1999-10-31 03:08:38 +01:00
|
|
|
package winapi_function;
|
|
|
|
|
|
|
|
use strict;
|
|
|
|
|
|
|
|
sub new {
|
|
|
|
my $proto = shift;
|
|
|
|
my $class = ref($proto) || $proto;
|
|
|
|
my $self = {};
|
|
|
|
bless ($self, $class);
|
|
|
|
|
|
|
|
return $self;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub file {
|
|
|
|
my $self = shift;
|
|
|
|
my $file = \${$self->{FILE}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$file = $_; }
|
|
|
|
|
|
|
|
return $$file;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub documentation {
|
|
|
|
my $self = shift;
|
|
|
|
my $documentation = \${$self->{DOCUMENTATION}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$documentation = $_; }
|
|
|
|
|
|
|
|
return $$documentation;
|
|
|
|
}
|
|
|
|
|
2000-03-24 21:39:51 +01:00
|
|
|
sub linkage {
|
|
|
|
my $self = shift;
|
|
|
|
my $linkage = \${$self->{LINKAGE}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$linkage = $_; }
|
|
|
|
|
|
|
|
return $$linkage;
|
|
|
|
}
|
|
|
|
|
1999-10-31 03:08:38 +01:00
|
|
|
sub return_type {
|
|
|
|
my $self = shift;
|
|
|
|
my $return_type = \${$self->{RETURN_TYPE}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$return_type = $_; }
|
|
|
|
|
|
|
|
return $$return_type;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub calling_convention {
|
|
|
|
my $self = shift;
|
|
|
|
my $calling_convention = \${$self->{CALLING_CONVENTION}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$calling_convention = $_; }
|
|
|
|
|
|
|
|
return $$calling_convention;
|
|
|
|
}
|
|
|
|
|
2000-05-24 01:37:51 +02:00
|
|
|
sub external_name16 {
|
1999-10-31 03:08:38 +01:00
|
|
|
my $self = shift;
|
2000-05-24 01:37:51 +02:00
|
|
|
my $external_name16 = \${$self->{EXTERNAL_NAME16}};
|
1999-10-31 03:08:38 +01:00
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
2000-05-24 01:37:51 +02:00
|
|
|
if(defined($_)) { $$external_name16 = $_; }
|
1999-10-31 03:08:38 +01:00
|
|
|
|
2000-05-24 01:37:51 +02:00
|
|
|
return $$external_name16;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub external_name32 {
|
|
|
|
my $self = shift;
|
|
|
|
my $external_name32 = \${$self->{EXTERNAL_NAME32}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$external_name32 = $_; }
|
|
|
|
|
|
|
|
return $$external_name32;
|
2000-04-24 20:02:32 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
sub internal_name {
|
|
|
|
my $self = shift;
|
|
|
|
my $internal_name = \${$self->{INTERNAL_NAME}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$internal_name = $_; }
|
|
|
|
|
|
|
|
return $$internal_name;
|
1999-10-31 03:08:38 +01:00
|
|
|
}
|
|
|
|
|
2000-05-11 23:46:17 +02:00
|
|
|
sub argument_types {
|
1999-10-31 03:08:38 +01:00
|
|
|
my $self = shift;
|
2000-05-11 23:46:17 +02:00
|
|
|
my $argument_types = \${$self->{ARGUMENT_TYPES}};
|
1999-10-31 03:08:38 +01:00
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
2000-05-11 23:46:17 +02:00
|
|
|
if(defined($_)) { $$argument_types = $_; }
|
1999-10-31 03:08:38 +01:00
|
|
|
|
2000-05-11 23:46:17 +02:00
|
|
|
return $$argument_types;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub argument_names {
|
|
|
|
my $self = shift;
|
|
|
|
my $argument_names = \${$self->{ARGUMENT_NAMES}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$argument_names = $_; }
|
|
|
|
|
|
|
|
return $$argument_names;
|
1999-10-31 03:08:38 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
sub module16 {
|
|
|
|
my $self = shift;
|
|
|
|
my $module16 = \${$self->{MODULE16}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$module16 = $_; }
|
|
|
|
return $$module16;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub module32 {
|
|
|
|
my $self = shift;
|
|
|
|
my $module32 = \${$self->{MODULE32}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$module32 = $_; }
|
|
|
|
return $$module32;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub statements {
|
|
|
|
my $self = shift;
|
|
|
|
my $statements = \${$self->{STATEMENTS}};
|
|
|
|
|
|
|
|
local $_ = shift;
|
|
|
|
|
|
|
|
if(defined($_)) { $$statements = $_; }
|
|
|
|
|
|
|
|
return $$statements;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub module {
|
|
|
|
my $self = shift;
|
|
|
|
my $module16 = \${$self->{MODULE16}};
|
|
|
|
my $module32 = \${$self->{MODULE32}};
|
|
|
|
|
|
|
|
my $module;
|
|
|
|
if(defined($$module16) && defined($$module32)) {
|
|
|
|
$module = "$$module16 & $$module32";
|
|
|
|
} elsif(defined($$module16)) {
|
|
|
|
$module = $$module16;
|
|
|
|
} elsif(defined($$module32)) {
|
|
|
|
$module = $$module32;
|
|
|
|
} else {
|
|
|
|
$module = "";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
sub function_called {
|
|
|
|
my $self = shift;
|
|
|
|
my $called_function_names = \%{$self->{CALLED_FUNCTION_NAMES}};
|
|
|
|
|
|
|
|
my $name = shift;
|
|
|
|
|
|
|
|
$$called_function_names{$name}++;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub function_called_by {
|
|
|
|
my $self = shift;
|
|
|
|
my $called_by_function_names = \%{$self->{CALLED_BY_FUNCTION_NAMES}};
|
|
|
|
|
|
|
|
my $name = shift;
|
|
|
|
|
|
|
|
$$called_by_function_names{$name}++;
|
|
|
|
}
|
|
|
|
|
|
|
|
sub called_function_names {
|
|
|
|
my $self = shift;
|
|
|
|
my $called_function_names = \%{$self->{CALLED_FUNCTION_NAMES}};
|
|
|
|
|
|
|
|
return sort(keys(%$called_function_names));
|
|
|
|
}
|
|
|
|
|
|
|
|
sub called_by_function_names {
|
|
|
|
my $self = shift;
|
|
|
|
my $called_by_function_names = \%{$self->{CALLED_BY_FUNCTION_NAMES}};
|
|
|
|
|
|
|
|
return sort(keys(%$called_by_function_names));
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
1;
|