Class: GenericCategoryCache
Source Location: /blogs/inc/generic/model/_genericcategorycache.class.php
Class GenericCategoryCache
Class Overview
|
GenericCategoryCache class Located in /blogs/inc/generic/model/_genericcategorycache.class.php [line 52] DataObjectCache | --GenericCache | --GenericCategoryCacheAuthor(s):
|
[ Top ]
Direct descendents
Inherited Properties, Constants, and Methods
[ Top ]
Property Summary
| mixed | $loaded_subsets | Which subsets have been loaded |
| mixed | $revealed_all_children | Have the children been revealed for all subsets yet? |
| mixed | $revealed_subsets | Have the children been revealed for all subsets yet? |
| mixed | $root_cats | These are the level 0 categories (which have no parent) |
| mixed | $subset_cache | |
| mixed | $subset_property | Which property of the objects defines the subset |
| mixed | $subset_root_cats | These are the level 0 categories (which have no parent) for each subset |
[ Top ]
Method Summary
| GenericCategoryCache | GenericCategoryCache() | Constructor |
| void | add() | Add a dataobject to the cache |
| true | check_path_to_root() | Support function for reveal_children() |
| void | clear() | Empty/reset the cache |
| string | recurse() | Return recursive display of loaded categories |
| string | recurse_select() | Return recursive select options list of all loaded categories |
| void | reveal_children() | Reveal children |
[ Top ]
Properties
mixed
$revealed_all_children
= false [line 80]
Have the children been revealed for all subsets yet?
[ Top ]
mixed
$revealed_subsets
= array() [line 84]
Have the children been revealed for all subsets yet?
[ Top ]
mixed
$root_cats
= array() [line 70]
These are the level 0 categories (which have no parent)
[ Top ]
Methods
Constructor GenericCategoryCache [line 90]
|
Constructor
Parameters:| $objtype: | ||
| $load_all: | ||
| $tablename: | ||
| $prefix: | ||
| $dbIDname: | ||
| $name_field: | ||
| $subset_property: | ||
| $order_by: |
[ Top ]
add [line 116]
|
Add a dataobject to the cache
Parameters:| &$Obj: |
Redefinition of:
- DataObjectCache::add()
- Add a dataobject to the cache
[ Top ]
check_path_to_root [line 260]
|
Support function for reveal_children()
Parameters:| integer | $subset_ID: | |
| integer | $cat_ID: | |
| $path_array: |
API Tags:
| Return: | if root parent |
[ Top ]
clear [line 101]
|
Empty/reset the cache
Redefinition of:
- DataObjectCache::clear()
- Clear the cache **extensively**
Redefined in descendants as:
- ChapterCache::clear() : Empty/reset the cache
[ Top ]
recurse [line 302]
|
Return recursive display of loaded categories
Parameters:| array | $callbacks: | callback funtions (to format the display) |
| integer|NULL | $subset_ID: | NULL for all subsets |
| array | $cat_array: | categories list to display |
| int | $level: | depth of categories list |
API Tags:
| Return: | recursive list of all loaded categories |
[ Top ]
recurse_select [line 385]
|
Return recursive select options list of all loaded categories
Parameters:| integer | $selected: | selected category in the select input |
| integer | $subset_ID: | NULL for all subsets |
| boolean | $include_root: | Include the root element? |
| array | $Cat_array: | GenercCategory objects to display (will recurse from those starting points) |
| integer | $level: | depth of categories list |
| array | $exclude_array: | IDs of categories to exclude (their children will be ignored to) |
API Tags:
| Return: | select options list of all loaded categories |
[ Top ]
