5.005-safe
[Business-OnlinePayment-LinkPoint.git] / LinkPoint.pm
index 88a8ac2..22815c3 100644 (file)
@@ -1,6 +1,6 @@
 package Business::OnlinePayment::LinkPoint;
 
-# $Id: LinkPoint.pm,v 1.2 2002-02-26 08:24:00 ivan Exp $
+# $Id: LinkPoint.pm,v 1.4 2002-02-27 22:16:08 ivan Exp $
 
 use strict;
 use vars qw($VERSION @ISA @EXPORT @EXPORT_OK);
@@ -43,6 +43,15 @@ sub map_fields {
     $self->content(%content);
 }
 
+sub build_subs {
+    my $self = shift;
+    foreach(@_) {
+        #no warnings; #not 5.005
+        local($^W)=0;
+        eval "sub $_ { my \$self = shift; if(\@_) { \$self->{$_} = shift; } return \$self->{$_}; }";
+    }
+}
+
 sub remap_fields {
     my($self,%map) = @_;