RRP/Request/Describe.pm untested

filter: Statementstmt 0.0% 0 / 15 Branchbran 0.0% 0 / 2 Conditioncond 0.0% 0 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 0.0% 0 / 5 Podpod 0.0% 0 / 3 totaltotal 0.0% 0 / 30 CC 2 SCAR 12.0
CC
2
Cov
0%
setOption
6.0
getName
2.0
setEntity
2.0
CRAP 3.3
1 package Net::RRP::Request::Describe;
2  
3 use strict;
4 use Net::RRP::Request;
5 @Net::RRP::Request::Describe::ISA = qw(Net::RRP::Request);
6 $Net::RRP::Request::Describe::VERSION = '0.1';
7  
8 =head1 NAME
9  
10 Net::RRP::Request::Describe - rrp describe request representation.
11  
12 =head1 SYNOPSIS
13  
14 use Net::RRP::Request::Describe;
15 my $describeRequest = new Net::RRP::Request::Describe ( Target => 'Protocol' );
16 my $describeRequest1 = new Net::RRP::Request::Describe ();
17 $describeRequest1->setOption ( Target => 'Protocol' );
18  
19 =head1 DESCRIPTION
20  
21 This is a rrp describe request representation class.
22  
23 =cut
24  
25 =head2 getName
26  
27 return a 'Describe'
28  
29 =cut
30  
31 sub getName { 'Describe' };
32  
33 =head2 setEntity
34  
35 throw Net::RRP::Exception::InvalidEntityValue immediate
36  
37 =cut
38  
39 sub setEntity
40 {
41 throw Net::RRP::Exception::InvalidEntityValue ();
42 }
43  
44 =head2 setOption
45  
46 Pass only Target option with Protocol value. Throw Net::RRP::Exception::InvalidCommandOption in other case.
47  
48 =cut
49  
50 sub setOption
51 {
52 my ( $this, $key, $value ) = @_;
53 throw Net::RRP::Exception::InvalidCommandOption () unless ( ( lc ( $key ) eq 'target' ) && ( lc ( $value ) eq 'protocol' ) );
54 $this->SUPER::setOption ( $key => $value );
55 }
56  
57 =head1 AUTHOR AND COPYRIGHT
58  
59 Net::RRP::Request::Describe (C) Michael Kulakov, Zenon N.S.P. 2000
60 125124, 19, 1-st Jamskogo polja st,
61 Moscow, Russian Federation
62  
63 mkul@cpan.org
64  
65 All rights reserved.
66  
67 You may distribute this package under the terms of either the GNU
68 General Public License or the Artistic License, as specified in the
69 Perl README file.
70  
71 =head1 SEE ALSO
72  
73 L<Net::RRP::Request(3)>, L<Net::RRP::Codec(3)>, RFC 2832
74  
75 =cut
76  
77 1;
78  
79 __END__