| Oracle Application Server Portal PL/SQL API Reference - 904 | |||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||
| SUMMARY: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | DETAIL: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | |||||||
This package contains procedures and functions to create a naming system for storing user-specified application preferences. These preference values can be stored at different levels: user, group, and system-wide. They can also be of different data types for the same name.
The naming system consists of a preference path and a preference name. The preference path denotes hierarchy, for example: ORACLE.TOOLS.PORTAL.PAGE
To create preference paths and names, create the path first, then create names under the path. Once created, paths and names can be deleted but they cannot be modified. For example, if the path ORACLE.TOOLS.PORTAL.STYLE exists, and a call is made to create the path ORACLE.TOOLS.PORTAL.PAGE, only the name PAGE is created.
If you delete a name from a preference path, all values associated with the name and all subordinate names and values are deleted. Deleting a preference path deletes all names and values associated with the path. You can delete partial paths. The last name in a specified path is the name that is deleted. For example,
Notes: Names in a preference path must be delimited by a period "." No preference path name may exceed 255 characters.
| Exception Summary | |
DUPLICATE_NAME_EXCEPTION | |
DUPLICATE_PATH_EXCEPTION | |
GENERAL_PREFERENCE_EXCEPTION | |
NAME_NOT_FOUND_EXCEPTION | |
PATH_NOT_FOUND_EXCEPTION | |
| Function/Procedure Summary | |
create_name | |
create_path | |
delete_name | |
delete_path | |
| Exception Detail |
DUPLICATE_NAME_EXCEPTION exception
DUPLICATE_PATH_EXCEPTION exception
GENERAL_PREFERENCE_EXCEPTION exception
NAME_NOT_FOUND_EXCEPTION exception
PATH_NOT_FOUND_EXCEPTION exception
| Function/Procedure Detail |
procedure create_name(
p_path in varchar2,
p_name in varchar2,
p_description in varchar2,
p_type_name in varchar2,
p_language in varchar2
) Constraints:
Note: If the path does not exist, create it with the wwpre_api_name.create_path procedure.
Example:
wwpre_api_name.create_name
(
p_path => 'ORACLE.PORTAL.TEST.STYLE.DEFAULT',
p_name => 'FONT_SIZE',
p_type_name => 'NUMBER',
p_description => 'Font Size for the Style',
p_language => wwctx_api.get_nls_language
);
p_path - the preference path under which the name is createdp_name - the preference name to be createp_description - a description or explanation of the preference namep_type_name - the name of the type associated with this
preferencep_language - the language in which the description should
be storedDUPLICATE_NAME_EXCEPTION - if the name already existsVALUE_ERROR - if the type is not validGENERAL_PREFERENCE_EXCEPTION - if the name is not
created
procedure create_path(
p_path in varchar2
) Call this procedure to create a new hierarchical path or to add a name to an existing hierarchical path. After creating or extending a path, call the create_name procedure to associate a preference name with the path.
Notes:
Example:
begin
wwpre_api_name.create_path
(
p_path => 'ORACLE.PORTAL.TEST'
);
end;
p_path - the preference path to be createdDUPLICATE_PATH_EXCEPTION - if a duplicate path existsGENERAL_PREFERENCE_EXCEPTION - if the path is not created
procedure delete_name(
p_path in varchar2,
p_name in varchar2
) Call this procedure to delete a specified preference name under a given path.
Note: This API deletes a name and all values associated with the name.
Example:
wwpre_api_name.delete_name
(
p_path => 'ORACLE.TOOLS.PORTAL.STYLE',
p_name => 'BGCOLOR'
);
p_path - the preference path of the name to be deletedp_name - the preference name to be deletedPATH_NOT_FOUND_EXCEPTION - if the path to be
deleted is not foundNAME_NOT_FOUND_EXCEPTION - if the name to be
deleted is not foundGENERAL_PREFERENCE_EXCEPTION - if the name is not
deleted
procedure delete_path(
p_path in varchar2
) Call this procedure to delete a preference path. The delete_path procedure deletes the specified path, the specified name and all values associated with it, and all subordinate names and values. Note that the last name specified in p_path is deleted and that names in the path must be delimited with a period ".".
For example:
- If the path to be deleted is ORACLE.PORTAL.STYLE,
and if the names associated with STYLE are BGCOLOR,
BANNERCOLOR, and PAGE_IMAGE, and if each name has a
number of values associated with it, then delete_path
deletes BGCOLOR, BANNERCOLOR, and PAGE_IMAGE and all
values associated with each name. Then it deletes STYLE
from the path.
- If the preference path to be deleted is ORACLE,
delete_path removes the entire path.
Example:
wwpre_api_name.delete_path
(
p_path => 'ORACLE.TOOLS.PORTAL.STYLE'
);
p_path - the preference path to be deletedPATH_NOT_FOUND_EXCEPTION - if the path to be
deleted is not foundGENERAL_PREFERENCE_EXCEPTION - if the path is not
deleted
| Oracle Application Server Portal PL/SQL API Reference - 904 | |||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||
| SUMMARY: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | DETAIL: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | |||||||