DBA Data[Home] [Help]

PACKAGE: APPS.FND_PROFILE_SERVER

Source


1 package FND_PROFILE_SERVER AUTHID CURRENT_USER as
2 /* $Header: AFPFPRSS.pls 115.0 99/07/16 23:25:55 porting ship  $ */
3 
4 /*
5 ** PUT - sets a profile option to a value for this session,
6 **       but doesn't save to the database
7 */
8 procedure PUT(NAME in varchar2, VAL in varchar2);
9 pragma restrict_references(PUT, WNDS, RNDS);
10 
11 /*
12 ** DEFINED - returns TRUE if a profile option has been stored
13 */
14 function  DEFINED(NAME in varchar2) return boolean;
15 pragma restrict_references(DEFINED, WNDS);
16 
17 /*
18 ** GET - gets the value of a profile option
19 */
20 procedure GET(NAME in varchar2, VAL out varchar2);
21 pragma restrict_references(GET, WNDS);
22 
23 /*
24 ** VALUE - returns the value of a profile options
25 */
26 function  VALUE(NAME in varchar2) return varchar2;
27 pragma restrict_references(VALUE, WNDS);
28 
29 /*
30 ** VALUE_WNPS - returns the value of a profile option without caching it.
31 **
32 **            The main usage for this routine would be in a SELECT statement
33 **            where VALUE() is not allowed since it writes package state.
34 **
35 **            This routine does the same thing as VALUE(); it returns
36 **            a profile value from the profile cache, or from the database
37 **            if it isn't already in the profile cache already.  The only
38 **            difference between this and VALUE() is that this will not
39 **            put the value into the cache if it is not already there, so
40 **            repeated calls to this can be slower because it will have
41 **            to hit the database each time for the profile value.
42 **
43 **            In most cases, however, you can and should use VALUE() instead
44 **            of VALUE_WNPS(), because VALUE() will give better performance.
45 */
46 function  VALUE_WNPS(NAME in varchar2) return varchar2;
47 pragma restrict_references(VALUE_WNPS, WNDS, WNPS);
48 
49 
50 /*
51 ** SAVE_USER - Sets the value of a profile option permanently
52 **             to the database, at the user level for the current user.
53 **             Also saves in the profile cache for this database session.
54 **             Note that this will not save in the profile caches
55 **             for any other database sessions that may be up, so those
56 **             could potentially be out of sync. This routine will not
57 **             actually commit the changes; the caller must commit.
58 **
59 **  returns: TRUE if successful, FALSE if failure.
60 **
61 */
62 function SAVE_USER(
63 		   X_NAME in varchar2,  /* Profile name you are setting */
64 		   X_VALUE in varchar2 /* Profile value you are setting */
65 ) return boolean;
66 
67 /*
68 ** SAVE - sets the value of a profile option permanently
69 **        to the database, at any level.  This routine can be used
70 **        at runtime or during patching.  This routine will not
71 **        actually commit the changes; the caller must commit.
72 **        ('SITE', 'APPL', 'RESP', or 'USER').
73 **        Examples of use:
74 **        FND_PROFILE.SAVE('P_NAME', 'P_VAL', 'SITE');
75 **        FND_PROFILE.SAVE('P_NAME', 'P_VAL', 'APPL', 321532);
76 **        FND_PROFILE.SAVE('P_NAME', 'P_VAL', 'RESP', 321532, 345234);
77 **        FND_PROFILE.SAVE('P_NAME', 'P_VAL', 'USER', 123321);
78 **
79 **  returns: TRUE if successful, FALSE if failure.
80 **
81 */
82 function SAVE(X_NAME in varchar2,  /* Profile name you are setting */
83 		   X_VALUE in varchar2, /* Profile value you are setting */
84                X_LEVEL_NAME in varchar2,/* Level that youre setting at: */
85 				      /* 'SITE', 'APPL', 'RESP', or 'USER' */
86 		   X_LEVEL_VALUE in varchar2 default NULL,
87                   /* Level value that you are setting at. */
88                   /*  e.g. user id for 'USER' level.  */
89                   /* X_LEVEL_VALUE is not used at site level. */
90                X_LEVEL_VALUE_APP_ID in varchar2 default NULL
91 					    /* Only used for 'RESP' level; */
92 					    /* Resp Application_Dd. */
93 ) return boolean;
94 
95 /*
96 ** GET_SPECIFIC - Get profile value for a specific user/resp/appl combo
97 **   Default is user/resp/appl is current login.
98 */
99 procedure GET_SPECIFIC(NAME_Z              in varchar2,
100                        USER_ID_Z           in number default null,
101                        RESPONSIBILITY_ID_Z in number default null,
102                        APPLICATION_ID_Z    in number default null,
103                        VAL_Z               out varchar2,
104                        DEFINED_Z           out boolean);
105 pragma restrict_references(GET_SPECIFIC, WNDS, WNPS);
106 
107 /*
108 ** VALUE_SPECIFIC - Get profile value for a specific user/resp/appl combo
109 **   Default is user/resp/appl is current login.
110 */
111 function VALUE_SPECIFIC(NAME              in varchar2,
112                         USER_ID           in number default null,
113                         RESPONSIBILITY_ID in number default null,
114                         APPLICATION_ID    in number default null)
115 return varchar2;
116 pragma restrict_references(VALUE_SPECIFIC, WNDS, WNPS);
117 
118 end FND_PROFILE_SERVER;