Interface Config


  • public interface Config
    The model interface that represents the configuration for an Asset Share Commons "site". Most of these configurations are derived via the configurations set on the Search Page's Page Properties.
    • Method Detail

      • getRequest

        org.apache.sling.api.SlingHttpServletRequest getRequest()
        Returns:
        the SlingHttpServletRequest that resolves to this Config object.
      • getResourceResolver

        org.apache.sling.api.resource.ResourceResolver getResourceResolver()
        Returns:
        the ResourceResolver that resolved this Config object.
      • getProperties

        org.apache.sling.api.resource.ValueMap getProperties()
      • getLocale

        Locale getLocale()
        Returns:
        the Locale for the Page that resolves to this Config object.
      • getRootPath

        String getRootPath()
        Returns:
        the absolute path Path to the resource resource (cq:Page) that resolves to this Config object.
      • getPlaceholderAsset

        AssetModel getPlaceholderAsset()
        Returns:
        the asset model representing the Placeholder asset for this Config. The Placeholder AssetModel is used for authoring purposes in contexts where there is no natural asset to display.
      • getAssetDetailsSelector

        String getAssetDetailsSelector()
        Returns:
        the ID of the AssetDetailsSelector implementation to use.
      • getAssetDetailsPath

        String getAssetDetailsPath()
        Returns:
        the absolute path to the main asset details page; asset-type specific details pages will exist under this.
      • getAssetDetailsUrl

        String getAssetDetailsUrl()
        Returns:
        the path segment of the URL to call to render the main asset details page.
      • getAssetDetailReferenceById

        default boolean getAssetDetailReferenceById()
        Returns:
        true if the asset details pages should reference assets by path (else ID).
      • getCartActionUrl

        String getCartActionUrl()
        Returns:
        the path segment of the URL to call to render the Cart.
      • getDownloadActionUrl

        String getDownloadActionUrl()
        Returns:
        the path segment of the URL to call to render the Download action.
      • getDownloadsActionUrl

        String getDownloadsActionUrl()
        Returns:
        the path segment of the URL to call to render the Downloads action.
      • getLicenseActionUrl

        String getLicenseActionUrl()
        Returns:
        the path segment of the URL to call to render the License Agreement action.
      • getShareActionUrl

        String getShareActionUrl()
        Returns:
        the path segment of the URL to call to render the Share action.
      • isCartEnabled

        boolean isCartEnabled()
        Returns:
        true if the cart is enabled.
      • isDownloadEnabled

        boolean isDownloadEnabled()
        Returns:
        true if the download action is enabled for asset card and asset details page.
      • isDownloadEnabledCart

        boolean isDownloadEnabledCart()
        Returns:
        true if the download action is enabled in the cart.
      • isLicenseEnabled

        boolean isLicenseEnabled()
        Returns:
        true if the license action is enabled.
      • isShareEnabled

        boolean isShareEnabled()
        Returns:
        true if the share action is enabled for asset card and asset details page.
      • isShareEnabledCart

        boolean isShareEnabledCart()
        Returns:
        true if the share action is enabled in the cart.
      • isAemClassic

        default boolean isAemClassic()
        Default assume AEM as a Cloud Service.
        Returns:
        true if targeting 6.5, false if targetting AEM as a Cloud Service
      • isContextHubEnabled

        default boolean isContextHubEnabled()
        Checks if AEM ContextHub has been configured. If it has we can load the ContextHub JS
        Returns:
        true if ContextHub is enabled for this page tree.
      • isDynamicMediaEnabled

        @Deprecated
        default boolean isDynamicMediaEnabled()
        Deprecated.
        We no longer detect Dynamic Media; Return false always.
        Returns:
        always returns false.