DBA Data[Home] [Help]

PACKAGE: APPS.HR_TIS_SHD

Source


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