public class TemplateNode extends BasePermissionsNode implements org.alfresco.service.namespace.NamespacePrefixResolverProvider
The class exposes Node properties, children as dynamically populated maps and lists.
Various helper methods are provided to access common and useful node variables such as the content url and type information.
See http://wiki.alfresco.com/wiki/Template_Guide
Modifier and Type | Class and Description |
---|---|
class |
TemplateNode.TemplateAuditInfo |
BaseContentNode.TemplateContentData
Modifier and Type | Field and Description |
---|---|
protected org.alfresco.service.cmr.repository.NodeRef |
nodeRef
Cached values
|
aspects, children, CONTENT_DOWNLOAD_PROP_URL, CONTENT_DOWNLOAD_URL, CONTENT_GET_PROP_URL, CONTENT_GET_URL, CONTENT_SERVICE_GET_PROP_URL, CONTENT_SERVICE_GET_URL, FOLDER_BROWSE_URL, imageResolver, NAMESPACE_BEGIN, services
Constructor and Description |
---|
TemplateNode(org.alfresco.service.cmr.repository.NodeRef nodeRef,
ServiceRegistry services,
TemplateImageResolver resolver)
Constructor
|
Modifier and Type | Method and Description |
---|---|
java.util.Map |
getAssociations() |
java.util.Map |
getAssocs() |
java.util.List |
getAuditTrail() |
java.util.Map |
getChildAssociations() |
java.util.Map |
getChildAssocs() |
java.util.List |
getChildAssocsByType(java.lang.String type) |
java.util.Map |
getChildByNamePath() |
java.util.Map |
getChildrenByLuceneSearch() |
java.util.Map |
getChildrenBySavedSearch() |
java.util.Map |
getChildrenByXPath() |
boolean |
getExists() |
java.lang.String |
getId() |
TemplateImageResolver |
getImageResolver() |
boolean |
getIsCategory() |
boolean |
getIsLocked() |
boolean |
getIsWorkingCopy() |
java.lang.String |
getName() |
org.alfresco.service.namespace.NamespacePrefixResolver |
getNamespacePrefixResolver() |
java.util.Map |
getNodeByReference() |
org.alfresco.service.cmr.repository.NodeRef |
getNodeRef() |
TemplateProperties |
getParent() |
java.lang.String |
getParentTypeShort() |
org.alfresco.service.cmr.repository.ChildAssociationRef |
getPrimaryParentAssoc() |
java.util.Map |
getProperties() |
java.lang.String |
getShareUrl()
This method returns a URL string which resolves to an Alfresco Share view of this node.
|
java.util.Map |
getSourceAssociations() |
java.util.Map |
getSourceAssocs() |
java.lang.String |
getStoreId() |
java.lang.String |
getStoreType() |
org.alfresco.service.namespace.QName |
getType() |
java.lang.String |
getTypeShort() |
java.util.List |
getVersionHistory() |
freemarker.ext.dom.NodeModel |
getXmlNodeModel() |
getDirectPermissions, getFullPermissions, getInheritsPermissions, getPermissions, hasPermission
getAspects, getChildren, getContent, getDisplayMimetype, getDisplayPath, getDownloadUrl, getEncoding, getHasChildren, getIcon16, getIcon32, getIcon64, getIsContainer, getIsDocument, getIsLinkToContainer, getIsLinkToDocument, getMimetype, getQnamePath, getServiceUrl, getSiteShortName, getSize, getUrl, getWebdavUrl, hasAspect, isTemplateContent, isTemplateNodeRef, toString
public TemplateNode(org.alfresco.service.cmr.repository.NodeRef nodeRef, ServiceRegistry services, TemplateImageResolver resolver)
nodeRef
- The NodeRef this Node wrapper representsservices
- The ServiceRegistry the TemplateNode can use to access servicesresolver
- Image resolver to use to retrieve iconspublic java.lang.String getId()
getId
in interface TemplateNodeRef
public java.lang.String getStoreType()
public java.lang.String getStoreId()
public org.alfresco.service.cmr.repository.NodeRef getNodeRef()
getNodeRef
in interface TemplateNodeRef
public boolean getExists()
true
if this node still existspublic boolean getIsWorkingCopy()
true
if this node is a working copypublic org.alfresco.service.namespace.QName getType()
getType
in interface TemplateNodeRef
public java.lang.String getParentTypeShort()
public java.lang.String getTypeShort()
public java.lang.String getName()
getName
in interface TemplateNodeRef
public java.util.Map getProperties()
getProperties
in interface TemplateProperties
public java.util.Map getAssocs()
public java.util.Map getAssociations()
public java.util.Map getSourceAssocs()
public java.util.Map getSourceAssociations()
public java.util.Map getChildAssocs()
public java.util.Map getChildAssociations()
public java.util.List getChildAssocsByType(java.lang.String type)
public boolean getIsLocked()
public boolean getIsCategory()
public TemplateProperties getParent()
getParent
in interface TemplateProperties
public org.alfresco.service.cmr.repository.ChildAssociationRef getPrimaryParentAssoc()
public java.util.List getVersionHistory()
VersionHistoryNode
public freemarker.ext.dom.NodeModel getXmlNodeModel()
public java.util.Map getChildByNamePath()
public java.util.Map getChildrenByXPath()
public java.util.Map getChildrenBySavedSearch()
public java.util.Map getChildrenByLuceneSearch()
public java.util.Map getNodeByReference()
public java.util.List getAuditTrail()
public TemplateImageResolver getImageResolver()
public java.lang.String getShareUrl()
sysAdminParams
bean must have been configured.
Currently this method only produces valid URls for documents and not for folders.public org.alfresco.service.namespace.NamespacePrefixResolver getNamespacePrefixResolver()
getNamespacePrefixResolver
in interface org.alfresco.service.namespace.NamespacePrefixResolverProvider
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.