ParseWhois/Domain/Registrar/SRSPlus.pm untested

filter: Statementstmt 0.0% 0 / 36 Branchbran 0.0% 0 / 14 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 14 Podpod 0.0% 0 / 12 totaltotal 0.0% 0 / 76 CC 8 SCAR 33.6
CC
8
Cov
0%
parse_text
72.0
rdebug
2.0
regex_org_start
2.0
CRAP 28.7
1 # Program: Net::ParseWhois::Domain::Registrar class for SRSPlus
2 # Version: 1.0
3 # Purpose: Provides parsing methods and configurations for the SRSPlus
4 # registrar (a division of Network Solutions)
5 # Written: 11/21/05 by Jeff Mercer <riffer@vaxer.net>
6  
7 package Net::ParseWhois::Domain::Registrar::SRSPlus;
8  
9 require 5.004;
10 use strict;
11  
12 @Net::ParseWhois::Domain::Registrar::SRSPlus::ISA = qw(Net::ParseWhois::Domain::Registrar);
13 $Net::ParseWhois::Domain::Registrar::SRSPlus::VERSION = 1.0;
14  
15 sub rdebug { 0 }
16 sub regex_org_start { '^Registrant:'}
17 sub regex_no_match { '^No match for' }
18 sub regex_created { '^Record created on (.*)\.$' }
19 sub regex_expires { '^Record expires on (.*)\.$' }
20 # NetSol/SRSPLus no longer gives last updated date for individual domains
21 sub regex_updated { '^Record last updated on (.*)\.$' }
22 sub regex_domain { '^Domain Name: (.*)$' }
23 sub regex_nameservers { '^Domain servers:$' }
24 sub my_nameservers_noips { 1 }
25 sub my_contacts { [ qw(Admin Technical Billing) ] }
26 sub my_data { [ qw(my_nameservers_noips my_contacts regex_org_start regex_no_match regex_created regex_updated regex_expires regex_domain regex_nameservers) ] }
27  
28 sub parse_text {
29 my $self = shift;
30 my $text = shift; # array ref, one line per element
31  
32 # Because NetSol doesn't give the last time a domain record was
33 # updated, we need to pre-fill that data value so the parse_contacts
34 # method won't screw-up. --jcm, 11/16/05
35 $self->{RECORD_UPDATED}="n/a";
36  
37 $self->dump_text($text) if $self->rdebug;
38 $self->parse_start($text);
39 $self->dump_text($text) if $self->rdebug;
40 $self->parse_org($text);
41 $self->dump_text($text) if $self->rdebug;
42 $self->parse_domain_name($text);
43 $self->dump_text($text) if $self->rdebug;
44 $self->parse_contacts($text);
45 $self->dump_text($text) if $self->rdebug;
46 $self->parse_domain_stats($text);
47 $self->dump_text($text) if $self->rdebug;
48 $self->parse_nameservers($text);
49 $self->dump_text($text) if $self->rdebug;
50  
51 return $self;
52 }
53  
54 1;