DBA Data[Home] [Help]

PACKAGE: APPS.UMX_PUB

Source


1 PACKAGE UMX_PUB AUTHID CURRENT_USER AS
2 /* $Header: UMXPRRSS.pls 120.5.12010000.3 2009/07/22 20:16:23 jstyles ship $ */
3 /*#
4  * This is the public interface that provides APIs to execute various
5  * functions for the RBAC support of User Management (UMX).
6  * @rep:scope public
7  * @rep:product UMX
8  * @rep:displayname User Management Public Interface
9  * @rep:category BUSINESS_ENTITY UMX_ROLE_REG_REQUESTS
10  * @rep:category BUSINESS_ENTITY UMX_ACCT_REG_REQUESTS
11  * @rep:category BUSINESS_ENTITY UMX_ROLE
12  */
13 
14   -- Function         :  get_attribute_value
15   -- Type             :  Public
16   -- Pre_reqs         :  None
17   -- Description      :  This API, is intended to be called by the AME's Rule,
18   --                     will return the value of the registration data.
19   -- input parameters (Mandatory):
20   --   p_reg_request_id : Registration Request ID
21   --   p_attribute_name : Attribute name
22   -- Output           :
23   --   Description : Attribute value
24   --
25   /*#
26    * This API, is intended to be called by the AME's Rule,
27    * will return the value of the registration data.
28    * @param p_reg_request_id The Registration Request ID
29    * @paraminfo {@rep:required}
30    * @param p_attribute_name The name of the registration data.
31    * @paraminfo {@rep:required}
32    * @return The value of the registration data.
33    * @rep:displayname Get the value from the User Management's Registration Data.
34    * @rep:scope public
35    * @rep:lifecycle active
36    */
37   function get_attribute_value (
38     p_reg_request_id in UMX_REG_REQUESTS.REG_REQUEST_ID%TYPE,
39     p_attribute_name in varchar2
40   ) return varchar2;
41 
42   --
43   -- Procedure        :  assign_role
44   -- Type             :  Public
45   -- Pre_reqs         :  None
46   -- Description      :  This API assigns role to a user either by direct assigning or
47   --                     launching the UMX Registration Workflow process.
48   -- Input Parameters (Mandatory):
49   --   p_registration_data : Table of record type of UMX_REGISTRATION_DATA
50   -- Output Parameters:
51   --   p_registration_data : Table of record type of UMX_REGISTRATION_DATA
52   --
53   /*#
54    * This API assigns a role to a user either by direct assigning or
55    * launching the UMX Registration Workflow process.
56    * @param p_registration_data The registration data
57    * @paraminfo {@rep:required}
58    * @rep:displayname Assign Role to a User
59    * @rep:businessevent oracle.apps.fnd.umx.rolerequested
60    * @rep:businessevent oracle.apps.fnd.umx.requestapproved
61    * @rep:scope public
62    * @rep:lifecycle active
63    */
64 procedure assign_role (p_registration_data in out NOCOPY UMX_REGISTRATION_PVT.UMX_REGISTRATION_DATA_TBL);
65 
66   procedure assign_role (p_registration_data in out NOCOPY UMX_REGISTRATION_PVT.UMX_REGISTRATION_DATA_TBL
67     , x_return_status out NOCOPY varchar2
68  		, x_message_data out NOCOPY varchar2);
69 
70   --
71   -- Procedure        :  updateWfAttribute
72   -- Type             :  Public
73   -- Pre_reqs         :  None
74   -- Description      :  This API can be invoked by anyone who registers a PL/SQL subscription to
75   --                     UMX raised Business Events during registration. This API will update the main
76   -- 			 User Management workflow event(payload) object and also the corresponding
77   --			 workflow attribute. If p_attr_name doesn't exist in the workflow, one is created.
78   --                     This API can also be called by anyone who has a custom notification workflow
79   --			 defined, and want this name value pair to be reflected in the main workflow;
80   --			 this name value pair will be available to rest of subscriptions and workflow
81   --			 activities.
82   -- Input Parameters (Mandatory):
83   -- p_event : Oracle Workflow WF_EVENT_T object type
84   -- p_attr_name : Varchar2, name of the attribute, maps to workflow attribute name.
85   -- p_attr_value : varchar2, value of the attribute, maps to Workflow attribute string value.
86   -- Output Parameters:
87   -- p_event : Oracle Workflow WF_EVENT_T object type
88   --
89 /*#
90  * This API Adds or Updates an attribute to the User Management Registration
91  * workflow. This method is to be used in any synchronous subscriptions, for
92  * events raised during registration process.
93  * @param p_event WF_EVENT_T
94  * @param p_attr_name attribute name
95  * @param p_attr_value attribute value
96  * @rep:scope public
97  * @rep:lifecycle active
98  * @rep:displayname Update User Management Workflow attribute.
99  */
100   procedure updateWfAttribute (p_event in out NOCOPY WF_EVENT_T,
101   			       p_attr_name in VARCHAR2 DEFAULT NULL,
102 			       p_attr_value in VARCHAR2 DEFAULT NULL);
103 
104   --
105   -- Procedure        :  notification_process_done
106   -- Type             :  Public
107   -- Pre_reqs         :  None
108   -- Description      :  This API will restart the sleeping main workflow.
109 /*#
110  * This API signifies the end of the notification workflow, it raises an
111  * event which will restart the main User Management workflow
112  * This method should be used in the scenario of customizing the Notification
113  * workflows. This Notification workflow must have been started by the event,
114  * which was defined as part of meta-data. This method should be associated
115  * with the last activity in your notification workflow. The signature of the
116  * API is the standard API for PL/SQL procedures called by function activities.
117  * @param item_type varchar2
118  * @param item_key varchar2
119  * @param activity_id number
120  * @param command varchar2
121  * @param resultout varchar2
122  * @rep:scope public
123  * @rep:lifecycle active
124  * @rep:displayname User Management, Notification Process Done.
125  */
126   procedure Notification_Process_Done (item_type    in  varchar2,
127                                        item_key     in  varchar2,
128                                        activity_id  in  number,
129                                        command      in  varchar2,
130                                        resultout    out NOCOPY varchar2);
131 
132   --
133   -- Procedure        :  get_suggested_username
134   -- Type             :  Public
135   -- Pre_reqs         :  None
136   -- Description      :  This API will return the suggested user name for a person.
137   --                     The user name will be generated via the
138   --                     oracle.apps.fnd.umx.username.generate Business Event
139   --                     which will be raised by this API.  The event could
140   --                     return a null value as the user name if the user name
141   --                     could not be generated.
142   -- Input Parameters :
143   -- @param     p_person_party_id
144   --    Description:  Person Party ID of the person who to generate
145   --                  a username for.
146   --    Required   :  N
147   -- Output Parameters :
148   --   x_suggested_username: Username generated by the Username Policy. May return null.
149   --
150   /*#
151    * This API will return the suggested user name for a person.
152    * The user name will be generated via the
153    * oracle.apps.fnd.umx.username.generate Business Event
154    * which will be raised by this API.  The event could
155    * return a null value as the user name if the user name
156    * could not be generated.
157    * @param p_person_party_id Person Party ID of the person who to generate a username for.
158    * @param x_suggested_username Username generated by the Username Policy. May return null.
159    * @rep:displayname Generate the Suggested User Name
160    * @rep:scope public
161    * @rep:lifecycle active
162    */
163   --
164   procedure get_suggested_username (p_person_party_id    in HZ_PARTIES.PARTY_ID%TYPE default null,
165                                     x_suggested_username out nocopy FND_USER.USER_NAME%TYPE);
166 
167   --
168   -- Procedure        :  get_username_policy_desc
169   -- Type             :  Public
170   -- Pre_reqs         :  None
171   -- Description      :  This API will return the description of the user name
172   --                     policy.  The return parameters / user name policy is
173   --                     based on the UMX: User Name Policy (UMX_USERNAME_POLICY)
174   --                     profile option, which points to a LOOKUP TYPE that
175   --                     should include the following:
176   --
177   --                       LOOKUP CODES: DESCRIPTION, PROMPT, HINT
178   --
179   --                     with the appropriate LOOKUP MEANING defined. Example:
180   --
181   --                       LOOKUP TYPE: UMX_USERNAME_POLICY:EMAIL
182   --
183   --  LOOKUP CODE    MEANING                     DESCRIPTION
184   --  -----------    --------------------------  -------------------------------
185   --  PROMPT         User Name                   Prompt of the user name text
186   --                                             input field.
187   --
188   --  DESCRIPTION    User Names must be based    Description of the policy
189   --                 on Email Address
190   --
191   --  HINT           example: [email protected]  Example of what the username should
192   --                                             look like.
193   --
194   -- Input Parameters :
195   -- Output Parameters :
196   -- x_policy_code:      User Name Policy code. Preseeded policies are:
197   --
198   --                     Code: UMX_USERNAME_POLICY:EMAIL
199   --                     Meaning: User name should be defined as Email Address.
200   --                              Product teams may choose to hide the email
201   --                              field in any account creation / registration
202   --                              UI's as long as the entered username (email)
203   --                              is copied into the fnd_user.email_address field
204   --                              as well.
205   --
206   --                     Code: UMX_USERNAME_POLICY:NONE
207   --                     Meaning: No username policy / format defined, freetext
208   --
209   --                     Code: Anything else, this would be a custom policy defined
210   --                           at a client site.
211   --
212   -- x_description:      User Name Policy description. May be null. For example:
213   --
214   --                       "User Names must be based on <b>Email Address</b>".
215   --                       The description can be displayed as a quick tip in
216   --                       the user account creation/registration page.
217   --
218   -- x_prompt:           Prompt of the User Name field. Defaults to "User Name" if
219   --                     none is defined in the policy.
220   --
221   -- x_hint:             An example of the user name format. May be null. For
222   --                     example:
223   --
224   --                       "(example: [email protected])"
225   --
226   --                     The hint can be displayed as an inline hint below the
227   --                     User Name field in any user account creation/registration
228   --                     page.
229   --
230   /*#
231    * This API will return the description of the user name
232    * policy.  The return parameters / user name policy is
233    * based on the UMX: User Name Policy (UMX_USERNAME_POLICY)
234    * profile option, which points to a LOOKUP TYPE that
235    * should include the following:
236    *   LOOKUP CODES: DESCRIPTION, PROMPT, HINT
237    * with the appropriate LOOKUP MEANING defined. Example:
238    *   LOOKUP TYPE: UMX_USERNAME_POLICY:EMAIL
239    * LOOKUP CODE    MEANING                     DESCRIPTION
240    * -----------    --------------------------  -------------------------------
241    * PROMPT         User Name                   Prompt of the user name text
242    *                                             input field.
243    *
244    * DESCRIPTION    User Names must be based    Description of the policy
245    *                on Email Address
246    *
247    * HINT           example: [email protected]  Example of what the username should
248    *                                            look like.
249    * @param x_policy_code User Name Policy code. Preseeded policies are:
250    *                     Code: UMX_USERNAME_POLICY:EMAIL
251    *                     Meaning: User name should be defined as Email Address.
252    *                              Product teams may choose to hide the email
253    *                              field in any account creation / registration
254    *                              UI's as long as the entered username (email)
255    *                              is copied into the fnd_user.email_address field
256    *                              as well.
257    *
258    *                     Code: UMX_USERNAME_POLICY:NONE
259    *                     Meaning: No username policy / format defined, freetext
260    *
261    *                     Code: Anything else, this would be a custom policy defined
262    *                           at a client site.
263    *
264    * @param x_description User Name Policy description. May be null. For example:
265    *
266    *                       "User Names must be based on <b>Email Address</b>".
267    *                       The description can be displayed as a quick tip in
268    *                       the user account creation/registration page.
269    *
270    * @param x_prompt Prompt of the User Name field. Defaults to "User Name" if
271    *                     none is defined in the policy.
272    *
273    * @param x_hint An example of the user name format. May be null. For
274    *                     example:
275    *
276    *                       "(example: [email protected])"
277    *
278    *                     The hint can be displayed as an inline hint below the
279    *                     User Name field in any user account creation/registration
280    *                     page.
281    * @rep:displayname Get the User Name Policy Descriptions
282    * @rep:scope public
283    * @rep:lifecycle active
284    */
285   --
286   procedure get_username_policy_desc
287                 (x_policy_code out nocopy FND_LOOKUP_TYPES.LOOKUP_TYPE%TYPE,
288                  x_description out nocopy FND_LOOKUP_VALUES.MEANING%TYPE,
289                  x_prompt      out nocopy FND_LOOKUP_VALUES.MEANING%TYPE,
290                  x_hint        out nocopy FND_LOOKUP_VALUES.MEANING%TYPE);
291 
292  BEFORE_ACT_ACTIVATION CONSTANT VARCHAR2(30) := 'BEFORE ACCOUNT ACTIVATION';
293  AFTER_ACT_ACTIVATION CONSTANT VARCHAR2(30)  := 'AFTER ACCOUNT ACTIVATION';
294  ROLE_APPROVED CONSTANT VARCHAR2(15) := 'ROLE APPROVED';
295 END UMX_PUB;