freeswitch/libs/libscgi/perl/FSSCGI.pm
Anthony Minessale 4b2e7fc1f2 perl update
2012-05-23 11:31:17 -05:00

106 lines
2.1 KiB
Perl

# This file was automatically generated by SWIG (http://www.swig.org).
# Version 1.3.35
#
# Don't modify this file, modify the SWIG interface instead.
package FSSCGI;
require Exporter;
require DynaLoader;
@ISA = qw(Exporter DynaLoader);
package FSSCGIc;
bootstrap FSSCGI;
package FSSCGI;
@EXPORT = qw( );
# ---------- BASE METHODS -------------
package FSSCGI;
sub TIEHASH {
my ($classname,$obj) = @_;
return bless $obj, $classname;
}
sub CLEAR { }
sub FIRSTKEY { }
sub NEXTKEY { }
sub FETCH {
my ($self,$field) = @_;
my $member_func = "swig_${field}_get";
$self->$member_func();
}
sub STORE {
my ($self,$field,$newval) = @_;
my $member_func = "swig_${field}_set";
$self->$member_func($newval);
}
sub this {
my $ptr = shift;
return tied(%$ptr);
}
# ------- FUNCTION WRAPPERS --------
package FSSCGI;
############# Class : FSSCGI::SCGIhandle ##############
package FSSCGI::SCGIhandle;
use vars qw(@ISA %OWNER %ITERATORS %BLESSEDMEMBERS);
@ISA = qw( FSSCGI );
%OWNER = ();
%ITERATORS = ();
sub new {
my $pkg = shift;
my $self = FSSCGIc::new_SCGIhandle(@_);
bless $self, $pkg if defined($self);
}
sub DESTROY {
return unless $_[0]->isa('HASH');
my $self = tied(%{$_[0]});
return unless defined $self;
delete $ITERATORS{$self};
if (exists $OWNER{$self}) {
FSSCGIc::delete_SCGIhandle($self);
delete $OWNER{$self};
}
}
*connected = *FSSCGIc::SCGIhandle_connected;
*socketDescriptor = *FSSCGIc::SCGIhandle_socketDescriptor;
*disconnect = *FSSCGIc::SCGIhandle_disconnect;
*addParam = *FSSCGIc::SCGIhandle_addParam;
*addBody = *FSSCGIc::SCGIhandle_addBody;
*getBody = *FSSCGIc::SCGIhandle_getBody;
*getParam = *FSSCGIc::SCGIhandle_getParam;
*sendRequest = *FSSCGIc::SCGIhandle_sendRequest;
*respond = *FSSCGIc::SCGIhandle_respond;
*bind = *FSSCGIc::SCGIhandle_bind;
*accept = *FSSCGIc::SCGIhandle_accept;
sub DISOWN {
my $self = shift;
my $ptr = tied(%$self);
delete $OWNER{$ptr};
}
sub ACQUIRE {
my $self = shift;
my $ptr = tied(%$self);
$OWNER{$ptr} = 1;
}
# ------- VARIABLE STUBS --------
package FSSCGI;
1;