public abstract class AbstractPoiCategoryManager extends java.lang.Object implements PoiCategoryManager
PoiCategoryManager interface. This implementation
provides functionality for getting categories by their ID / name.| Modifier and Type | Field and Description |
|---|---|
protected java.util.Map<java.lang.Integer,PoiCategory> |
categoryMap
Maps category IDs to categories.
|
protected PoiCategory |
rootCategory
The hierarchies root category.
|
protected static java.lang.String |
SELECT_STATEMENT |
| Constructor and Description |
|---|
AbstractPoiCategoryManager() |
| Modifier and Type | Method and Description |
|---|---|
PoiCategory |
getPoiCategoryByID(int id)
Returns a category given by its ID or throws an exception if this category does not exist.
|
PoiCategory |
getPoiCategoryByTitle(java.lang.String title)
Returns a category given by unique title or throws an exception if this category does not
exist.
|
PoiCategory |
getRootCategory()
Returns the category tree's root.
|
protected static final java.lang.String SELECT_STATEMENT
protected PoiCategory rootCategory
protected java.util.Map<java.lang.Integer,PoiCategory> categoryMap
public PoiCategory getPoiCategoryByID(int id) throws UnknownPoiCategoryException
getPoiCategoryByID in interface PoiCategoryManagerid - The category's ID.UnknownPoiCategoryException - if the category has not been added to the PoiCategoryManager.public PoiCategory getPoiCategoryByTitle(java.lang.String title) throws UnknownPoiCategoryException
getPoiCategoryByTitle in interface PoiCategoryManagertitle - The category's titlec.title.equalsIgnoreCase(title).UnknownPoiCategoryException - if the category has not been added to the PoiCategoryManager.public PoiCategory getRootCategory() throws UnknownPoiCategoryException
getRootCategory in interface PoiCategoryManagerUnknownPoiCategoryException - if the category has not been added to the PoiCategoryManager.