Content Repository : content_folder
Content folders contain related content items and allow content managers to group content as they see fit. Within a content folder, content items must have unique names since this is where they will be served from. For example within the folder "movies" (served from "/movies") all items must have unique names, such as: "terminator," "terminator2" (served from "/movies/terminator, "/movies/terminator2" respectively).
Returns the item ID of the index page of the folder, null otherwise
Author: | Michael Pih | |||
---|---|---|---|---|
Returns: | The item ID of the index page | |||
Parameters: | ||||
|
||||
Declaration: | ||||
function get_index_page ( folder_id in cr_folders.folder_id%TYPE ) return cr_items.item_id%TYPE; |
Returns the label for the folder. This function is the default name method for the folder object.
Author: | Karl Goldstein | |||
---|---|---|---|---|
Returns: | The folder's label | |||
Parameters: | ||||
|
||||
Declaration: | ||||
function get_label ( folder_id in cr_folders.folder_id%TYPE ) return cr_folders.label%TYPE; | ||||
See Also: | acs_object_type.create_type, the docs for the name_method parameter |
Determine if the folder is empty
Author: | Karl Goldstein | |||
---|---|---|---|---|
Returns: | 't' if the folder contains no subfolders or items, 'f' otherwise | |||
Parameters: | ||||
|
||||
Declaration: | ||||
function is_empty ( folder_id in cr_folders.folder_id%TYPE ) return varchar2; | ||||
See Also: | content_folder.is_folder |
Determine if the item is a folder
Author: | Karl Goldstein | |||
---|---|---|---|---|
Returns: | 't' if the item is a folder, 'f' otherwise | |||
Parameters: | ||||
|
||||
Declaration: | ||||
function is_folder ( item_id in cr_items.item_id%TYPE ) return char; | ||||
See Also: | content_folder.new, content_folder.is_sub_folder |
change this to is_type_registered Determines if a content type is registered to the folder Only items of the registered type(s) may be added to the folder.
Author: | Karl Goldstein | |||||||||
---|---|---|---|---|---|---|---|---|---|---|
Returns: | 't' if the type is registered to this folder, 'f' otherwise | |||||||||
Parameters: | ||||||||||
|
||||||||||
Declaration: | ||||||||||
function is_registered ( folder_id in cr_folders.folder_id%TYPE, content_type in cr_folder_type_map.content_type%TYPE, include_subtypes in varchar2 default 'f' ) return varchar2; | ||||||||||
See Also: | content_folder.register_content_type, content_folder.unregister_content_type, |
Determine if the item target_folder_id is a subfolder of the item folder_id
Author: | Karl Goldstein | ||||||
---|---|---|---|---|---|---|---|
Returns: | 't' if the item target_folder_id is a subfolder of the item folder_id, 'f' otherwise | ||||||
Parameters: | |||||||
|
|||||||
Declaration: | |||||||
function is_sub_folder ( folder_id in cr_folders.folder_id%TYPE, target_folder_id in cr_folders.folder_id%TYPE ) return char; | |||||||
See Also: | content_folder.is_folder |
Create a new folder
Author: | Karl Goldstein | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Returns: | The id of the newly created folder | ||||||||||||||||||||||||
Parameters: | |||||||||||||||||||||||||
|
|||||||||||||||||||||||||
Declaration: | |||||||||||||||||||||||||
function new ( name in cr_items.name%TYPE, label in cr_folders.label%TYPE, description in cr_folders.description%TYPE default null, parent_id in acs_objects.context_id%TYPE default null, folder_id in cr_folders.folder_id%TYPE default null, creation_date in acs_objects.creation_date%TYPE default sysdate, creation_user in acs_objects.creation_user%TYPE default null, creation_ip in acs_objects.creation_ip%TYPE default null ) return cr_folders.folder_id%TYPE; | |||||||||||||||||||||||||
See Also: | acs_object.new, content_item.new |
Recursively copy the folder and all items in into a new location. An error is thrown if either of the parameters is not a folder. The root folder of the sitemap and the root folder of the templates cannot be copied
Author: | Karl Goldstein | ||||||
---|---|---|---|---|---|---|---|
Parameters: | |||||||
|
|||||||
Declaration: | |||||||
procedure copy ( folder_id in cr_folders.folder_id%TYPE, target_folder_id in cr_folders.folder_id%TYPE ); | |||||||
See Also: | content_folder.new, content_folder.copy |
Delete a folder. An error is thrown if the folder is not empty
Author: | Karl Goldstein | |||
---|---|---|---|---|
Parameters: | ||||
|
||||
Declaration: | ||||
procedure delete ( folder_id in cr_folders.folder_id%TYPE ); | ||||
See Also: | acs_object.delete, content_item.delete |
Recursively move the folder and all items in into a new location. An error is thrown if either of the parameters is not a folder. The root folder of the sitemap and the root folder of the templates cannot be moved.
Author: | Karl Goldstein | ||||||
---|---|---|---|---|---|---|---|
Parameters: | |||||||
|
|||||||
Declaration: | |||||||
procedure move ( folder_id in cr_folders.folder_id%TYPE, target_folder_id in cr_folders.folder_id%TYPE ); | |||||||
See Also: | content_folder.new, content_folder.copy |
Register a content type to the folder, if it is not already registered. Only items of the registered type(s) may be added to the folder.
Author: | Karl Goldstein | ||||||
---|---|---|---|---|---|---|---|
Parameters: | |||||||
|
|||||||
Declaration: | |||||||
procedure register_content_type ( folder_id in cr_folders.folder_id%TYPE, content_type in cr_folder_type_map.content_type%TYPE, include_subtypes in varchar2 default 'f' ); | |||||||
See Also: | content_folder.unregister_content_type, content_folder.is_registered |
Change the name, label and/or description of the folder
Author: | Karl Goldstein | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Parameters: | |||||||||||||
|
|||||||||||||
Declaration: | |||||||||||||
procedure rename ( folder_id in cr_folders.folder_id%TYPE, name in cr_items.name%TYPE default null, label in cr_folders.label%TYPE default null, description in cr_folders.description%TYPE default null ); | |||||||||||||
See Also: | content_folder.new |
Unregister a content type from the folder, if it has been registered. Only items of the registered type(s) may be added to the folder. If the folder already contains items of the type to be unregistered, the items remain in the folder.
Author: | Karl Goldstein | |||||||||
---|---|---|---|---|---|---|---|---|---|---|
Parameters: | ||||||||||
|
||||||||||
Declaration: | ||||||||||
procedure unregister_content_type ( folder_id in cr_folders.folder_id%TYPE, content_type in cr_folder_type_map.content_type%TYPE, include_subtypes in varchar2 default 'f' ); | ||||||||||
See Also: | content_folder.register_content_type, content_folder.is_registered |
Last Modified: $Id: folder.html,v 1.1.1.1 2002/07/09 17:34:56 rmello Exp $