Interface Service


  • public interface Service
    Represents a web service entry in context of web service configurations. A Service acts mainly as container for Configuration entries.
    Since:
    5.5
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String BASE_PATH
      Base path for service Resources.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.String getComponentReference()
      Returns a path to a related page component or null if not defined.
      Resource getContentResource()
      Returns the Resource of the services content or null if the service has no content.
      java.lang.String getDescription()
      Return jcr:description property of the service.
      java.lang.String getIconPath()
      Returns the path to an icon for this service or null if this service does not provide an icon.
      java.lang.Long getInclusionRank()
      Returns an Long value of the includsionRank property.
      java.lang.String getName()
      Returns the name of the service.
      java.lang.String getPath()
      Returns the path of the service.
      ValueMap getProperties()
      Returns a value map of the service content.
      Resource getResource()
      Returns the service Resource.
      java.lang.String[] getSelectableChildren()
      Returns an array of paths to selectable child templates.
      java.lang.String getServiceUrl()
      Returns the URL to the service or null if not defined.
      java.lang.String getServiceUrlLabel()
      Returns the URL label for the service URL link or null if not defined.
      Template getTemplate()
      Returns the pages Template or null if no template has been found or the current user does not have read access to the template resource specified by the path in the page's template property.
      java.lang.String getThumbnailPath()
      Returns the path to a thumbnail for this service or null if this service does not provide a thumbnail.
      java.lang.String getTitle()
      Return the jcr:title property of the service.
      java.lang.Boolean isSelectableChild​(java.lang.String templatePath)
      Checks if provided template path is selectable.
      java.lang.Boolean isVisible()
      Indicates if the service has the property 'visible' set to true.
    • Method Detail

      • getTitle

        java.lang.String getTitle()
        Return the jcr:title property of the service.
        Returns:
        String representation of title
      • getInclusionRank

        java.lang.Long getInclusionRank()
        Returns an Long value of the includsionRank property.
        Returns:
        Long value of rank
      • getDescription

        java.lang.String getDescription()
        Return jcr:description property of the service.
        Returns:
        String representation description
      • getName

        java.lang.String getName()
        Returns the name of the service. This is the first segment of the configuration path after the base path.
        Returns:
        String representation of name
      • getPath

        java.lang.String getPath()
        Returns the path of the service.
        Returns:
        String of service path or null
      • getComponentReference

        java.lang.String getComponentReference()
        Returns a path to a related page component or null if not defined.
        Returns:
        String of a path or null
      • getServiceUrl

        java.lang.String getServiceUrl()
        Returns the URL to the service or null if not defined.
        Returns:
        String of an URL or null
      • getServiceUrlLabel

        java.lang.String getServiceUrlLabel()
        Returns the URL label for the service URL link or null if not defined.
        Returns:
        String of a URL label or null
      • getIconPath

        java.lang.String getIconPath()
        Returns the path to an icon for this service or null if this service does not provide an icon.
        Returns:
        String of a path to an icon or null
      • getThumbnailPath

        java.lang.String getThumbnailPath()
        Returns the path to a thumbnail for this service or null if this service does not provide a thumbnail.
        Returns:
        String of a path to an icon or null
      • getTemplate

        Template getTemplate()
        Returns the pages Template or null if no template has been found or the current user does not have read access to the template resource specified by the path in the page's template property. This is the case on publish instances using default ACL configuration (anonymous cannot read templates).
        Returns:
        Page Template or null
      • getContentResource

        Resource getContentResource()
        Returns the Resource of the services content or null if the service has no content.
        Returns:
        Content Resource or null
      • getProperties

        ValueMap getProperties()
        Returns a value map of the service content. If the service has no content an empty map is returned.
        Returns:
        A ValueMap or ValueMap.EMPTY
      • getSelectableChildren

        java.lang.String[] getSelectableChildren()
        Returns an array of paths to selectable child templates.
        Returns:
        A String array of selectable template paths
      • isSelectableChild

        java.lang.Boolean isSelectableChild​(java.lang.String templatePath)
        Checks if provided template path is selectable.
        Parameters:
        templatePath - templatePath
        Returns:
        true if templatePath is selectable, false otherwise
      • isVisible

        java.lang.Boolean isVisible()
        Indicates if the service has the property 'visible' set to true. If the property is missing this method will return true.
        Returns:
        false if the property is set to false, true otherwise or if the property is missing