DBA Data[Home] [Help]

PACKAGE: APPS.PAY_SBT_SHD

Source


1 Package pay_sbt_shd AUTHID CURRENT_USER as
2 /* $Header: pysbtrhi.pkh 115.5 2003/05/14 12:14:51 scchakra ship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                    Global Record Type Specification                      |
6 -- ----------------------------------------------------------------------------
7 --
8 Type g_rec_type Is Record
9   (
10   balance_type_id                   number(9),
11   template_id                       number(9),
12   assignment_remuneration_flag      varchar2(30),
13   balance_name                      varchar2(80),
14   balance_uom                       varchar2(30),
15   currency_code                     varchar2(15),
16   comments                          varchar2(240),    -- pseudo column
17   reporting_name                    varchar2(80),
18   attribute_category                varchar2(30),
19   attribute1                        varchar2(150),
20   attribute2                        varchar2(150),
21   attribute3                        varchar2(150),
22   attribute4                        varchar2(150),
23   attribute5                        varchar2(150),
24   attribute6                        varchar2(150),
25   attribute7                        varchar2(150),
26   attribute8                        varchar2(150),
27   attribute9                        varchar2(150),
28   attribute10                       varchar2(150),
29   attribute11                       varchar2(150),
30   attribute12                       varchar2(150),
31   attribute13                       varchar2(150),
32   attribute14                       varchar2(150),
33   attribute15                       varchar2(150),
34   attribute16                       varchar2(150),
35   attribute17                       varchar2(150),
36   attribute18                       varchar2(150),
37   attribute19                       varchar2(150),
38   attribute20                       varchar2(150),
39   jurisdiction_level                number(9),        -- Increased length
40   tax_type                          varchar2(30),
41   exclusion_rule_id                 number(9),
42   object_version_number             number(9),
43   category_name                     varchar2(30),
44   base_balance_type_id              number(9),
45   base_balance_name                 varchar2(80),
46   input_value_id                    number(9)
47   );
48 --
49 -- ----------------------------------------------------------------------------
50 -- |           Global Definitions - Internal Development Use Only             |
51 -- ----------------------------------------------------------------------------
52 --
53 g_old_rec  g_rec_type;                            -- Global record definition
54 --
55 -- ----------------------------------------------------------------------------
56 -- |---------------------------< constraint_error >---------------------------|
57 -- ----------------------------------------------------------------------------
58 -- {Start Of Comments}
59 --
60 -- Description:
61 --   This procedure is called when a constraint has been violated (i.e.
62 --   The exception hr_api.check_integrity_violated,
63 --   hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
64 --   hr_api.unique_integrity_violated has been raised).
65 --   The exceptions can only be raised as follows:
66 --   1) A check constraint can only be violated during an INSERT or UPDATE
67 --      dml operation.
68 --   2) A parent integrity constraint can only be violated during an
69 --      INSERT or UPDATE dml operation.
70 --   3) A child integrity constraint can only be violated during an
71 --      DELETE dml operation.
72 --   4) A unique integrity constraint can only be violated during INSERT or
73 --      UPDATE dml operation.
74 --
75 -- Prerequisites:
76 --   1) Either hr_api.check_integrity_violated,
77 --      hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
78 --      hr_api.unique_integrity_violated has been raised with the subsequent
79 --      stripping of the constraint name from the generated error message
80 --      text.
81 --   2) Standalone validation test which corresponds with a constraint error.
82 --
83 -- In Parameter:
84 --   p_constraint_name is in upper format and is just the constraint name
85 --   (e.g. not prefixed by brackets, schema owner etc).
86 --
87 -- Post Success:
88 --   Development dependant.
89 --
90 -- Post Failure:
91 --   Developement dependant.
92 --
93 -- Developer Implementation Notes:
94 --   For each constraint being checked the hr system package failure message
95 --   has been generated as a template only. These system error messages should
96 --   be modified as required (i.e. change the system failure message to a user
97 --   friendly defined error message).
98 --
99 -- Access Status:
100 --   Internal Development Use Only.
101 --
102 -- {End Of Comments}
103 -- ----------------------------------------------------------------------------
104 Procedure constraint_error
105             (p_constraint_name in all_constraints.constraint_name%TYPE);
106 --
107 -- ----------------------------------------------------------------------------
108 -- |-----------------------------< api_updating >-----------------------------|
109 -- ----------------------------------------------------------------------------
110 -- {Start Of Comments}
111 --
112 -- Description:
113 --   This function is used to populate the g_old_rec record with the
114 --   current row from the database for the specified primary key
115 --   provided that the primary key exists and is valid and does not
116 --   already match the current g_old_rec. The function will always return
117 --   a TRUE value if the g_old_rec is populated with the current row.
118 --   A FALSE value will be returned if all of the primary key arguments
119 --   are null.
120 --
121 -- Prerequisites:
122 --   None.
123 --
124 -- In Parameters:
125 --
126 -- Post Success:
127 --   A value of TRUE will be returned indiciating that the g_old_rec
128 --   is current.
129 --   A value of FALSE will be returned if all of the primary key arguments
130 --   have a null value (this indicates that the row has not be inserted into
131 --   the Schema), and therefore could never have a corresponding row.
132 --
133 -- Post Failure:
134 --   A failure can only occur under two circumstances:
135 --   1) The primary key is invalid (i.e. a row does not exist for the
136 --      specified primary key values).
137 --   2) If an object_version_number exists but is NOT the same as the current
138 --      g_old_rec value.
139 --
140 -- Developer Implementation Notes:
141 --   None.
142 --
143 -- Access Status:
144 --   Internal Development Use Only.
145 --
146 -- {End Of Comments}
147 -- ----------------------------------------------------------------------------
148 Function api_updating
149   (
150   p_balance_type_id                    in number,
151   p_object_version_number              in number
152   )      Return Boolean;
153 --
154 -- ----------------------------------------------------------------------------
155 -- |---------------------------------< lck >----------------------------------|
156 -- ----------------------------------------------------------------------------
157 -- {Start Of Comments}
158 --
159 -- Description:
160 --   The Lck process has two main functions to perform. Firstly, the row to be
161 --   updated or deleted must be locked. The locking of the row will only be
162 --   successful if the row is not currently locked by another user.
163 --   Secondly, during the locking of the row, the row is selected into
164 --   the g_old_rec data structure which enables the current row values from the
165 --   server to be available to the api.
166 --
167 -- Prerequisites:
168 --   When attempting to call the lock the object version number (if defined)
169 --   is mandatory.
170 --
171 -- In Parameters:
172 --   The arguments to the Lck process are the primary key(s) which uniquely
173 --   identify the row and the object version number of row.
174 --
175 -- Post Success:
176 --   On successful completion of the Lck process the row to be updated or
177 --   deleted will be locked and selected into the global data structure
178 --   g_old_rec.
179 --
180 -- Post Failure:
181 --   The Lck process can fail for three reasons:
182 --   1) When attempting to lock the row the row could already be locked by
183 --      another user. This will raise the HR_Api.Object_Locked exception.
184 --   2) The row which is required to be locked doesn't exist in the HR Schema.
185 --      This error is trapped and reported using the message name
186 --      'HR_7220_INVALID_PRIMARY_KEY'.
187 --   3) The row although existing in the HR Schema has a different object
188 --      version number than the object version number specified.
189 --      This error is trapped and reported using the message name
190 --      'HR_7155_OBJECT_INVALID'.
191 --
192 -- Developer Implementation Notes:
193 --   For each primary key and the object version number arguments add a
194 --   call to hr_api.mandatory_arg_error procedure to ensure that these
195 --   argument values are not null.
196 --
197 -- Access Status:
198 --   Internal Development Use Only.
199 --
200 -- {End Of Comments}
201 -- ----------------------------------------------------------------------------
202 Procedure lck
203   (
204   p_balance_type_id                    in number,
205   p_object_version_number              in number
206   );
207 --
208 -- ----------------------------------------------------------------------------
209 -- |-----------------------------< convert_args >-----------------------------|
210 -- ----------------------------------------------------------------------------
211 -- {Start Of Comments}
212 --
213 -- Description:
214 --   This function is used to turn attribute parameters into the record
215 --   structure parameter g_rec_type.
216 --
217 -- Prerequisites:
218 --   This is a private function and can only be called from the ins or upd
219 --   attribute processes.
220 --
221 -- In Parameters:
222 --
223 -- Post Success:
224 --   A returning record structure will be returned.
225 --
226 -- Post Failure:
227 --   No direct error handling is required within this function. Any possible
231 -- Developer Implementation Notes:
228 --   errors within this function will be a PL/SQL value error due to conversion
229 --   of datatypes or data lengths.
230 --
232 --   None.
233 --
234 -- Access Status:
235 --   Internal Row Handler Use Only.
236 --
237 -- {End Of Comments}
238 -- ----------------------------------------------------------------------------
239 Function convert_args
240 	(
241 	p_balance_type_id               in number,
242 	p_template_id                   in number,
243 	p_assignment_remuneration_flag  in varchar2,
244 	p_balance_name                  in varchar2,
245 	p_balance_uom                   in varchar2,
246 	p_currency_code                 in varchar2,
247 	p_comments                      in varchar2,
248 	p_reporting_name                in varchar2,
249 	p_attribute_category            in varchar2,
250 	p_attribute1                    in varchar2,
251 	p_attribute2                    in varchar2,
252 	p_attribute3                    in varchar2,
253 	p_attribute4                    in varchar2,
254 	p_attribute5                    in varchar2,
255 	p_attribute6                    in varchar2,
256 	p_attribute7                    in varchar2,
257 	p_attribute8                    in varchar2,
258 	p_attribute9                    in varchar2,
259 	p_attribute10                   in varchar2,
260 	p_attribute11                   in varchar2,
261 	p_attribute12                   in varchar2,
262 	p_attribute13                   in varchar2,
263 	p_attribute14                   in varchar2,
264 	p_attribute15                   in varchar2,
265 	p_attribute16                   in varchar2,
266 	p_attribute17                   in varchar2,
267 	p_attribute18                   in varchar2,
268 	p_attribute19                   in varchar2,
269 	p_attribute20                   in varchar2,
270 	p_jurisdiction_level            in number,
271 	p_tax_type                      in varchar2,
272 	p_exclusion_rule_id             in number,
273 	p_object_version_number         in number,
274         p_category_name                 in varchar2,
278 	)
275         p_base_balance_type_id          in number,
276         p_base_balance_name             in varchar2,
277         p_input_value_id                in number
279 	Return g_rec_type;
280 --
281 end pay_sbt_shd;