|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.infoglue.cms.controllers.kernel.impl.simple.BaseController
org.infoglue.cms.controllers.kernel.impl.simple.CategoryController
public class CategoryController
The CategoryController manages all actions related to persistence and querying for Categories. TODO: When we convert have Hibernate manage all of these relationships, it will pull it TODO: all back with one query and be a helluva lot faster than this pasic implementation
| Method Summary | |
|---|---|
void |
delete(java.lang.Integer id)
Deletes a CategoryVO, and all children. |
java.util.List |
findActiveByParent(java.lang.Integer parentId)
Find a List of active Categories by parent. |
java.util.List |
findAllActiveCategories()
Find a list of all Categories in the system. |
java.util.List |
findAllActiveChildren(java.lang.Integer parentId)
Finds all children for a given parent id, recursively until no children are found. |
CategoryVO |
findById(java.lang.Integer id)
Find a Category by it's identifier. |
Category |
findById(java.lang.Integer id,
org.exolab.castor.jdo.Database db)
Find a Category by it's identifier. |
java.util.List |
findByParent(java.lang.Integer parentId)
Find a List of Categories by parent. |
java.util.List |
findByParent(java.lang.Integer parentId,
org.exolab.castor.jdo.Database db)
Find a List of Categories by parent. |
CategoryVO |
findByPath(java.lang.String path)
Find a Category by it's name path. |
CategoryVO |
findByPath(java.lang.String path,
org.exolab.castor.jdo.Database db)
Find a Category by it's name path. |
java.util.List |
findRootCategories()
Find a List of Categories that have no parent. |
java.util.List |
findRootCategories(org.exolab.castor.jdo.Database db)
Find a List of Categories that have no parent. |
java.util.List |
findRootCategoryVOList(org.exolab.castor.jdo.Database db)
Find a List of Categories that have no parent. |
CategoryVO |
findWithChildren(java.lang.Integer id)
Find a Category with it's children populated. |
CategoryVO |
findWithChildren(java.lang.Integer id,
org.exolab.castor.jdo.Database db)
Find a Category with it's children populated. |
java.util.List |
getAuthorizedActiveChildren(java.lang.Integer parentId,
InfoGluePrincipal infogluePrincipal)
Finds all authorized categories parent id, recursively until no children are found. |
java.lang.String |
getCategoryPath(java.lang.Integer categoryId,
org.exolab.castor.jdo.Database db)
Gets a category's full path. |
static CategoryController |
getController()
|
boolean |
getIsAccessApproved(java.lang.Integer categoryId,
InfoGluePrincipal infoGluePrincipal)
This method returns true if the user should have access to the contentTypeDefinition sent in. |
BaseEntityVO |
getNewVO()
Implemented for BaseController |
CategoryVO |
moveCategory(java.lang.Integer categoryId,
java.lang.Integer newParentId)
Moves a CategoryVO to a different parent category |
CategoryVO |
save(CategoryVO c)
Saves a CategoryVO whether it is new or not. |
Category |
save(CategoryVO c,
org.exolab.castor.jdo.Database db)
Saves a CategoryVO whether it is new or not. |
| Methods inherited from class org.infoglue.cms.controllers.kernel.impl.simple.BaseController |
|---|
beginTransaction, beginTransaction, closeDatabase, commitTransaction, createEntity, createEntity, createQuery, deleteEntity, deleteEntity, deleteEntity, deleteEntity, executeQuery, executeQuery, executeQuery, executeQuery, getAllObjects, getAllVOObjects, getAllVOObjects, getAllVOObjects, getAllVOObjects, getObjectWithId, getObjectWithId, getObjectWithIdAsReadOnly, getVOWithId, getVOWithId, getVOWithId, getVOWithId, intercept, intercept, rollbackTransaction, toModifiableVOList, toVOList, updateEntity, updateEntity, updateEntity, updateEntity, validateEntity |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static CategoryController getController()
public CategoryVO findById(java.lang.Integer id)
throws SystemException
id - The id of the Category to find
SystemException - If an error happens
public Category findById(java.lang.Integer id,
org.exolab.castor.jdo.Database db)
throws SystemException
id - The id of the Category to find
SystemException - If an error happens
public CategoryVO findByPath(java.lang.String path)
throws SystemException
path - The path of the Category to find in the form /categoryName/categoryName/categoryName
SystemException - If an error happens
public CategoryVO findByPath(java.lang.String path,
org.exolab.castor.jdo.Database db)
throws SystemException
path - The path of the Category to find in the form /categoryName/categoryName/categoryName
SystemException - If an error happens
public java.lang.String getCategoryPath(java.lang.Integer categoryId,
org.exolab.castor.jdo.Database db)
throws SystemException
SystemException - If an error happens
public java.util.List findByParent(java.lang.Integer parentId)
throws SystemException
parentId - The parent id of the Category to find
SystemException - If an error happens
public java.util.List findByParent(java.lang.Integer parentId,
org.exolab.castor.jdo.Database db)
throws SystemException
parentId - The parent id of the Category to find
SystemException - If an error happens
public java.util.List findActiveByParent(java.lang.Integer parentId)
throws SystemException
parentId - The parent id of the Category to find
SystemException - If an error happens
public CategoryVO findWithChildren(java.lang.Integer id)
throws SystemException
id - The id of the Category to find
SystemException - If an error happens
public CategoryVO findWithChildren(java.lang.Integer id,
org.exolab.castor.jdo.Database db)
throws SystemException
id - The id of the Category to find
SystemException - If an error happens
public java.util.List findRootCategories()
throws SystemException
SystemException - If an error happens
public java.util.List findRootCategories(org.exolab.castor.jdo.Database db)
throws SystemException
SystemException - If an error happens
public java.util.List findRootCategoryVOList(org.exolab.castor.jdo.Database db)
throws SystemException
SystemException - If an error happens
public java.util.List findAllActiveCategories()
throws SystemException
SystemException - If an error happens
public java.util.List getAuthorizedActiveChildren(java.lang.Integer parentId,
InfoGluePrincipal infogluePrincipal)
throws SystemException
SystemException
public java.util.List findAllActiveChildren(java.lang.Integer parentId)
throws SystemException
SystemException
public Category save(CategoryVO c,
org.exolab.castor.jdo.Database db)
throws SystemException
c - The CategoryVO to save
SystemException - If an error happens
public CategoryVO save(CategoryVO c)
throws SystemException
c - The CategoryVO to save
SystemException - If an error happens
public CategoryVO moveCategory(java.lang.Integer categoryId,
java.lang.Integer newParentId)
throws SystemException
categoryId - The id of the CategoryVO to movenewParentId - The id of the parent to move the CategoryVO
SystemException - If an error happens
public void delete(java.lang.Integer id)
throws SystemException
id - The id of the Category to delete
SystemException - If an error happenspublic BaseEntityVO getNewVO()
getNewVO in class BaseController
public boolean getIsAccessApproved(java.lang.Integer categoryId,
InfoGluePrincipal infoGluePrincipal)
throws SystemException
SystemException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||