org.omnifaces.resourcehandler
Class ResourceIdentifier

java.lang.Object
  extended by org.omnifaces.resourcehandler.ResourceIdentifier

public class ResourceIdentifier
extends java.lang.Object

Convenience class to represent a resource identifier.

Since:
1.3
Author:
Bauke Scholtz

Constructor Summary
ResourceIdentifier(java.lang.String resourceIdentifier)
          Create a new instance based on given standard JSF resource identifier string format library:name.
ResourceIdentifier(java.lang.String library, java.lang.String name)
          Create a new instance based on given resource library and name.
 
Method Summary
 boolean equals(java.lang.Object object)
           
 java.lang.String getLibrary()
          Returns the resource library.
 java.lang.String getName()
          Returns the resource name.
 int hashCode()
           
 java.lang.String toString()
          Returns the resource identifier as string in standard JSF resource identifier format library:name.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ResourceIdentifier

public ResourceIdentifier(java.lang.String resourceIdentifier)
Create a new instance based on given standard JSF resource identifier string format library:name.

Parameters:
resourceIdentifier - The standard JSF resource identifier.

ResourceIdentifier

public ResourceIdentifier(java.lang.String library,
                          java.lang.String name)
Create a new instance based on given resource library and name.

Parameters:
library - The resource lirbary.
name - The resource name.
Method Detail

getLibrary

public java.lang.String getLibrary()
Returns the resource library.

Returns:
The resource library.

getName

public java.lang.String getName()
Returns the resource name.

Returns:
The resource name.

equals

public boolean equals(java.lang.Object object)
Overrides:
equals in class java.lang.Object

hashCode

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

toString

public java.lang.String toString()
Returns the resource identifier as string in standard JSF resource identifier format library:name. If there is no library, then only the name is returned without the colon separator like so name.

Overrides:
toString in class java.lang.Object