DBA Data[Home] [Help]

PACKAGE: APPS.BEN_BFT_SHD

Source


1 Package ben_bft_shd AUTHID CURRENT_USER as
2 /* $Header: bebftrhi.pkh 120.0 2005/05/28 00:40:56 appldev noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                    Global Record Type Specification                      |
6 -- ----------------------------------------------------------------------------
7 --
8 Type g_rec_type Is Record
9   (
10   benefit_action_id                 number(15),
11   process_date                      date,
12   uneai_effective_date              date,
13   mode_cd                           varchar2(30),
14   derivable_factors_flag            varchar2(30),
15   close_uneai_flag                  varchar2(30),
16   validate_flag                     varchar2(30),
17   person_id                         number(15),
18   person_type_id                    number(15),
19   pgm_id                            number(15),
20   business_group_id                 number(15),
21   pl_id                             number(15),
22   popl_enrt_typ_cycl_id             number(15),
23   no_programs_flag                  varchar2(30),
24   no_plans_flag                     varchar2(30),
25   comp_selection_rl                 number(15),
26   person_selection_rl               number(15),
27   ler_id                            number(15),
28   organization_id                   number(15),
29   benfts_grp_id                     number(15),
30   location_id                       number(15),
31   pstl_zip_rng_id                   number(15),
32   rptg_grp_id                       number(15),
33   pl_typ_id                         number(15),
34   opt_id                            number(15),
35   eligy_prfl_id                     number(15),
36   vrbl_rt_prfl_id                   number(15),
37   legal_entity_id                   number(15),
38   payroll_id                        number(15),
39   debug_messages_flag               varchar2(30),
40   cm_trgr_typ_cd                    varchar2(30),
41   cm_typ_id                         number(15),
42   age_fctr_id                       number(15),
43   min_age                           number(15),
44   max_age                           number(15),
45   los_fctr_id                       number(15),
46   min_los                           number(15),
47   max_los                           number(15),
48   cmbn_age_los_fctr_id              number(15),
49   min_cmbn                          number(15),
50   max_cmbn                          number(15),
51   date_from                         date,
52   elig_enrol_cd                     varchar2(30),
53   actn_typ_id                       number(15),
54   use_fctr_to_sel_flag              varchar2(30),
55   los_det_to_use_cd                 varchar2(30),
56   audit_log_flag                    varchar2(30),
57   lmt_prpnip_by_org_flag            varchar2(30),
58   lf_evt_ocrd_dt                    date,
59   ptnl_ler_for_per_stat_cd          varchar2(30),
60   bft_attribute_category            varchar2(30),
61   bft_attribute1                    varchar2(150),
62   bft_attribute3                    varchar2(150),
63   bft_attribute4                    varchar2(150),
64   bft_attribute5                    varchar2(150),
65   bft_attribute6                    varchar2(150),
66   bft_attribute7                    varchar2(150),
67   bft_attribute8                    varchar2(150),
68   bft_attribute9                    varchar2(150),
69   bft_attribute10                   varchar2(150),
70   bft_attribute11                   varchar2(150),
71   bft_attribute12                   varchar2(150),
72   bft_attribute13                   varchar2(150),
73   bft_attribute14                   varchar2(150),
74   bft_attribute15                   varchar2(150),
75   bft_attribute16                   varchar2(150),
76   bft_attribute17                   varchar2(150),
77   bft_attribute18                   varchar2(150),
78   bft_attribute19                   varchar2(150),
79   bft_attribute20                   varchar2(150),
80   bft_attribute21                   varchar2(150),
81   bft_attribute22                   varchar2(150),
82   bft_attribute23                   varchar2(150),
83   bft_attribute24                   varchar2(150),
84   bft_attribute25                   varchar2(150),
85   bft_attribute26                   varchar2(150),
86   bft_attribute27                   varchar2(150),
87   bft_attribute28                   varchar2(150),
88   bft_attribute29                   varchar2(150),
89   bft_attribute30                   varchar2(150),
90   request_id                        number(15),
91   program_application_id            number(15),
92   program_id                        number(15),
93   program_update_date               date,
94   object_version_number             number(9),
95   enrt_perd_id                      number(15),
96   inelg_action_cd                   varchar2(30),
97   org_hierarchy_id                   number,
98   org_starting_node_id                   number,
99   grade_ladder_id                   number,
100   asg_events_to_all_sel_dt                   varchar2(30),
101   rate_id                   number,
102   per_sel_dt_cd                   varchar2(30),
103   per_sel_freq_cd                   varchar2(30),
104   per_sel_dt_from                   date,
105   per_sel_dt_to                   date,
106   year_from                   number,
107   year_to                   number,
108   cagr_id                   number,
109   qual_type                   number,
110   qual_status                   varchar2(30),
111   concat_segs                   varchar2(2000),
112   grant_price_val                   number
113   );
114 --
115 -- ----------------------------------------------------------------------------
116 -- |           Global Definitions - Internal Development Use Only             |
117 -- ----------------------------------------------------------------------------
118 --
119 g_old_rec  g_rec_type;                            -- Global record definition
120 g_api_dml  boolean;                               -- Global api dml status
121 --
122 -- ----------------------------------------------------------------------------
123 -- |------------------------< return_api_dml_status >-------------------------|
124 -- ----------------------------------------------------------------------------
125 -- {Start Of Comments}
126 --
127 -- Description:
128 --   This function will return the current g_api_dml private global
129 --   boolean status.
130 --   The g_api_dml status determines if at the time of the function
131 --   being executed if a dml statement (i.e. INSERT, UPDATE or DELETE)
132 --   is being issued from within an api.
133 --   If the status is TRUE then a dml statement is being issued from
134 --   within this entity api.
135 --   This function is primarily to support database triggers which
136 --   need to maintain the object_version_number for non-supported
137 --   dml statements (i.e. dml statement issued outside of the api layer).
138 --
139 -- Prerequisites:
140 --   None.
141 --
142 -- In Parameters:
143 --   None.
144 --
145 -- Post Success:
146 --   Processing continues.
147 --   If the function returns a TRUE value then, dml is being executed from
148 --   within this api.
149 --
150 -- Post Failure:
151 --   None.
152 --
153 -- Access Status:
154 --   Internal Row Handler Use Only.
155 --
156 -- {End Of Comments}
157 -- ----------------------------------------------------------------------------
158 Function return_api_dml_status Return Boolean;
159 --
160 -- ----------------------------------------------------------------------------
161 -- |---------------------------< constraint_error >---------------------------|
162 -- ----------------------------------------------------------------------------
163 -- {Start Of Comments}
164 --
165 -- Description:
166 --   This procedure is called when a constraint has been violated (i.e.
167 --   The exception hr_api.check_integrity_violated,
168 --   hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
169 --   hr_api.unique_integrity_violated has been raised).
170 --   The exceptions can only be raised as follows:
171 --   1) A check constraint can only be violated during an INSERT or UPDATE
172 --      dml operation.
173 --   2) A parent integrity constraint can only be violated during an
174 --      INSERT or UPDATE dml operation.
175 --   3) A child integrity constraint can only be violated during an
176 --      DELETE dml operation.
177 --   4) A unique integrity constraint can only be violated during INSERT or
178 --      UPDATE dml operation.
179 --
180 -- Prerequisites:
181 --   1) Either hr_api.check_integrity_violated,
182 --      hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
183 --      hr_api.unique_integrity_violated has been raised with the subsequent
184 --      stripping of the constraint name from the generated error message
185 --      text.
186 --   2) Standalone validation test which corresponds with a constraint error.
187 --
188 -- In Parameter:
189 --   p_constraint_name is in upper format and is just the constraint name
190 --   (e.g. not prefixed by brackets, schema owner etc).
191 --
192 -- Post Success:
193 --   Development dependant.
194 --
195 -- Post Failure:
196 --   Developement dependant.
197 --
198 -- Developer Implementation Notes:
199 --   For each constraint being checked the hr system package failure message
200 --   has been generated as a template only. These system error messages should
201 --   be modified as required (i.e. change the system failure message to a user
202 --   friendly defined error message).
203 --
204 -- Access Status:
205 --   Internal Development Use Only.
206 --
207 -- {End Of Comments}
208 -- ----------------------------------------------------------------------------
209 Procedure constraint_error
210             (p_constraint_name in all_constraints.constraint_name%TYPE);
211 --
212 -- ----------------------------------------------------------------------------
213 -- |-----------------------------< api_updating >-----------------------------|
214 -- ----------------------------------------------------------------------------
215 -- {Start Of Comments}
216 --
217 -- Description:
218 --   This function is used to populate the g_old_rec record with the
219 --   current row from the database for the specified primary key
220 --   provided that the primary key exists and is valid and does not
221 --   already match the current g_old_rec. The function will always return
222 --   a TRUE value if the g_old_rec is populated with the current row.
223 --   A FALSE value will be returned if all of the primary key arguments
224 --   are null.
225 --
226 -- Prerequisites:
227 --   None.
228 --
229 -- In Parameters:
230 --
231 -- Post Success:
232 --   A value of TRUE will be returned indiciating that the g_old_rec
233 --   is current.
234 --   A value of FALSE will be returned if all of the primary key arguments
235 --   have a null value (this indicates that the row has not be inserted into
236 --   the Schema), and therefore could never have a corresponding row.
237 --
238 -- Post Failure:
239 --   A failure can only occur under two circumstances:
240 --   1) The primary key is invalid (i.e. a row does not exist for the
241 --      specified primary key values).
242 --   2) If an object_version_number exists but is NOT the same as the current
243 --      g_old_rec value.
244 --
245 -- Developer Implementation Notes:
246 --   None.
247 --
248 -- Access Status:
249 --   Internal Development Use Only.
250 --
251 -- {End Of Comments}
252 -- ----------------------------------------------------------------------------
253 Function api_updating
254   (
255   p_benefit_action_id                  in number,
256   p_object_version_number              in number
257   )      Return Boolean;
258 --
259 -- ----------------------------------------------------------------------------
260 -- |---------------------------------< lck >----------------------------------|
261 -- ----------------------------------------------------------------------------
262 -- {Start Of Comments}
263 --
264 -- Description:
265 --   The Lck process has two main functions to perform. Firstly, the row to be
266 --   updated or deleted must be locked. The locking of the row will only be
267 --   successful if the row is not currently locked by another user.
268 --   Secondly, during the locking of the row, the row is selected into
269 --   the g_old_rec data structure which enables the current row values from the
270 --   server to be available to the api.
271 --
272 -- Prerequisites:
273 --   When attempting to call the lock the object version number (if defined)
274 --   is mandatory.
275 --
276 -- In Parameters:
277 --   The arguments to the Lck process are the primary key(s) which uniquely
278 --   identify the row and the object version number of row.
279 --
280 -- Post Success:
281 --   On successful completion of the Lck process the row to be updated or
282 --   deleted will be locked and selected into the global data structure
283 --   g_old_rec.
284 --
285 -- Post Failure:
286 --   The Lck process can fail for three reasons:
287 --   1) When attempting to lock the row the row could already be locked by
288 --      another user. This will raise the HR_Api.Object_Locked exception.
289 --   2) The row which is required to be locked doesn't exist in the HR Schema.
290 --      This error is trapped and reported using the message name
291 --      'HR_7220_INVALID_PRIMARY_KEY'.
292 --   3) The row although existing in the HR Schema has a different object
293 --      version number than the object version number specified.
294 --      This error is trapped and reported using the message name
295 --      'HR_7155_OBJECT_INVALID'.
296 --
297 -- Developer Implementation Notes:
298 --   For each primary key and the object version number arguments add a
299 --   call to hr_api.mandatory_arg_error procedure to ensure that these
300 --   argument values are not null.
301 --
302 -- Access Status:
303 --   Internal Development Use Only.
304 --
305 -- {End Of Comments}
306 -- ----------------------------------------------------------------------------
307 Procedure lck
308   (
309   p_benefit_action_id                  in number,
310   p_object_version_number              in number
311   );
312 --
313 -- ----------------------------------------------------------------------------
314 -- |-----------------------------< convert_args >-----------------------------|
315 -- ----------------------------------------------------------------------------
316 -- {Start Of Comments}
317 --
318 -- Description:
319 --   This function is used to turn attribute parameters into the record
320 --   structure parameter g_rec_type.
321 --
322 -- Prerequisites:
323 --   This is a private function and can only be called from the ins or upd
324 --   attribute processes.
325 --
326 -- In Parameters:
327 --
328 -- Post Success:
329 --   A returning record structure will be returned.
330 --
331 -- Post Failure:
332 --   No direct error handling is required within this function. Any possible
333 --   errors within this function will be a PL/SQL value error due to conversion
334 --   of datatypes or data lengths.
335 --
336 -- Developer Implementation Notes:
337 --   None.
338 --
339 -- Access Status:
340 --   Internal Row Handler Use Only.
341 --
342 -- {End Of Comments}
343 -- ----------------------------------------------------------------------------
344 Function convert_args
345 	(
346 	p_benefit_action_id             in number,
347 	p_process_date                  in date,
348 	p_uneai_effective_date          in date,
349 	p_mode_cd                       in varchar2,
350 	p_derivable_factors_flag        in varchar2,
351 	p_close_uneai_flag              in varchar2,
352 	p_validate_flag                 in varchar2,
353 	p_person_id                     in number,
354 	p_person_type_id                in number,
355 	p_pgm_id                        in number,
356 	p_business_group_id             in number,
357 	p_pl_id                         in number,
358 	p_popl_enrt_typ_cycl_id         in number,
359 	p_no_programs_flag              in varchar2,
360 	p_no_plans_flag                 in varchar2,
364 	p_organization_id               in number,
361 	p_comp_selection_rl             in number,
362 	p_person_selection_rl           in number,
363 	p_ler_id                        in number,
365 	p_benfts_grp_id                 in number,
366 	p_location_id                   in number,
367 	p_pstl_zip_rng_id               in number,
368 	p_rptg_grp_id                   in number,
369 	p_pl_typ_id                     in number,
370 	p_opt_id                        in number,
371 	p_eligy_prfl_id                 in number,
372 	p_vrbl_rt_prfl_id               in number,
373 	p_legal_entity_id               in number,
374 	p_payroll_id                    in number,
375 	p_debug_messages_flag           in varchar2,
376   p_cm_trgr_typ_cd                in varchar2,
377   p_cm_typ_id                     in number,
378   p_age_fctr_id                   in number,
379   p_min_age                       in number,
380   p_max_age                       in number,
381   p_los_fctr_id                   in number,
382   p_min_los                       in number,
383   p_max_los                       in number,
384   p_cmbn_age_los_fctr_id          in number,
385   p_min_cmbn                      in number,
386   p_max_cmbn                      in number,
387   p_date_from                     in date,
388   p_elig_enrol_cd                 in varchar2,
389   p_actn_typ_id                   in number,
390   p_use_fctr_to_sel_flag          in varchar2,
391   p_los_det_to_use_cd             in varchar2,
392   p_audit_log_flag                in varchar2,
393   p_lmt_prpnip_by_org_flag        in varchar2,
394   p_lf_evt_ocrd_dt                in date,
395   p_ptnl_ler_for_per_stat_cd      in varchar2,
396 	p_bft_attribute_category        in varchar2,
397 	p_bft_attribute1                in varchar2,
398 	p_bft_attribute3                in varchar2,
399 	p_bft_attribute4                in varchar2,
400 	p_bft_attribute5                in varchar2,
401 	p_bft_attribute6                in varchar2,
402 	p_bft_attribute7                in varchar2,
403 	p_bft_attribute8                in varchar2,
404 	p_bft_attribute9                in varchar2,
405 	p_bft_attribute10               in varchar2,
406 	p_bft_attribute11               in varchar2,
407 	p_bft_attribute12               in varchar2,
408 	p_bft_attribute13               in varchar2,
409 	p_bft_attribute14               in varchar2,
410 	p_bft_attribute15               in varchar2,
411 	p_bft_attribute16               in varchar2,
412 	p_bft_attribute17               in varchar2,
413 	p_bft_attribute18               in varchar2,
414 	p_bft_attribute19               in varchar2,
415 	p_bft_attribute20               in varchar2,
416 	p_bft_attribute21               in varchar2,
417 	p_bft_attribute22               in varchar2,
418 	p_bft_attribute23               in varchar2,
419 	p_bft_attribute24               in varchar2,
420 	p_bft_attribute25               in varchar2,
421 	p_bft_attribute26               in varchar2,
422 	p_bft_attribute27               in varchar2,
423 	p_bft_attribute28               in varchar2,
424 	p_bft_attribute29               in varchar2,
425 	p_bft_attribute30               in varchar2,
426   p_request_id                    in number,
427   p_program_application_id        in number,
428   p_program_id                    in number,
429   p_program_update_date           in date,
430 	p_object_version_number         in number,
431 	p_enrt_perd_id                  in number,
432 	p_inelg_action_cd               in varchar2,
433 	p_org_hierarchy_id               in number,
434 	p_org_starting_node_id               in number,
435 	p_grade_ladder_id               in number,
436 	p_asg_events_to_all_sel_dt               in varchar2,
437 	p_rate_id               in number,
438 	p_per_sel_dt_cd               in varchar2,
439 	p_per_sel_freq_cd               in varchar2,
440 	p_per_sel_dt_from               in date,
441 	p_per_sel_dt_to               in date,
442 	p_year_from               in number,
443 	p_year_to               in number,
444 	p_cagr_id               in number,
445 	p_qual_type               in number,
446 	p_qual_status               in varchar2,
447 	p_concat_segs               in varchar2,
448   p_grant_price_val               in number
449 	)
450 	Return g_rec_type;
451 --
452 end ben_bft_shd;