Alexandre Julliard | 0799c1a | 2002-03-09 23:29:33 +0000 | [diff] [blame] | 1 | # |
| 2 | # Copyright 1999, 2000, 2001 Patrik Stridvall |
| 3 | # |
| 4 | # This library is free software; you can redistribute it and/or |
| 5 | # modify it under the terms of the GNU Lesser General Public |
| 6 | # License as published by the Free Software Foundation; either |
| 7 | # version 2.1 of the License, or (at your option) any later version. |
| 8 | # |
| 9 | # This library is distributed in the hope that it will be useful, |
| 10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 12 | # Lesser General Public License for more details. |
| 13 | # |
| 14 | # You should have received a copy of the GNU Lesser General Public |
| 15 | # License along with this library; if not, write to the Free Software |
| 16 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 17 | # |
| 18 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 19 | package function; |
| 20 | |
| 21 | use strict; |
| 22 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 23 | sub new($) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 24 | my $proto = shift; |
| 25 | my $class = ref($proto) || $proto; |
| 26 | my $self = {}; |
| 27 | bless ($self, $class); |
| 28 | |
| 29 | return $self; |
| 30 | } |
| 31 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 32 | sub file($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 33 | my $self = shift; |
| 34 | my $file = \${$self->{FILE}}; |
| 35 | |
| 36 | local $_ = shift; |
| 37 | |
| 38 | if(defined($_)) { $$file = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 39 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 40 | return $$file; |
| 41 | } |
| 42 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 43 | sub debug_channels($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 44 | my $self = shift; |
| 45 | my $debug_channels = \${$self->{DEBUG_CHANNELS}}; |
| 46 | |
| 47 | local $_ = shift; |
| 48 | |
| 49 | if(defined($_)) { $$debug_channels = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 50 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 51 | return $$debug_channels; |
| 52 | } |
| 53 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 54 | sub documentation_line($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 55 | my $self = shift; |
| 56 | my $documentation_line = \${$self->{DOCUMENTATION_LINE}}; |
| 57 | |
| 58 | local $_ = shift; |
| 59 | |
| 60 | if(defined($_)) { $$documentation_line = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 61 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 62 | return $$documentation_line; |
| 63 | } |
| 64 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 65 | sub documentation($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 66 | my $self = shift; |
| 67 | my $documentation = \${$self->{DOCUMENTATION}}; |
| 68 | |
| 69 | local $_ = shift; |
| 70 | |
| 71 | if(defined($_)) { $$documentation = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 72 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 73 | return $$documentation; |
| 74 | } |
| 75 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 76 | sub function_line($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 77 | my $self = shift; |
| 78 | my $function_line = \${$self->{FUNCTION_LINE}}; |
| 79 | |
| 80 | local $_ = shift; |
| 81 | |
| 82 | if(defined($_)) { $$function_line = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 83 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 84 | return $$function_line; |
| 85 | } |
| 86 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 87 | sub linkage($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 88 | my $self = shift; |
| 89 | my $linkage = \${$self->{LINKAGE}}; |
| 90 | |
| 91 | local $_ = shift; |
| 92 | |
| 93 | if(defined($_)) { $$linkage = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 94 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 95 | return $$linkage; |
| 96 | } |
| 97 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 98 | sub return_type($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 99 | my $self = shift; |
| 100 | my $return_type = \${$self->{RETURN_TYPE}}; |
| 101 | |
| 102 | local $_ = shift; |
| 103 | |
| 104 | if(defined($_)) { $$return_type = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 105 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 106 | return $$return_type; |
| 107 | } |
| 108 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 109 | sub calling_convention($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 110 | my $self = shift; |
| 111 | my $calling_convention = \${$self->{CALLING_CONVENTION}}; |
| 112 | |
| 113 | local $_ = shift; |
| 114 | |
| 115 | if(defined($_)) { $$calling_convention = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 116 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 117 | return $$calling_convention; |
| 118 | } |
| 119 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 120 | sub internal_name($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 121 | my $self = shift; |
| 122 | my $internal_name = \${$self->{INTERNAL_NAME}}; |
| 123 | |
| 124 | local $_ = shift; |
| 125 | |
| 126 | if(defined($_)) { $$internal_name = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 127 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 128 | return $$internal_name; |
| 129 | } |
| 130 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 131 | sub argument_types($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 132 | my $self = shift; |
| 133 | my $argument_types = \${$self->{ARGUMENT_TYPES}}; |
| 134 | |
| 135 | local $_ = shift; |
| 136 | |
| 137 | if(defined($_)) { $$argument_types = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 138 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 139 | return $$argument_types; |
| 140 | } |
| 141 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 142 | sub argument_names($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 143 | my $self = shift; |
| 144 | my $argument_names = \${$self->{ARGUMENT_NAMES}}; |
| 145 | |
| 146 | local $_ = shift; |
| 147 | |
| 148 | if(defined($_)) { $$argument_names = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 149 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 150 | return $$argument_names; |
| 151 | } |
| 152 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 153 | sub argument_documentations($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 154 | my $self = shift; |
| 155 | my $argument_documentations = \${$self->{ARGUMENT_DOCUMENTATIONS}}; |
| 156 | |
| 157 | local $_ = shift; |
| 158 | |
| 159 | if(defined($_)) { $$argument_documentations = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 160 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 161 | return $$argument_documentations; |
| 162 | } |
| 163 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 164 | sub statements_line($$) { |
Patrik Stridvall | 4b33b13 | 2001-08-09 21:35:38 +0000 | [diff] [blame] | 165 | my $self = shift; |
| 166 | my $statements_line = \${$self->{STATEMENTS_LINE}}; |
| 167 | |
| 168 | local $_ = shift; |
| 169 | |
| 170 | if(defined($_)) { $$statements_line = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 171 | |
Patrik Stridvall | 4b33b13 | 2001-08-09 21:35:38 +0000 | [diff] [blame] | 172 | return $$statements_line; |
| 173 | } |
| 174 | |
Francois Gouget | a8b09d1 | 2004-10-26 00:12:21 +0000 | [diff] [blame] | 175 | sub statements($$) { |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 176 | my $self = shift; |
| 177 | my $statements = \${$self->{STATEMENTS}}; |
| 178 | |
| 179 | local $_ = shift; |
| 180 | |
| 181 | if(defined($_)) { $$statements = $_; } |
Alexandre Julliard | 7cae558 | 2002-06-01 02:55:48 +0000 | [diff] [blame] | 182 | |
Patrik Stridvall | c3e8ac3 | 2001-07-11 17:27:45 +0000 | [diff] [blame] | 183 | return $$statements; |
| 184 | } |
| 185 | |
| 186 | 1; |