All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ajanta.naming.URN

java.lang.Object
   |
   +----ajanta.naming.URN

public class URN
extends Object
implements Serializable
The Uniform Resource Name scheme is used for location idependent naming. Syntax of URN is defined as RFC2141 ::= "urn:" ":" NID is Namespace Identifier NSS is Namespace Specific String ::= '%" | "/" | "?" | "#" Note: following two URN are lexically equivalent URN:foo:a123,456 urn:FOO:a123,456


Constructor Index

 o URN(String)
This constructor takes a string and parse it to fill the URN structure

Method Index

 o equals(Object)
Checks equiality of the passed object with this object.
 o getCreationDomain()
Return the string representation of the creation domain.
 o getCreationDomainURN()
Return the the creation domain.
 o getNamingAuthority()
Returns the naming authoruty for this URN.
 o getNID()
Return the NID part of the URN
 o getNSS()
Return the NSS part of the URN
 o hashCode()
hashCode of the URN
 o toString()
Returns a string representation of the URN

Constructors

 o URN
 public URN(String urn) throws MalformedURNException
This constructor takes a string and parse it to fill the URN structure

Parameters:
urn - - string representation of a URN

Methods

 o getNSS
 public String getNSS()
Return the NSS part of the URN

Returns:
a string that represent the NSS( NameSpace Specific String)
 o getNID
 public String getNID()
Return the NID part of the URN

Returns:
a string that represent the NID ( NameSpace Identifier)
 o getNamingAuthority
 public URN getNamingAuthority()
Returns the naming authoruty for this URN. Currently it is the string before the last slash of the NSS

Returns:
the URN of its naming authority
 o getCreationDomain
 public String getCreationDomain()
Return the string representation of the creation domain. In our URN, the first component of the NSS is the creation domain

Returns:
the first componnent of NSS as creation domain, if there is only one component the NSS is the creation domain
 o getCreationDomainURN
 public URN getCreationDomainURN()
Return the the creation domain. In our URN, the first component of the NSS is the creation domain

Returns:
URN first componnent of NSS as creation domain, if there is only one component the NSS is the creation domain
 o toString
 public String toString()
Returns a string representation of the URN

Returns:
a string representation of the URN
Overrides:
toString in class Object
 o equals
 public boolean equals(Object obj)
Checks equiality of the passed object with this object. Note: the NID is case insensitive. The following two URN are equivalent URN:foo:a123,456 urn:FOO:a123,456

Returns:
true is equal false otherwise
Overrides:
equals in class Object
 o hashCode
 public int hashCode()
hashCode of the URN

Returns:
int value of the hashCode of this URN
Overrides:
hashCode in class Object

All Packages  Class Hierarchy  This Package  Previous  Next  Index