Class DefaultLinkFactory
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
-
- org.ametys.plugins.repository.jcr.DefaultTraversableAmetysObjectFactory
-
- org.ametys.plugins.linkdirectory.repository.DefaultLinkFactory
-
- All Implemented Interfaces:
AmetysObjectFactory<SimpleAmetysObject>,JCRAmetysObjectFactory<SimpleAmetysObject>,Component,Configurable,LogEnabled,Serviceable
public class DefaultLinkFactory extends DefaultTraversableAmetysObjectFactory
Factory which createsLinkobjects, which represent a link entry in the directory.
-
-
Field Summary
Fields Modifier and Type Field Description private LinkDataTypeExtensionPoint_linkDataTypeExtensionPointstatic StringLINK_NODE_TYPEThe link node type.static StringLINK_ROOT_NODE_TYPEThe link container node type.-
Fields inherited from class org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
_ametysFactoryExtensionPoint, _manager, _nodetype, _repository, _resolver, _scheme
-
-
Constructor Summary
Constructors Constructor Description DefaultLinkFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DefaultLinkgetAmetysObject(Node node, String parentPath)Creates aAmetysObjectfrom a persistent JCR node.LinkDataTypeExtensionPointgetLinkDataTypeExtensionPoint()Returns the extension point holding allRepositoryElementTypeclasses for links.voidservice(ServiceManager manager)-
Methods inherited from class org.ametys.plugins.repository.jcr.DefaultTraversableAmetysObjectFactory
createChild, getChild, getChildren, hasChild
-
Methods inherited from class org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
configure, getAmetysObjectById, getAmetysObjectById, getNode, getNodetypes, getParent, getScheme, getWorkspaceNode, hasAmetysObjectForId
-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
-
-
-
Field Detail
-
LINK_ROOT_NODE_TYPE
public static final String LINK_ROOT_NODE_TYPE
The link container node type.- See Also:
- Constant Field Values
-
LINK_NODE_TYPE
public static final String LINK_NODE_TYPE
The link node type.- See Also:
- Constant Field Values
-
_linkDataTypeExtensionPoint
private LinkDataTypeExtensionPoint _linkDataTypeExtensionPoint
-
-
Constructor Detail
-
DefaultLinkFactory
public DefaultLinkFactory()
-
-
Method Detail
-
service
public void service(ServiceManager manager) throws ServiceException
- Specified by:
servicein interfaceServiceable- Overrides:
servicein classSimpleAmetysObjectFactory- Throws:
ServiceException
-
getAmetysObject
public DefaultLink getAmetysObject(Node node, String parentPath) throws AmetysRepositoryException
Description copied from interface:JCRAmetysObjectFactoryCreates aAmetysObjectfrom a persistent JCR node.- Specified by:
getAmetysObjectin interfaceJCRAmetysObjectFactory<SimpleAmetysObject>- Overrides:
getAmetysObjectin classDefaultTraversableAmetysObjectFactory- Parameters:
node- the JCR node to use.parentPath- the parent Path in the Ametys hierarchy, may benullif not known yet.- Returns:
- the object.
- Throws:
AmetysRepositoryException- if an error occurs.
-
getLinkDataTypeExtensionPoint
public LinkDataTypeExtensionPoint getLinkDataTypeExtensionPoint()
Returns the extension point holding allRepositoryElementTypeclasses for links.- Returns:
- the extension point holding all
RepositoryElementTypeclasses for links.
-
-