1## Domain Registry Interface, .CH/.LI policies 2## 3## Copyright (c) 2008,2009 Tonnerre Lombard <tonnerre.lombard@sygroup.ch>. 4## All rights reserved. 5## 6## This file is part of Net::DRI 7## 8## Net::DRI is free software; you can redistribute it and/or modify 9## it under the terms of the GNU General Public License as published by 10## the Free Software Foundation; either version 2 of the License, or 11## (at your option) any later version. 12## 13## See the LICENSE file that comes with this distribution for more details. 14# 15# 16# 17#################################################################################################### 18 19package Net::DRI::DRD::SWITCH; 20 21use strict; 22use warnings; 23 24use base qw/Net::DRI::DRD/; 25 26use DateTime::Duration; 27 28our $VERSION=do { my @r=(q$Revision: 1.3 $=~/\d+/g); sprintf("%d".".%02d" x $#r, @r); }; 29 30__PACKAGE__->make_exception_for_unavailable_operations(qw/domain_transfer_accept domain_transfer_refuse domain_renew contact_transfer_stop contact_transfer_query contact_transfer_accept contact_transfer_refuse/); 31 32=pod 33 34=head1 NAME 35 36Net::DRI::DRD::SWITCH - SWITCH (.CH/.LI) policies for Net::DRI 37 38=head1 DESCRIPTION 39 40Please see the README file for details. 41 42=head1 SUPPORT 43 44For now, support questions should be sent to: 45 46E<lt>tonnerre.lombard@sygroup.chE<gt> 47 48Please also see the SUPPORT file in the distribution. 49 50=head1 SEE ALSO 51 52E<lt>http://oss.bsdprojects.net/projects/netdri/E<gt> or 53E<lt>http://www.dotandco.com/services/software/Net-DRI/E<gt> 54 55=head1 AUTHOR 56 57Tonnerre Lombard, E<lt>tonnerre.lombard@sygroup.chE<gt> 58 59=head1 COPYRIGHT 60 61Copyright (c) 2008,2009 Tonnerre Lombard <tonnerre.lombard@sygroup.ch>. 62All rights reserved. 63 64This program is free software; you can redistribute it and/or modify 65it under the terms of the GNU General Public License as published by 66the Free Software Foundation; either version 2 of the License, or 67(at your option) any later version. 68 69See the LICENSE file that comes with this distribution for more details. 70 71=cut 72 73#################################################################################################### 74 75sub new 76{ 77 my $class=shift; 78 my $self=$class->SUPER::new(@_); 79 $self->{info}->{host_as_attr}=0; 80 $self->{info}->{contact_i18n}=1; ## LOC only 81 bless($self,$class); 82 return $self; 83} 84 85sub periods { return map { DateTime::Duration->new(years => $_) } (1); } 86sub name { return 'SWITCH'; } 87sub tlds { return ('ch','li'); } 88sub object_types { return ('domain','contact','ns'); } 89sub profile_types { return qw/epp/; } 90 91sub transport_protocol_default 92{ 93 my ($self,$type)=@_; 94 95 return ('Net::DRI::Transport::Socket',{},'Net::DRI::Protocol::EPP::Extensions::SWITCH',{}) if $type eq 'epp'; 96## return ('Net::DRI::Transport::Socket',{remote_host=>'whois.switch.ch'},'Net::DRI::Protocol::Whois',{}) if $type eq 'whois'; 97 return; 98} 99 100#################################################################################################### 1011; 102