|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mycore.datamodel.classifications2.impl.MCRCategLinkServiceImpl
public class MCRCategLinkServiceImpl
| Constructor Summary | |
|---|---|
MCRCategLinkServiceImpl()
|
|
| Method Summary | |
|---|---|
Map<MCRCategoryID,Number> |
countLinks(MCRCategory parent,
boolean childrenOnly)
Counts links to a collection of categories. |
Map<MCRCategoryID,Number> |
countLinksForType(MCRCategory parent,
String type,
boolean childrenOnly)
Counts links to a collection of categories. |
void |
deleteLink(String id)
Delete all links that refer to the given Object ID. |
void |
deleteLinks(Collection<String> ids)
Delete all links that refer to the given collection of Object IDs. |
Collection<String> |
getLinksFromCategory(MCRCategoryID id)
Returns a list of linked Object IDs. |
Collection<String> |
getLinksFromCategoryForType(MCRCategoryID id,
String type)
Returns a list of linked Object IDs restricted by the specified type. |
Collection<MCRCategoryID> |
getLinksFromObject(String id)
Returns a list of linked categories. |
Map<MCRCategoryID,Boolean> |
hasLinks(MCRCategory category)
Checks if a categories id refered by objects. |
void |
setLinks(MCRObjectReference objectReference,
Collection<MCRCategoryID> categories)
Add links between categories and Objects. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MCRCategLinkServiceImpl()
| Method Detail |
|---|
public Map<MCRCategoryID,Number> countLinks(MCRCategory parent,
boolean childrenOnly)
MCRCategLinkService
countLinks in interface MCRCategLinkServiceparent - a subtree rooted at a MCRCategory for which links should be countedchildrenOnly - if only direct children of category should be queried (query may be more optimized)
public Map<MCRCategoryID,Number> countLinksForType(MCRCategory parent,
String type,
boolean childrenOnly)
MCRCategLinkService
countLinksForType in interface MCRCategLinkServicetype - restrict links that refer to object of this typechildrenOnly - if only direct children of category should be queried (query may be more optimized)
public void deleteLink(String id)
MCRCategLinkService
deleteLink in interface MCRCategLinkServiceid - an Object IDMCRCategLinkService.deleteLinks(Collection)public void deleteLinks(Collection<String> ids)
MCRCategLinkService
deleteLinks in interface MCRCategLinkServiceids - a collection of Object IDsMCRCategLinkService.deleteLink(String)public Collection<String> getLinksFromCategory(MCRCategoryID id)
MCRCategLinkService
getLinksFromCategory in interface MCRCategLinkServiceid - ID of the category
public Collection<String> getLinksFromCategoryForType(MCRCategoryID id,
String type)
MCRCategLinkService
getLinksFromCategoryForType in interface MCRCategLinkServiceid - ID of the categorytype - restrict links that refer to object of this type
public Collection<MCRCategoryID> getLinksFromObject(String id)
MCRCategLinkService
getLinksFromObject in interface MCRCategLinkServiceid - Object ID of a linked Object
public void setLinks(MCRObjectReference objectReference,
Collection<MCRCategoryID> categories)
MCRCategLinkService
setLinks in interface MCRCategLinkServiceobjectReference - reference to a Objectcategories - a collection of categoryIDs to be linked to#countLinks(Collection),
#countLinksForType(Collection, String)public Map<MCRCategoryID,Boolean> hasLinks(MCRCategory category)
MCRCategLinkService
hasLinks in interface MCRCategLinkServicecategory - a subtree rooted at a MCRCategory for which links should be counted
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||