Class PageWebResourceWithExtraParametersWrapper

  • All Implemented Interfaces:
    java.lang.Cloneable, ICacheEntry, ICloneableCacheEntry

    public class PageWebResourceWithExtraParametersWrapper
    extends PageWebResource
    PageWebResource wrapper to allow adding extra parameters in parameter map.
    Since:
    15.0.0
    Version:
    $Revision: 25303 $ $Date: 2022-10-22 22:48:02 -0300 (Sat, 22 Oct 2022) $
    • Constructor Detail

      • PageWebResourceWithExtraParametersWrapper

        public PageWebResourceWithExtraParametersWrapper​(PageWebResource pwr,
                                                         java.util.Map<java.lang.String,​java.lang.String[]> extraParameters)
        Creates a new instance.
        Parameters:
        pwr - the wrapped web resource
        extraParameters - the extra parameters
        Since:
        15.0.0
    • Method Detail

      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • getName

        public java.lang.String getName()
        Description copied from class: WebResource
        Returns the name for this web resource. The name is usually used for management display purposes.
        Overrides:
        getName in class PageWebResource
        Returns:
        this web resource's name, localized according to its locale.
        See Also:
        WebResource.getLocale()
      • getTitle

        public java.lang.String getTitle()
        Description copied from class: WebResource
        Returns the title for this web resource. The title is usually used as an end-user title.
        Overrides:
        getTitle in class PageWebResource
        Returns:
        this web resource's title, localized according to its locale.
        See Also:
        WebResource.getLocale()
      • getUrlTitle

        public java.lang.String getUrlTitle()
        Description copied from class: WebResource
        Returns the title value meant to be used for friendly URL generation of this web resource.
        Overrides:
        getUrlTitle in class PageWebResource
        Returns:
        the title value.
        See Also:
        IURLResolver
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • isCacheEnabled

        public boolean isCacheEnabled()
        Description copied from class: WebResource
        Returns if the cache is enabled for this web resource.
        Overrides:
        isCacheEnabled in class PageWebResource
        Returns:
        true if the cache is enabled, false otherwise.
      • getId

        public java.lang.String getId()
        Description copied from class: WebResource
        Returns the unique identifier for this web resource.
        Overrides:
        getId in class WebResource
        Returns:
        the unique identifier for this web resource, or null if it is not persisted.
      • getDynamicPath

        public java.lang.String getDynamicPath()
        Description copied from class: WebResource
        Returns the dynamic path to access this web resource. The dynamic path, starts with '/' and is relative to the portal web application root.
        Overrides:
        getDynamicPath in class WebResource
        Returns:
        the dynamic path for this web resource.
        See Also:
        WebResource.getFriendlyPath()
      • getParameterMap

        public java.util.Map<java.lang.String,​java.lang.String[]> getParameterMap()
        Description copied from class: WebResource
        Returns a map containing all parameters for this web resource.
        Overrides:
        getParameterMap in class PageWebResource
        Returns:
        an immutable map containing all parameters for this web resource.
      • getParent

        public WebResource getParent()
        Description copied from class: WebResource
        Returns the web resource of the parent element of this web resource.
        Overrides:
        getParent in class PageWebResource
        Returns:
        the parent of this web resource, or null if it has no parent.
      • getFriendlyPath

        public java.lang.String getFriendlyPath()
        Description copied from class: WebResource
        Returns the friendly path to access this web resource. The friendly path, if set, always starts with '/' and is relative to the portal web application root. One exception to this rule is if the friendly path corresponds to the application root, in this case an empty string is returned.

        Note that even thought a friendly path is returned, the use of friendly URL may be disabled for this web resource.

        Overrides:
        getFriendlyPath in class WebResource
        Returns:
        the friendly path or null if there is no friendly path set.
        See Also:
        WebResource.getPath()
      • getProperties

        public java.util.Map<java.lang.String,​java.util.List<java.lang.String>> getProperties()
        Description copied from class: WebResource
        Returns the properties for this web resource.
        Overrides:
        getProperties in class PageWebResource
        Returns:
        a immutable map where the key is the property name and the value is a list of the property's values.
      • getFriendlyURLPattern

        public java.lang.String getFriendlyURLPattern()
        Description copied from class: WebResource
        Returns the pattern to be used to resolve friendly URL for this web resource.

        The specific syntax or usage of the pattern is up to the IURLResolver configured for this web resource.

        Overrides:
        getFriendlyURLPattern in class WebResource
        Returns:
        the pattern.
      • getLocale

        public java.util.Locale getLocale()
        Description copied from class: WebResource
        Returns the locale for this web resource.
        Overrides:
        getLocale in class WebResource
        Returns:
        the locale.
      • getTargetId

        public java.lang.String getTargetId()
        Description copied from class: PageWebResource
        Returns the target identifier for this page web resource.
        Overrides:
        getTargetId in class PageWebResource
        Returns:
        the target identifier.
      • getCreatedDateTime

        public java.util.Date getCreatedDateTime()
        Description copied from class: WebResource
        Returns the date-time this web resource was created.
        Overrides:
        getCreatedDateTime in class WebResource
        Returns:
        the date-time this web resource was created.
      • getPageCache

        public PageCacheConfig getPageCache()
        Description copied from class: WebResource
        Returns the cache definition for this web resource.
        Overrides:
        getPageCache in class WebResource
        Returns:
        the cache object or null if this web resource does not have cache.
      • getWebsite

        public IWebsite getWebsite()
        Description copied from class: WebResource
        Returns the website this web resource belongs to.

        The full URL to access this web resource is composed by a base URL of the web site it belongs, and the path of this web resource.

        If this web resource is located in an area of portal that do not belong to any website, this method will return null.

        Overrides:
        getWebsite in class WebResource
        Returns:
        the website this web resource belongs to.
      • getPortletMode

        public javax.portlet.PortletMode getPortletMode()
        Description copied from class: PageWebResource
        Returns the portlet mode for the target in this page web resource.
        Overrides:
        getPortletMode in class PageWebResource
        Returns:
        the portlet mode.
      • getWindowState

        public javax.portlet.WindowState getWindowState()
        Description copied from class: PageWebResource
        Returns the window state for the target in this page web resource.
        Overrides:
        getWindowState in class PageWebResource
        Returns:
        the window state.
      • isPreviewModeEnabled

        public boolean isPreviewModeEnabled()
        Description copied from class: PageWebResource
        Returns true if this page web resource is being processed in preview mode.
        Overrides:
        isPreviewModeEnabled in class PageWebResource
        Returns:
        true if preview mode is enabled, false otherwise.
      • setPreviewModeEnabled

        public void setPreviewModeEnabled​(boolean previewModeEnabled)
        Description copied from class: PageWebResource
        Sets the preview mode for processing this page web resource.
        Overrides:
        setPreviewModeEnabled in class PageWebResource
        Parameters:
        previewModeEnabled - true to enable, false to disable.
      • getRunTimeServiceInstanceId

        public java.lang.String getRunTimeServiceInstanceId()
        Description copied from class: PageWebResource
        Returns the service instance identifier of the runtime service instance for this page web resource.
        Overrides:
        getRunTimeServiceInstanceId in class PageWebResource
        Returns:
        the service instance identifier, or null if this page web resource does not have a runtime service instance.
        See Also:
        ServiceInstanceConfig
      • getRunTimeServiceInterfaceId

        public java.lang.String getRunTimeServiceInterfaceId()
        Description copied from class: PageWebResource
        Returns the service interface identifier of the runtime service interface for this page web resource.
        Overrides:
        getRunTimeServiceInterfaceId in class PageWebResource
        Returns:
        the service interface identifier, or null if this page web resource does not have a runtime service interface.
        See Also:
        ServiceInterfaceConfig
      • getProject

        public IProject getProject()
                            throws PortalException
        Description copied from class: WebResource
        Returns the project this web resource belongs to (if any).
        It is important to notice that the relation webresource <-> project is not persisted. Instead, it is calculated at runtime.
        This method may require a current transaction.
        Overrides:
        getProject in class PageWebResource
        Returns:
        the project this web resource belongs to (if any).
        Throws:
        PortalException
      • isCacheEnabled

        public boolean isCacheEnabled​(boolean considerGuestOnlyCache)
        Description copied from class: WebResource
        Returns if the cache is enabled for this web resource for the current user.
        Overrides:
        isCacheEnabled in class WebResource
        Parameters:
        considerGuestOnlyCache - indicates if the result should be true even if the cache is only for guest.
        Returns:
        true if the cache is enabled, false otherwise.
      • getParameter

        public java.lang.String getParameter​(java.lang.String parameterName)
        Description copied from class: WebResource
        Returns the value of a parameter for this web resource. If the parameter has multiple values, the first is returned.
        Overrides:
        getParameter in class WebResource
        Parameters:
        parameterName - the parameter name.
        Returns:
        the value, or null if no parameter with such name exists for this web resource.
      • getParameterValues

        public java.lang.String[] getParameterValues​(java.lang.String parameterName)
        Description copied from class: WebResource
        Returns the values of a parameter for this web resource.
        Overrides:
        getParameterValues in class WebResource
        Parameters:
        parameterName - the parameter name.
        Returns:
        the values, or null if no parameter with such name exists for this web resource.
      • toString

        public java.lang.String toString()
        Description copied from class: WebResource
        Returns a string representation for debug and logging purposes.
        Overrides:
        toString in class WebResource
        Returns:
        string representation for debug and logging purposes.