eliminate warnings about redefined subroutines
[Business-OnlinePayment-LinkPoint.git] / LinkPoint.pm
index 9a77236..7b307ff 100644 (file)
@@ -1,6 +1,6 @@
 package Business::OnlinePayment::LinkPoint;
 
-# $Id: LinkPoint.pm,v 1.1 2002-02-15 01:19:27 ivan Exp $
+# $Id: LinkPoint.pm,v 1.3 2002-02-26 08:53:52 ivan Exp $
 
 use strict;
 use vars qw($VERSION @ISA @EXPORT @EXPORT_OK);
@@ -15,7 +15,7 @@ require Exporter;
 @ISA = qw(Exporter AutoLoader Business::OnlinePayment);
 @EXPORT = qw();
 @EXPORT_OK = qw();
-$VERSION = '0.01';
+$VERSION = '0.02';
 
 sub set_defaults {
     my $self = shift;
@@ -43,6 +43,14 @@ sub map_fields {
     $self->content(%content);
 }
 
+sub build_subs {
+    my $self = shift;
+    foreach(@_) {
+        no warnings;
+        eval "sub $_ { my \$self = shift; if(\@_) { \$self->{$_} = shift; } return \$self->{$_}; }";
+    }
+}
+
 sub remap_fields {
     my($self,%map) = @_;
 
@@ -139,8 +147,7 @@ sub submit {
       name email phone address city state zip country
     /);
 
-    print "$_ => $post_data{$_}\n" foreach keys %post_data;
-    #die;
+    #print "$_ => $post_data{$_}\n" foreach keys %post_data;
 
     my %response = $lperl->$action(\%post_data);
 
@@ -210,7 +217,7 @@ For detailed information see L<Business::OnlinePayment>.
 =head1 COMPATIBILITY
 
 This module implements an interface to the LinkPoint Perl Wrapper
-http://www.linkpoint.com/product_solutions/internet/inet_index.html
+http://www.linkpoint.com/product_solutions/internet/lperl/lperl_main.html
 
 =head1 BUGS