Interface IServiceInterfaceUrl

  • All Superinterfaces:
    BaseURL, PortletURL
    All Known Implementing Classes:
    ServiceContainerUrl

    @StableMinor(version="14.0",
                 sinceVersion="4.0")
    public interface IServiceInterfaceUrl
    extends PortletURL
    The ServiceInterfaceURL interface represents a URL that reference the service interface itself.

    A ServiceInterfaceURL is created through the RenderResponse. Parameters, a service interface mode, a window state and a security level can be added to ServiceInterfaceURL objects. The ServiceInterfaceURL must be converted to a String in order to embed it into the markup generated by the service interface.

    There are two types of ServiceInterfaceURLs:

    • Action URLs, they are created with RenderResponse.createActionURL, and trigger an action request followed by a render request.
    • Render URLs, they are created with RenderResponse.createRenderURL, and trigger a render request.

    The string reprensentation of a ServiceInterfaceURL does not need to be a valid URL at the time the service interface is generating its content. It may contain special tokens that will be converted to a valid URL, by the portal, before the content is returned to the client.

    Since:
    4.0.0
    Version:
    $Revision: 24477 $ $Date: 2021-04-28 11:30:36 -0300 (Wed, 28 Apr 2021) $
    • Field Detail

      • TARGET_SCOPE_PAGE

        static final int TARGET_SCOPE_PAGE
        Comment for TARGET_SCOPE_PAGE Send parameter to all interface instances in the target page.
        See Also:
        Constant Field Values
      • TARGET_SCOPE_SERVICE

        static final int TARGET_SCOPE_SERVICE
        Comment for TARGET_SCOPE_SERVICE Send parameter to all interface instances in the target page that correspond to the specified service.
        See Also:
        Constant Field Values
      • TARGET_SCOPE_SERVICEINSTANCE

        static final int TARGET_SCOPE_SERVICEINSTANCE
        Comment for TARGET_SCOPE_SERVICEINSTANCE Send parameter to all interface instances in the target page that correspond to the specified service instance.
        See Also:
        Constant Field Values
      • TARGET_SCOPE_SERVICEINTERFACE

        static final int TARGET_SCOPE_SERVICEINTERFACE
        Comment for TARGET_SCOPE_SERVICEINTERFACE Send parameter to all interface instances in the target page that correspond to the specified service interface.
        See Also:
        Constant Field Values
      • TARGET_SCOPE_SERVICEINTERFACEINSTANCE

        static final int TARGET_SCOPE_SERVICEINTERFACEINSTANCE
        Comment for TARGET_SCOPE_SERVICEINTERFACEINSTANCE Send parameter to the interface instance in the target page that corresponds to the specified interface interface.
        See Also:
        Constant Field Values
      • ACTION_URL

        static final int ACTION_URL
        Comment for ACTION_URL specifies that this url is an action url
        See Also:
        Constant Field Values
      • RENDER_URL

        static final int RENDER_URL
        Comment for RENDER_URL specifies that this url is a render url
        See Also:
        Constant Field Values
      • EXTERNAL_URL

        static final int EXTERNAL_URL
        Comment for EXTERNAL_URL specifies that this url is an external url
        See Also:
        Constant Field Values
    • Method Detail

      • getUrl

        String getUrl()
               throws PortalException
        Deprecated.
        Since 4.0.7 this method was replaced by toString() method, so this interface uses the same method as specified in the PortletURL interface.
        Returns the service interface URL string representation to be embedded in the markup.
        Note that the returned String may not be a valid URL, as it may be rewritten by the portal/service interface-container before returning the markup to the client.
        Returns:
        the encoded URL as a string
        Throws:
        PortalException
      • toString

        String toString()
        Returns the service interface URL string representation to be embedded in the markup.
        Note that the returned String may not be a valid URL, as it may be rewritten by the portal/service interface-container before returning the markup to the client.
        Specified by:
        toString in interface BaseURL
        Overrides:
        toString in class Object
        Returns:
        the encoded URL as a string
        Throws:
        PortalException
      • setPageId

        void setPageId​(String pageId)
        Set the destination page. If not specified, the destination page is assumed to be the current page
        Parameters:
        pageId -
      • setChannelId

        void setChannelId​(String channelId)
        Set the destination channel. If not specified, the destination channel is assumed to be the current channel. If the page is specified, the channel value is ignored when rendering the url.
        Parameters:
        channelId -
      • setTargetScope

        void setTargetScope​(int targetScope,
                            String targetId)
        The target scope allows the service interface to send parameters to one or more service interfaces. The target scope requires one of the possible scopes: TARGET_SCOPE_SERVICE TARGET_SCOPE_SERVICEINSTANCE TARGET_SCOPE_SERVICEINTERFACE TARGET_SCOPE_SERVICEINTERFACEINSTANCE
        Parameters:
        targetScope -
        targetId -
      • setExternalUrl

        void setExternalUrl​(String url)
        Set external url
        Parameters:
        url -
      • setRunTimeServiceInterfaceId

        void setRunTimeServiceInterfaceId​(String runTimeServiceInterfaceId)
        Sets the runtime service interface identifier. This is usually used in pop-ups that render runtime interfaces that are not previously mounted on a page.
        Parameters:
        runTimeServiceInterfaceId -
        Since:
        4.0.10
      • setRunTimeServiceInstanceId

        void setRunTimeServiceInstanceId​(String runTimeServiceInstanceId)
        Sets the runtime service instance identifier. This is usually used in pop-ups that render runtime interfaces that are not previously mounted on a page. These runtime interfaces need a serviceinstanceid to be rendered.
        Parameters:
        runTimeServiceInterfaceId -
        Since:
        4.0.10