content-folder-procs.tcl

Tcl API for content_folders

Location:
packages/acs-content-repository/tcl/content-folder-procs.tcl
Created:
2004-05-28
Author:
Dave Bauer <dave@thedesignexperience.org>
CVS Identification:
$Id: content-folder-procs.tcl,v 1.20.2.2 2020/08/25 14:54:20 antoniop Exp $

Procedures in this file

Detailed information

content::folder::delete (public)

 content::folder::delete -folder_id folder_id [ -cascade_p cascade_p ]

Delete a content folder

Switches:
-folder_id (required)
item_id of the content_folder
-cascade_p (optional, defaults to "f")
if true delete all children, if false, return error if folder is nonempty
Returns:
Error:
Author:
Dave Bauer <dave@thedesignexperience.org>
Created:
2004-05-28

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_image content_image (test acs-content-repository) content::folder::delete content::folder::delete test_content_image->content::folder::delete test_content_item content_item (test acs-content-repository) test_content_item->content::folder::delete test_content_revision content_revision (test acs-content-repository) test_content_revision->content::folder::delete package_exec_plsql package_exec_plsql (public) content::folder::delete->package_exec_plsql

Testcases:
content_image, content_item, content_revision

content::folder::get_folder_from_package (public, deprecated)

 content::folder::get_folder_from_package -package_id package_id
Deprecated. Invoking this procedure generates a warning.

Switches:
-package_id (required)
Author:
Timo Hentschel <timo@timohentschel.de>
Created:
2005-01-06 Returns the folder_id of the package instance. Cached DEPRECATED: this proc assumes there will be just one folder for each package, which is not true in general!
See Also:
  • other packages as file-storage or xowiki define the concept of a root_folder. This is explicitly meant to be unique for each package. If your package can guarantee there will only be one folder per package, you should write your own api for it.

Partial Call Graph (max 5 caller/called nodes):
%3 ad_log_deprecated ad_log_deprecated (public) content::folder::get_folder_from_package_not_cached content::folder::get_folder_from_package_not_cached (public, deprecated) util_memoize util_memoize (public) content::folder::get_folder_from_package content::folder::get_folder_from_package content::folder::get_folder_from_package->ad_log_deprecated content::folder::get_folder_from_package->content::folder::get_folder_from_package_not_cached content::folder::get_folder_from_package->util_memoize

Testcases:
No testcase defined.

content::folder::get_folder_from_package_not_cached (public, deprecated)

 content::folder::get_folder_from_package_not_cached \
    -package_id package_id
Deprecated. Invoking this procedure generates a warning.

Switches:
-package_id (required)
Author:
Timo Hentschel <timo@timohentschel.de>
Created:
2005-01-06 Returns the folder_id of the package instance DEPRECATED: this proc assumes there will be just one folder for each package, which is not true in general!
See Also:
  • other packages as file-storage or xowiki define the concept of a root_folder. This is explicitly meant to be unique for each package. If your package can guarantee there will only be one folder per package, you should write your own api for it.

Partial Call Graph (max 5 caller/called nodes):
%3 content::folder::get_folder_from_package content::folder::get_folder_from_package (public, deprecated) content::folder::get_folder_from_package_not_cached content::folder::get_folder_from_package_not_cached content::folder::get_folder_from_package->content::folder::get_folder_from_package_not_cached ad_log_deprecated ad_log_deprecated (public) content::folder::get_folder_from_package_not_cached->ad_log_deprecated db_string db_string (public) content::folder::get_folder_from_package_not_cached->db_string

Testcases:
No testcase defined.

content::folder::get_index_page (public)

 content::folder::get_index_page -folder_id folder_id
Switches:
-folder_id (required)
Returns:
item_id of content item named "index" in folder_id

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_item content_item (test acs-content-repository) content::folder::get_index_page content::folder::get_index_page test_content_item->content::folder::get_index_page package_exec_plsql package_exec_plsql (public) content::folder::get_index_page->package_exec_plsql

Testcases:
content_item

content::folder::get_label (public)

 content::folder::get_label -folder_id folder_id
Switches:
-folder_id (required)
Returns:
label of cr_folder suitable for display

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_item content_item (test acs-content-repository) content::folder::get_label content::folder::get_label test_content_item->content::folder::get_label package_exec_plsql package_exec_plsql (public) content::folder::get_label->package_exec_plsql

Testcases:
content_item

content::folder::is_empty (public)

 content::folder::is_empty -folder_id folder_id
Switches:
-folder_id (required)
Returns:
t or f

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_item content_item (test acs-content-repository) content::folder::is_empty content::folder::is_empty test_content_item->content::folder::is_empty package_exec_plsql package_exec_plsql (public) content::folder::is_empty->package_exec_plsql

Testcases:
content_item

content::folder::is_folder (public)

 content::folder::is_folder -item_id item_id
Switches:
-item_id (required)
Returns:
t or f

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_item content_item (test acs-content-repository) content::folder::is_folder content::folder::is_folder test_content_item->content::folder::is_folder test_content_item_nested_structure content_item_nested_structure (test acs-content-repository) test_content_item_nested_structure->content::folder::is_folder package_exec_plsql package_exec_plsql (public) content::folder::is_folder->package_exec_plsql

Testcases:
content_item, content_item_nested_structure

content::folder::is_registered (public)

 content::folder::is_registered -folder_id folder_id \
    -content_type content_type [ -include_subtypes include_subtypes ]
Switches:
-folder_id (required)
-content_type (required)
-include_subtypes (optional)
Returns:
t or f

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_item content_item (test acs-content-repository) content::folder::is_registered content::folder::is_registered test_content_item->content::folder::is_registered package_exec_plsql package_exec_plsql (public) content::folder::is_registered->package_exec_plsql

Testcases:
content_item

content::folder::is_root (public)

 content::folder::is_root -folder_id folder_id
Switches:
-folder_id (required)
Returns:
t or f

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_item content_item (test acs-content-repository) content::folder::is_root content::folder::is_root test_content_item->content::folder::is_root package_exec_plsql package_exec_plsql (public) content::folder::is_root->package_exec_plsql

Testcases:
content_item

content::folder::is_sub_folder (public)

 content::folder::is_sub_folder -folder_id folder_id \
    -target_folder_id target_folder_id
Switches:
-folder_id (required)
-target_folder_id (required)
Returns:
t of f

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_folder content_folder (test acs-content-repository) content::folder::is_sub_folder content::folder::is_sub_folder test_content_folder->content::folder::is_sub_folder package_exec_plsql package_exec_plsql (public) content::folder::is_sub_folder->package_exec_plsql

Testcases:
content_folder

content::folder::new (public)

 content::folder::new -name name [ -folder_id folder_id ] \
    [ -parent_id parent_id ] [ -content_type content_type ] \
    [ -label label ] [ -description description ] \
    [ -creation_user creation_user ] [ -creation_ip creation_ip ] \
    [ -creation_date creation_date ] [ -context_id context_id ] \
    [ -package_id package_id ]
Switches:
-name (required)
-folder_id (optional)
-parent_id (optional)
-content_type (optional, defaults to "content_folder")
-label (optional)
-description (optional)
-creation_user (optional)
-creation_ip (optional)
-creation_date (optional)
-context_id (optional)
-package_id (optional)
Returns:
Error:
Author:
Dave Bauer <dave@thedesignexperience.org>
Created:
2004-05-28

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_folder content_folder (test acs-content-repository) content::folder::new content::folder::new test_content_folder->content::folder::new test_content_image content_image (test acs-content-repository) test_content_image->content::folder::new test_content_item content_item (test acs-content-repository) test_content_item->content::folder::new test_content_item_nested_structure content_item_nested_structure (test acs-content-repository) test_content_item_nested_structure->content::folder::new test_content_revision content_revision (test acs-content-repository) test_content_revision->content::folder::new package_instantiate_object package_instantiate_object (public) content::folder::new->package_instantiate_object bug_tracker::project_new bug_tracker::project_new (public) bug_tracker::project_new->content::folder::new cr_item_search::test_setup cr_item_search::test_setup (private) cr_item_search::test_setup->content::folder::new email_image::create_type_folder_rel email_image::create_type_folder_rel (public) email_image::create_type_folder_rel->content::folder::new fs::new_folder fs::new_folder (public) fs::new_folder->content::folder::new packages/file-storage/www/folder-add.tcl packages/file-storage/ www/folder-add.tcl packages/file-storage/www/folder-add.tcl->content::folder::new

Testcases:
content_folder, content_image, image_new, content_item, content_item_nested_structure, content_revision

content::folder::register_content_type (public)

 content::folder::register_content_type -folder_id folder_id \
    -content_type content_type [ -include_subtypes include_subtypes ]

Register an allowed content type for folder_id

Switches:
-folder_id (required)
folder to register type to
-content_type (required)
content_revision or subtype of content_revision
-include_subtypes (optional, defaults to "f")
t or f
Returns:
Error:
Author:
Dave Bauer <dave@thedesignexperience.org>
Created:
2004-05-29

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_extlink content_extlink (test acs-content-repository) content::folder::register_content_type content::folder::register_content_type test_content_extlink->content::folder::register_content_type test_content_folder content_folder (test acs-content-repository) test_content_folder->content::folder::register_content_type test_content_image content_image (test acs-content-repository) test_content_image->content::folder::register_content_type test_content_item content_item (test acs-content-repository) test_content_item->content::folder::register_content_type test_content_revision content_revision (test acs-content-repository) test_content_revision->content::folder::register_content_type package_exec_plsql package_exec_plsql (public) content::folder::register_content_type->package_exec_plsql bug_tracker::install::package_upgrade bug_tracker::install::package_upgrade (private) bug_tracker::install::package_upgrade->content::folder::register_content_type bug_tracker::project_new bug_tracker::project_new (public) bug_tracker::project_new->content::folder::register_content_type cr_item_search::test_setup cr_item_search::test_setup (private) cr_item_search::test_setup->content::folder::register_content_type email_image::create_type_folder_rel email_image::create_type_folder_rel (public) email_image::create_type_folder_rel->content::folder::register_content_type subsite::after_upgrade subsite::after_upgrade (private) subsite::after_upgrade->content::folder::register_content_type

Testcases:
content_extlink, content_folder, content_image, image_new, content_item, content_revision, fs_publish_file

content::folder::unregister_content_type (public)

 content::folder::unregister_content_type -folder_id folder_id \
    -content_type content_type [ -include_subtypes include_subtypes ]

Unregister an allowed content type for folder_id

Switches:
-folder_id (required)
folder to unregister type from
-content_type (required)
content_revision or subtype of content_revision
-include_subtypes (optional, defaults to "f")
t or f
Returns:
Error:
Author:
Dave Bauer <dave@thedesignexperience.org>
Created:
2004-06-04

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_image content_image (test acs-content-repository) content::folder::unregister_content_type content::folder::unregister_content_type test_content_image->content::folder::unregister_content_type test_content_revision content_revision (test acs-content-repository) test_content_revision->content::folder::unregister_content_type package_exec_plsql package_exec_plsql (public) content::folder::unregister_content_type->package_exec_plsql

Testcases:
content_image, content_revision

content::folder::update (public)

 content::folder::update -folder_id folder_id -attributes attributes

Update standard cr_folder attributes, including the attributes for the folder cr_item

Switches:
-folder_id (required)
folder to update
-attributes (required)
A list of pairs of additional attributes and their values to set. Each pair is a list of lists of two elements: key => value Valid attributes are: label, description, name, package_id
Returns:
Error:
Author:
Dave Bauer <dave@thedesignexperience.org>
Created:
2004-06-04

Partial Call Graph (max 5 caller/called nodes):
%3 test_content_folder content_folder (test acs-content-repository) content::folder::update content::folder::update test_content_folder->content::folder::update content::item::update content::item::update (public) content::folder::update->content::item::update db_dml db_dml (public) content::folder::update->db_dml Class ::xo::db::CrFolder Class ::xo::db::CrFolder (public) Class ::xo::db::CrFolder->content::folder::update packages/file-storage/www/folder-edit.tcl packages/file-storage/ www/folder-edit.tcl packages/file-storage/www/folder-edit.tcl->content::folder::update xo::db::CrFolder instproc save xo::db::CrFolder instproc save (public) xo::db::CrFolder instproc save->content::folder::update

Testcases:
content_folder
[ show source ]