Tree PREV CLASS NEXT CLASS SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD com.ibm.portal.resolver.uri
Class PortletURIjava.lang.Objectcom.ibm.portal.resolver.uri.BaseURI
com.ibm.portal.resolver.uri.PortletURI
- All Implemented Interfaces:
- Identifiable, Addressable, Constants
public class PortletURI- extends BaseURI
- implements Addressable, Constants, Identifiable
Handles URIs of the format
portlet:<portletWindowID>[@<pageID>][/<pocURIScheme>/<pocURISchemeSpecificPart>]in case there are '@' signs in the portletWindowID or pageID they must be escaped using URL escaping. pocURI does not need to be escaped specifically. The IDs can either be serialized objectIDs or unique names.
- Since:
- 6.1.0.1
Field Summary
Fields inherited from class com.ibm.portal.resolver.uri.BaseURI NULL_FACTORY
Fields inherited from interface com.ibm.portal.resolver.data.Addressable EMPTY_PARAMETERS
Fields inherited from interface com.ibm.portal.resolver.uri.Constants ESCAPE_CHAR, ESCAPE_STRG
Constructor Summary PortletURI(java.net.URI portletURI, Identification id)
Tokenizes the uri into the components that make up a portlet URIPortletURI(java.net.URI portletURI, Identification id, PocURIFactory uriFct)
Tokenizes the uri into the components that make up a portlet URI
Method Summary boolean equals(java.lang.Object obj)
ObjectID getObjectID()
Return the object ID of the portlet windowObjectID getPageID()
Return the objectID of the pagejava.util.Map<java.lang.String,java.lang.String[]> getParameters()
Returns an potentially unmodifiable version of the parameters used to address the object, never null, but potentially the empty map.java.net.URI getPocURI()
ObjectID getPortletWindowID()
Deprecated. use getObjectID() instead, since the URI not always contains portlet window IDsjava.net.URI getURI()
Return the unique identifier of the object.int hashCode()
static java.net.URI newInstance(Identifiable resourceID, Identifiable pageID, java.net.URI pocURI, Identification id, PocURIFactory uriFct)
Constructs a new URI that matches the pattern of a portlet URI.static java.net.URI newInstance(Identifiable resourceID, java.net.URI pocURI, Identification id, PocURIFactory aFactory)
Constructs a new URI that matches the pattern of a portlet URI.static java.net.URI newInstance(ObjectID resourceID, ObjectID pageID, java.net.URI pocURI, Identification id)
Constructs a new URI that matches the pattern of a portlet URI.static java.net.URI newInstance(ObjectID resourceID, ObjectID pageID, java.net.URI pocURI, Identification id, PocURIFactory uriFct)
Constructs a new URI that matches the pattern of a portlet URI.static java.net.URI newInstance(ObjectID resourceID, java.net.URI pocURI, Identification id)
Constructs a new URI that matches the pattern of a portlet URI.static java.net.URI newInstance(ObjectID resourceID, java.net.URI pocURI, Identification id, PocURIFactory uriFct)
Constructs a new URI that matches the pattern of a portlet URI.java.net.URI newInstance(java.net.URI aPocURI)
Construct a portlet URI with the same portlet ID but a new POC URIjava.lang.String toString()
java.net.URI toURI()
Return the URI version of this portlet URI
Methods inherited from class com.ibm.portal.resolver.uri.BaseURI createURI, createURI, createURI, createURI, decode, decode, decode, decode, encode, encode, normalizeRawSchemeSpecificPart, normalizeRawSchemeSpecificPart
Methods inherited from class java.lang.Object clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Constructor Detail PortletURI
public PortletURI(java.net.URI portletURI, Identification id) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Tokenizes the uri into the components that make up a portlet URI
- Parameters:
- portletURI - uri to decode
- id - identification service used for string deserialization
- Throws:
- SerializationException - for errors during the serialization or deserialization of object IDs.
- java.net.URISyntaxException - if a POCURI is available and if this URI is not a valid URI
- java.io.IOException - for errors during the decoding process
PortletURI
public PortletURI(java.net.URI portletURI, Identification id, PocURIFactory uriFct) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Tokenizes the uri into the components that make up a portlet URI
- Parameters:
- portletURI - uri to decode
- id - identification service used for string deserialization
- Throws:
- SerializationException - for errors during the serialization or deserialization of object IDs.
- java.net.URISyntaxException - if a POCURI is available and if this URI is not a valid URI
- java.io.IOException - for errors during the decoding process
Method Detail newInstance
public static final java.net.URI newInstance(Identifiable resourceID, Identifiable pageID, java.net.URI pocURI, Identification id, PocURIFactory uriFct) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Constructs a new URI that matches the pattern of a portlet URI.
- Parameters:
- resourceID - objectID to the portlet window, must not be null
- pageID - objectID of the page that contains the portlet window, may be null
- pocURI - pocURI, potentially null
- id - identification service used for the serialization of the objectIDs
- Returns:
- URI to the portlet
- Throws:
- SerializationException
- SerializationException
- java.net.URISyntaxException
- java.net.URISyntaxException
- java.io.IOException
- java.io.IOException
newInstance
public static final java.net.URI newInstance(Identifiable resourceID, java.net.URI pocURI, Identification id, PocURIFactory aFactory) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Constructs a new URI that matches the pattern of a portlet URI.
- Parameters:
- resourceID - objectID to the portlet window, must not be null
- pocURI - pocURI, potentially null
- id - identification service used for the serialization of the objectIDs
- Returns:
- URI to the portlet
- Throws:
- SerializationException
- java.net.URISyntaxException
- java.io.IOException
- Since:
- 8.5
newInstance
public static final java.net.URI newInstance(ObjectID resourceID, ObjectID pageID, java.net.URI pocURI, Identification id) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Constructs a new URI that matches the pattern of a portlet URI.
- Parameters:
- resourceID - objectID to the portlet window, must not be null
- pageID - objectID of the page that contains the portlet window, may be null
- pocURI - pocURI, potentially null
- id - identification service used for the serialization of the objectIDs
- Returns:
- URI to the portlet
- Throws:
- SerializationException
- SerializationException
- java.net.URISyntaxException
- java.net.URISyntaxException
- java.io.IOException
- java.io.IOException
newInstance
public static final java.net.URI newInstance(ObjectID resourceID, ObjectID pageID, java.net.URI pocURI, Identification id, PocURIFactory uriFct) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Constructs a new URI that matches the pattern of a portlet URI.
- Parameters:
- resourceID - objectID to the portlet window, must not be null
- pageID - objectID of the page that contains the portlet window, may be null
- pocURI - pocURI, potentially null
- id - identification service used for the serialization of the objectIDs
- Returns:
- URI to the portlet
- Throws:
- SerializationException
- SerializationException
- java.net.URISyntaxException
- java.net.URISyntaxException
- java.io.IOException
- java.io.IOException
newInstance
public static final java.net.URI newInstance(ObjectID resourceID, java.net.URI pocURI, Identification id) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Constructs a new URI that matches the pattern of a portlet URI.
- Parameters:
- resourceID - objectID to the portlet window, must not be null
- pocURI - pocURI, potentially null
- id - identification service used for the serialization of the objectIDs
- Returns:
- URI to the portlet
- Throws:
- SerializationException
- java.net.URISyntaxException
- java.io.IOException
- Since:
- 6.1.0.1
newInstance
public static final java.net.URI newInstance(ObjectID resourceID, java.net.URI pocURI, Identification id, PocURIFactory uriFct) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Constructs a new URI that matches the pattern of a portlet URI.
- Parameters:
- resourceID - objectID to the portlet window, must not be null
- pocURI - pocURI, potentially null
- id - identification service used for the serialization of the objectIDs
- Returns:
- URI to the portlet
- Throws:
- SerializationException
- java.net.URISyntaxException
- java.io.IOException
- Since:
- 8.5
equals
public boolean equals(java.lang.Object obj)
- Overrides:
- equals in class java.lang.Object
getObjectID
public ObjectID getObjectID()
- Returns the object ID of the portlet window
- Specified by:
- getObjectID in interface Identifiable
- Returns:
- the ObjectID of this resource, this can never be null
- See Also:
- Identifiable.getObjectID()
getPageID
public ObjectID getPageID()
- Returns the objectID of the page
- Returns:
- the page ID, may be null
getParameters
public java.util.Map<java.lang.String,java.lang.String[]> getParameters()
- Description copied from interface: Addressable
Returns an potentially unmodifiable version of the parameters used to address the object, never null, but potentially the empty map.
The key is of type String, the values of type String[]
- Specified by:
- getParameters in interface Addressable
- Returns:
- parameter map
getPocURI
public java.net.URI getPocURI()
- Returns:
- the POC URI, may be null
getPortletWindowID
@Deprecated public ObjectID getPortletWindowID()
- Deprecated. use getObjectID() instead, since the URI not always contains portlet window IDs
- Returns the objectID of the portlet window.
- Returns:
- the window ID, never null
getURI
public java.net.URI getURI()
- Description copied from interface: Addressable
- Returns the unique identifier of the object. The URI must contain valid scheme information and cannot be just a relative URL.
- Specified by:
- getURI in interface Addressable
- Returns:
- URI of the object, never null.
hashCode
public int hashCode()
- Overrides:
- hashCode in class java.lang.Object
newInstance
public java.net.URI newInstance(java.net.URI aPocURI) throws SerializationException, java.net.URISyntaxException, java.io.IOException
- Construct a portlet URI with the same portlet ID but a new POC URI
- Parameters:
- aPocURI - the new poc URI
- Returns:
- the new URI
- Throws:
- java.net.URISyntaxException
- SerializationException
- java.io.IOException
- Since:
- 6.1.0.3
toString
public java.lang.String toString()
- Overrides:
- toString in class java.lang.Object
toURI
public java.net.URI toURI()
- Returns the URI version of this portlet URI
- Returns:
- the URI
- Since:
- 6.1.0.3
Tree PREV CLASS NEXT CLASS SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD