Package org.alfresco.repo.template
Class DocumentationURLMethod
java.lang.Object
org.alfresco.repo.processor.BaseProcessorExtension
org.alfresco.repo.template.BaseTemplateProcessorExtension
org.alfresco.repo.template.DocumentationURLMethod
- All Implemented Interfaces:
freemarker.template.TemplateMethodModel,freemarker.template.TemplateMethodModelEx,freemarker.template.TemplateModel,org.alfresco.processor.ProcessorExtension,TemplateProcessorExtension
public class DocumentationURLMethod
extends BaseTemplateProcessorExtension
implements freemarker.template.TemplateMethodModelEx
-
Field Summary
Fields inherited from interface freemarker.template.TemplateModel
NOTHING -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns documentation URL.Returns default landing documentation URL.getDocumentationUrl(String topicUid, String urlComponent, String alfrescoComponent) Constructs the documentation URL using the base URL, topic UID, version, and additional component.voidsetAcsVersion(String acsVersion) voidsetAlfrescoSearchEnterpriseVersion(String alfrescoSearchEnterpriseVersion) voidsetAlfrescoSearchVersion(String alfrescoSearchVersion) voidsetDefaultDocumentationUrl(String defaultDocumentationUrl) voidsetDocumentationBaseUrl(String documentationBaseUrl) Methods inherited from class org.alfresco.repo.template.BaseTemplateProcessorExtension
getTemplateImageResolver, setTemplateImageResolverMethods inherited from class org.alfresco.repo.processor.BaseProcessorExtension
getExtensionName, register, setExtensionName, setProcessorMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.alfresco.processor.ProcessorExtension
getExtensionName
-
Constructor Details
-
DocumentationURLMethod
public DocumentationURLMethod()
-
-
Method Details
-
setDefaultDocumentationUrl
-
setAcsVersion
-
setAlfrescoSearchVersion
-
setAlfrescoSearchEnterpriseVersion
-
setDocumentationBaseUrl
-
exec
Returns documentation URL. You can specify property key which should hold value of topic uid and url component(if required). * a) If no arguments are provided, the default documentation URL is returned.${documentationUrl() -> https://support.hyland.com/p/alfrescob) First argument is interpreted as Topic UID of the URL. The value is retrieved and treated as Topic UID appended after baseURL and before version.${documentationURL("eet567890373737")} -> https://support.hyland.com/access?dita:id=eet567890373737&vrm_version=25.1c) Second argument(if required) is interpreted as an additional URL component, which will be appended to the URL to denote a specific component of Alfresco.${documentationUrl("eeu1720075126296", "&component=Alfresco%20Content%20Services%20Community%20Edition"} -> https://support.hyland.com/access?dita:id=eeu1720075126296&vrm_version=25.1&component=Alfresco%20Content%20Services%20Community%20Editiond) Third argument (if required) is interpreted as the Alfresco component (e.g., "solr", "elasticsearch", or empty) to determine which version to use in the URL.${documentationUrl("eeu1720075126296", "", "solr")} -> https://support.hyland.com/access?dita:id=eeu1720075126296&vrm_version=2.0- Specified by:
execin interfacefreemarker.template.TemplateMethodModel- Specified by:
execin interfacefreemarker.template.TemplateMethodModelEx- Parameters:
args- arguments passed to Freemarker template method invocation first argument is interpreted as Topic UID of the URL, second argument is interpreted as an additional URL component, third argument is interpreted as the Alfresco component ("solr", "elasticsearch", or empty) to select the version.- Returns:
- the documentation URL
- Throws:
freemarker.template.TemplateModelException- if an error occurs
-
getDocumentationUrl
Returns default landing documentation URL.- Returns:
- default documentation URL
-
getDocumentationUrl
Constructs the documentation URL using the base URL, topic UID, version, and additional component.- Parameters:
topicUid- path segmenturlComponent- additional URL component (may be empty)alfrescoComponent- additional Alfresco component (may be empty), to determine the version- Returns:
- full documentation URL
-