blib/lib/VM/EC2/REST/windows.pm untested

filter: Statementstmt 0.0% 0 / 12 Branchbran n/a Conditioncond 0.0% 0 / 2 MC/DCmcdc n/a Subroutinesub 0.0% 0 / 3 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 18 CC 1 SCAR 6.9
CC
1
Cov
0%
get_password_data
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 package VM::EC2::REST::windows;
2  
3 use strict;
4 use VM::EC2 ''; # important not to import anything!
5 package VM::EC2; # add methods to VM::EC2
6  
7 VM::EC2::Dispatch->register(GetPasswordData => 'VM::EC2::Instance::PasswordData');
8  
9 =head1 NAME VM::EC2::REST::windows
10  
11 =head1 SYNOPSIS
12  
13 use VM::EC2 ':misc';
14  
15 =head1 METHODS
16  
17 These methods control several Windows platform-related
18 functions. However, only GetPasswordData is implemented by VM::EC2
19 (volunteers welcome).
20  
21 Implemented:
22 GetPasswordData
23  
24 Unimplemented:
25 BundleInstance
26 CancelBundleTask
27 DescribeBundleTasks
28  
29 =cut
30  
31 =head2 $password_data = $ec2->get_password_data($instance_id);
32  
33 =head2 $password_data = $ec2->get_password_data(-instance_id=>$id);
34  
35 For Windows instances, get the administrator's password as a
36 L<VM::EC2::Instance::PasswordData> object.
37  
38 =cut
39  
40 sub get_password_data {
41 my $self = shift;
42 my %args = VM::EC2::ParmParser->args(-instance_id=>@_);
43 $args{-instance_id} or croak "Usage: get_password_data(-instance_id=>\$id)";
44 my ($async,@params) = VM::EC2::ParmParser->format_parms(\%args,{single_parm=>'InstanceId'});
45 return $self->call('GetPasswordData',@params);
46 }
47  
48  
49 =head1 SEE ALSO
50  
51 L<VM::EC2>
52  
53 =head1 AUTHOR
54  
55 Lincoln Stein E<lt>lincoln.stein@gmail.comE<gt>.
56  
57 Copyright (c) 2011 Ontario Institute for Cancer Research
58  
59 This package and its accompanying libraries is free software; you can
60 redistribute it and/or modify it under the terms of the GPL (either
61 version 1, or at your option, any later version) or the Artistic
62 License 2.0. Refer to LICENSE for the full license text. In addition,
63 please see DISCLAIMER.txt for disclaimers of warranty.
64  
65 =cut
66  
67  
68 1;