public class QuestionPoolTreeImpl extends Object implements Tree
| Constructor and Description |
|---|
QuestionPoolTreeImpl() |
QuestionPoolTreeImpl(QuestionPoolIteratorFacade iter)
Constucts the representation of the tree of pools.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
currentObjectIsParent()
Determine if the pool has childeren
|
Map |
getAllObjects()
Get Map of QuestionPoolImpls.
|
List |
getChildList()
List the child pool id strings
|
List |
getChildList(Long parentId)
Get a List of pools having parentId as parent
|
Map |
getChildren()
Get Map of QuestionPoolImpls retricted to childeren of the currently
selected pool Id string
|
Map |
getChildren(Long parentId)
Get Map of QuestionPoolImpls retricted to a given
Parent Id string
|
Long |
getCurrentId()
Obtain the poolId set as the current working poolId-designated node
|
String |
getCurrentLevel()
Get the current level.
|
Object |
getCurrentObject()
Get the object we're currently looking at.
|
String |
getCurrentObjectHTMLId()
Get the HTML id of the current object.
|
Collection |
getCurrentObjectProperties()
Return in order the current:
Pool Name
Author
Last Modified
Total # of Questions
Total # of Subpools
|
boolean |
getHasChildList() |
boolean |
getHasNoChildList() |
Object |
getParent()
Get the parent of the object we're currently looking at.
|
List |
getRootNodeList()
Get a List of top level pools.
|
Collection |
getSortedObjects()
Dump the tree into a long collection of objects of the form:
Pool 1
Pool 2
Pool 3
Pool 4
Pool 5
|
Collection |
getSortedObjects(Long poolId)
get sorted objects for a subpool tree
|
String |
getSortProperty()
This gets the property by which siblings will be sorted.
|
boolean |
haveCommonRoot(Long poolIdA,
Long poolIdB)
THis checks to see if given two pools have a common ancestor
|
boolean |
isDescendantOf(Long poolA,
Long poolB)
Is a pool (pool A) a descendant of the other (Pool B)?
|
int |
poolLevel(Long poolId)
This returns the level of the pool inside a pool tree, Root being 0.
|
void |
setCurrentId(Long poolId)
Set the current working poolId String, from which context relative
child lists are calculated from the poolId-designated node
|
void |
setCurrentObjectHTMLId(String param) |
void |
setPropertyMethods(String[] methods)
Set the properties to request.
|
void |
setSortProperty(String newProperty)
This sets the property by which siblings will be sorted.
|
void |
sortByProperty(String sortProperty,
boolean sortAscending) |
public QuestionPoolTreeImpl()
public QuestionPoolTreeImpl(QuestionPoolIteratorFacade iter)
iter - QuestionPoolIteratorFacade for the pools in questionpublic List getChildList(Long parentId)
getChildList in interface TreeparentId - the Id of the parent poolpublic List getRootNodeList()
getRootNodeList in interface Treepublic Object getCurrentObject()
getCurrentObject in interface Treepublic Object getParent()
public void setCurrentObjectHTMLId(String param)
public String getCurrentObjectHTMLId()
getCurrentObjectHTMLId in interface Treepublic String getCurrentLevel()
getCurrentLevel in interface Treepublic Collection getCurrentObjectProperties()
getCurrentObjectProperties in interface Treepublic void setPropertyMethods(String[] methods)
setPropertyMethods in interface Treepublic Map getAllObjects()
getAllObjects in interface Treepublic Collection getSortedObjects()
getSortedObjects in interface Treepublic Collection getSortedObjects(Long poolId)
getSortedObjects in interface Treepublic Map getChildren(Long parentId)
getChildren in interface TreeparentId - parent of all returned childrenpublic Map getChildren()
getChildren in interface Treepublic Long getCurrentId()
getCurrentId in interface Treepublic void setCurrentId(Long poolId)
setCurrentId in interface TreepoolId - public boolean currentObjectIsParent()
currentObjectIsParent in interface Treepublic List getChildList()
getChildList in interface Treepublic boolean getHasChildList()
public boolean getHasNoChildList()
public String getSortProperty()
getSortProperty in interface Treepublic void setSortProperty(String newProperty)
setSortProperty in interface Treepublic void sortByProperty(String sortProperty, boolean sortAscending)
sortByProperty in interface Treepublic boolean haveCommonRoot(Long poolIdA, Long poolIdB)
haveCommonRoot in interface Treepublic boolean isDescendantOf(Long poolA, Long poolB)
isDescendantOf in interface TreeCopyright © 2005-2014 Sakai Project. All Rights Reserved.