import of rt 3.0.4
[freeside.git] / rt / lib / RT / CachedGroupMember.pm
1 # BEGIN LICENSE BLOCK
2
3 # Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
4
5 # (Except where explictly superceded by other copyright notices)
6
7 # This work is made available to you under the terms of Version 2 of
8 # the GNU General Public License. A copy of that license should have
9 # been provided with this software, but in any event can be snarfed
10 # from www.gnu.org.
11
12 # This work is distributed in the hope that it will be useful, but
13 # WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15 # General Public License for more details.
16
17 # Unless otherwise specified, all modifications, corrections or
18 # extensions to this work which alter its source code become the
19 # property of Best Practical Solutions, LLC when submitted for
20 # inclusion in the work.
21
22
23 # END LICENSE BLOCK
24 # Autogenerated by DBIx::SearchBuilder factory (by <jesse@bestpractical.com>)
25 # WARNING: THIS FILE IS AUTOGENERATED. ALL CHANGES TO THIS FILE WILL BE LOST.  
26
27 # !! DO NOT EDIT THIS FILE !!
28 #
29
30 use strict;
31
32
33 =head1 NAME
34
35 RT::CachedGroupMember
36
37
38 =head1 SYNOPSIS
39
40 =head1 DESCRIPTION
41
42 =head1 METHODS
43
44 =cut
45
46 package RT::CachedGroupMember;
47 use RT::Record; 
48
49
50 use vars qw( @ISA );
51 @ISA= qw( RT::Record );
52
53 sub _Init {
54   my $self = shift; 
55
56   $self->Table('CachedGroupMembers');
57   $self->SUPER::_Init(@_);
58 }
59
60
61
62
63
64 =item Create PARAMHASH
65
66 Create takes a hash of values and creates a row in the database:
67
68   int(11) 'GroupId'.
69   int(11) 'MemberId'.
70   int(11) 'Via'.
71   int(11) 'ImmediateParentId'.
72   smallint(6) 'Disabled'.
73
74 =cut
75
76
77
78
79 sub Create {
80     my $self = shift;
81     my %args = ( 
82                 GroupId => '',
83                 MemberId => '',
84                 Via => '',
85                 ImmediateParentId => '',
86                 Disabled => '0',
87
88                   @_);
89     $self->SUPER::Create(
90                          GroupId => $args{'GroupId'},
91                          MemberId => $args{'MemberId'},
92                          Via => $args{'Via'},
93                          ImmediateParentId => $args{'ImmediateParentId'},
94                          Disabled => $args{'Disabled'},
95 );
96
97 }
98
99
100
101 =item id
102
103 Returns the current value of id. 
104 (In the database, id is stored as int(11).)
105
106
107 =cut
108
109
110 =item GroupId
111
112 Returns the current value of GroupId. 
113 (In the database, GroupId is stored as int(11).)
114
115
116
117 =item SetGroupId VALUE
118
119
120 Set GroupId to VALUE. 
121 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
122 (In the database, GroupId will be stored as a int(11).)
123
124
125 =cut
126
127
128 =item MemberId
129
130 Returns the current value of MemberId. 
131 (In the database, MemberId is stored as int(11).)
132
133
134
135 =item SetMemberId VALUE
136
137
138 Set MemberId to VALUE. 
139 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
140 (In the database, MemberId will be stored as a int(11).)
141
142
143 =cut
144
145
146 =item Via
147
148 Returns the current value of Via. 
149 (In the database, Via is stored as int(11).)
150
151
152
153 =item SetVia VALUE
154
155
156 Set Via to VALUE. 
157 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
158 (In the database, Via will be stored as a int(11).)
159
160
161 =cut
162
163
164 =item ImmediateParentId
165
166 Returns the current value of ImmediateParentId. 
167 (In the database, ImmediateParentId is stored as int(11).)
168
169
170
171 =item SetImmediateParentId VALUE
172
173
174 Set ImmediateParentId to VALUE. 
175 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
176 (In the database, ImmediateParentId will be stored as a int(11).)
177
178
179 =cut
180
181
182 =item Disabled
183
184 Returns the current value of Disabled. 
185 (In the database, Disabled is stored as smallint(6).)
186
187
188
189 =item SetDisabled VALUE
190
191
192 Set Disabled to VALUE. 
193 Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
194 (In the database, Disabled will be stored as a smallint(6).)
195
196
197 =cut
198
199
200
201 sub _ClassAccessible {
202     {
203      
204         id =>
205                 {read => 1, type => 'int(11)', default => ''},
206         GroupId => 
207                 {read => 1, write => 1, type => 'int(11)', default => ''},
208         MemberId => 
209                 {read => 1, write => 1, type => 'int(11)', default => ''},
210         Via => 
211                 {read => 1, write => 1, type => 'int(11)', default => ''},
212         ImmediateParentId => 
213                 {read => 1, write => 1, type => 'int(11)', default => ''},
214         Disabled => 
215                 {read => 1, write => 1, type => 'smallint(6)', default => '0'},
216
217  }
218 };
219
220
221         eval "require RT::CachedGroupMember_Overlay";
222         if ($@ && $@ !~ qr{^Can't locate RT/CachedGroupMember_Overlay.pm}) {
223             die $@;
224         };
225
226         eval "require RT::CachedGroupMember_Vendor";
227         if ($@ && $@ !~ qr{^Can't locate RT/CachedGroupMember_Vendor.pm}) {
228             die $@;
229         };
230
231         eval "require RT::CachedGroupMember_Local";
232         if ($@ && $@ !~ qr{^Can't locate RT/CachedGroupMember_Local.pm}) {
233             die $@;
234         };
235
236
237
238
239 =head1 SEE ALSO
240
241 This class allows "overlay" methods to be placed
242 into the following files _Overlay is for a System overlay by the original author,
243 _Vendor is for 3rd-party vendor add-ons, while _Local is for site-local customizations.  
244
245 These overlay files can contain new subs or subs to replace existing subs in this module.
246
247 If you'll be working with perl 5.6.0 or greater, each of these files should begin with the line 
248
249    no warnings qw(redefine);
250
251 so that perl does not kick and scream when you redefine a subroutine or variable in your overlay.
252
253 RT::CachedGroupMember_Overlay, RT::CachedGroupMember_Vendor, RT::CachedGroupMember_Local
254
255 =cut
256
257
258 1;