DBA Data[Home] [Help]

PACKAGE: APPS.PAY_BLD_SHD

Source


1 Package pay_bld_shd as
2 /* $Header: pybldrhi.pkh 120.0 2005/05/29 03:19:37 appldev noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                    Global Record Type Specification                      |
6 -- ----------------------------------------------------------------------------
7 --
8 Type g_rec_type Is Record
9   (balance_dimension_id            number(9)
10   ,business_group_id               number(15)
11   ,legislation_code                varchar2(30)
12   ,route_id                        number(15)
13   ,database_item_suffix            varchar2(80)
14   ,dimension_name                  varchar2(80)
15   ,dimension_type                  varchar2(9)       -- Increased length
16   ,description                     varchar2(240)
17   ,feed_checking_code              varchar2(61)
18   ,legislation_subgroup            varchar2(30)
19   ,payments_flag                   varchar2(30)
20   ,expiry_checking_code            varchar2(61)
21   ,expiry_checking_level           varchar2(9)       -- Increased length
22   ,feed_checking_type              varchar2(9)       -- Increased length
23   ,dimension_level                 varchar2(30)
24   ,period_type                     varchar2(30)
25   ,asg_action_balance_dim_id       number(9)
26   ,database_item_function          varchar2(30)
27   ,save_run_balance_enabled        varchar2(30)
28   ,start_date_code                 varchar2(61)
29   );
30 --
31 -- ----------------------------------------------------------------------------
32 -- |           Global Definitions - Internal Development Use Only             |
33 -- ----------------------------------------------------------------------------
34 --
35 g_old_rec  g_rec_type;                            -- Global record definition
36 -- Global table name
37 g_tab_nam  constant varchar2(30) := 'PAY_BALANCE_DIMENSIONS';
38 --
39 -- ----------------------------------------------------------------------------
40 -- |---------------------------< constraint_error >---------------------------|
41 -- ----------------------------------------------------------------------------
42 -- {Start Of Comments}
43 --
44 -- Description:
45 --   This procedure is called when a constraint has been violated (i.e.
46 --   The exception hr_api.check_integrity_violated,
47 --   hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
48 --   hr_api.unique_integrity_violated has been raised).
49 --   The exceptions can only be raised as follows:
50 --   1) A check constraint can only be violated during an INSERT or UPDATE
51 --      dml operation.
52 --   2) A parent integrity constraint can only be violated during an
53 --      INSERT or UPDATE dml operation.
54 --   3) A child integrity constraint can only be violated during an
55 --      DELETE dml operation.
56 --   4) A unique integrity constraint can only be violated during INSERT or
57 --      UPDATE dml operation.
58 --
59 -- Prerequisites:
60 --   1) Either hr_api.check_integrity_violated,
61 --      hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
62 --      hr_api.unique_integrity_violated has been raised with the subsequent
63 --      stripping of the constraint name from the generated error message
64 --      text.
65 --   2) Standalone validation test which corresponds with a constraint error.
66 --
67 -- In Parameter:
68 --   p_constraint_name is in upper format and is just the constraint name
69 --   (e.g. not prefixed by brackets, schema owner etc).
70 --
71 -- Post Success:
72 --   Development dependant.
73 --
74 -- Post Failure:
75 --   Developement dependant.
76 --
77 -- Developer Implementation Notes:
78 --   For each constraint being checked the hr system package failure message
79 --   has been generated as a template only. These system error messages should
80 --   be modified as required (i.e. change the system failure message to a user
81 --   friendly defined error message).
82 --
83 -- Access Status:
84 --   Internal Development Use Only.
85 --
86 -- {End Of Comments}
87 -- ----------------------------------------------------------------------------
88 Procedure constraint_error
89   (p_constraint_name in all_constraints.constraint_name%TYPE);
90 --
91 -- ----------------------------------------------------------------------------
92 -- |-----------------------------< api_updating >-----------------------------|
93 -- ----------------------------------------------------------------------------
94 --  {Start Of Comments}
95 --
96 -- Description:
97 --   This function is used to populate the g_old_rec record with the
98 --   current row from the database for the specified primary key
99 --   provided that the primary key exists and is valid and does not
100 --   already match the current g_old_rec. The function will always return
101 --   a TRUE value if the g_old_rec is populated with the current row.
102 --   A FALSE value will be returned if all of the primary key arguments
103 --   are null.
104 --
105 -- Prerequisites:
106 --   None.
107 --
108 -- In Parameters:
109 --
110 -- Post Success:
111 --   A value of TRUE will be returned indiciating that the g_old_rec
112 --   is current.
113 --   A value of FALSE will be returned if all of the primary key arguments
114 --   have a null value (this indicates that the row has not be inserted into
115 --   the Schema), and therefore could never have a corresponding row.
116 --
117 -- Post Failure:
118 --   A failure can only occur under two circumstances:
119 --   1) The primary key is invalid (i.e. a row does not exist for the
120 --      specified primary key values).
121 --   2) If an object_version_number exists but is NOT the same as the current
122 --      g_old_rec value.
123 --
124 -- Developer Implementation Notes:
125 --   None.
126 --
127 -- Access Status:
128 --   Internal Development Use Only.
129 --
130 -- {End Of Comments}
131 -- ----------------------------------------------------------------------------
132 Function api_updating
133   (p_balance_dimension_id                 in     number
134   )      Return Boolean;
135 --
136 -- ----------------------------------------------------------------------------
137 -- |---------------------------------< lck >----------------------------------|
138 -- ----------------------------------------------------------------------------
139 -- {Start of comments}
140 --
141 -- Description:
142 --   The Lck process has two main functions to perform. Firstly, the row to be
143 --   updated or deleted must be locked. The locking of the row will only be
144 --   successful if the row is not currently locked by another user.
145 --   Secondly, during the locking of the row, the row is selected into
146 --   the g_old_rec data structure which enables the current row values from
147 --   the server to be available to the api.
148 --
149 -- Prerequisites:
150 --   When attempting to call the lock the object version number (if defined)
151 --   is mandatory.
152 --
153 -- In Parameters:
154 --   The arguments to the Lck process are the primary key(s) which uniquely
155 --   identify the row and the object version number of row.
156 --
157 -- Post Success:
158 --   On successful completion of the Lck process the row to be updated or
159 --   deleted will be locked and selected into the global data structure
160 --   g_old_rec.
161 --
162 -- Post Failure:
163 --   The Lck process can fail for three reasons:
164 --   1) When attempting to lock the row the row could already be locked by
165 --      another user. This will raise the HR_Api.Object_Locked exception.
166 --   2) The row which is required to be locked doesn't exist in the HR Schema.
167 --      This error is trapped and reported using the message name
168 --      'HR_7220_INVALID_PRIMARY_KEY'.
169 --   3) The row although existing in the HR Schema has a different object
170 --      version number than the object version number specified.
171 --      This error is trapped and reported using the message name
172 --      'HR_7155_OBJECT_INVALID'.
173 --
174 -- Developer Implementation Notes:
175 --   For each primary key and the object version number arguments add a
176 --   call to hr_api.mandatory_arg_error procedure to ensure that these
177 --   argument values are not null.
178 --
179 -- Access Status:
180 --   Internal Development Use Only.
181 --
182 -- {End of comments}
183 -- ----------------------------------------------------------------------------
184 Procedure lck
185   (p_balance_dimension_id                 in     number
186   );
187 --
188 -- ----------------------------------------------------------------------------
189 -- |-----------------------------< convert_args >-----------------------------|
190 -- ----------------------------------------------------------------------------
191 -- {Start Of Comments}
192 --
193 -- Description:
194 --   This function is used to turn attribute parameters into the record
195 --   structure parameter g_rec_type.
196 --
197 -- Prerequisites:
198 --   This is a private function and can only be called from the ins or upd
199 --   attribute processes.
200 --
201 -- In Parameters:
202 --
203 -- Post Success:
204 --   A returning record structure will be returned.
205 --
206 -- Post Failure:
207 --   No direct error handling is required within this function.  Any possible
208 --   errors within this function will be a PL/SQL value error due to
209 --   conversion of datatypes or data lengths.
210 --
211 -- Developer Implementation Notes:
212 --   None.
213 --
214 -- Access Status:
215 --   Internal Row Handler Use Only.
216 --
217 -- {End Of Comments}
218 -- ----------------------------------------------------------------------------
219 Function convert_args
220   (p_balance_dimension_id           in number
221   ,p_business_group_id              in number
222   ,p_legislation_code               in varchar2
223   ,p_route_id                       in number
224   ,p_database_item_suffix           in varchar2
225   ,p_dimension_name                 in varchar2
226   ,p_dimension_type                 in varchar2
227   ,p_description                    in varchar2
228   ,p_feed_checking_code             in varchar2
229   ,p_legislation_subgroup           in varchar2
230   ,p_payments_flag                  in varchar2
231   ,p_expiry_checking_code           in varchar2
232   ,p_expiry_checking_level          in varchar2
233   ,p_feed_checking_type             in varchar2
234   ,p_dimension_level                in varchar2
235   ,p_period_type                    in varchar2
236   ,p_asg_action_balance_dim_id      in number
237   ,p_database_item_function         in varchar2
238   ,p_save_run_balance_enabled       in varchar2
239   ,p_start_date_code                in varchar2
240   )
241   Return g_rec_type;
242 --
243 end pay_bld_shd;