|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.geotools.feature.NameImpl
public class NameImpl
Simple implementation of Name.
This class emulates QName, and is used as the implementation of both AttributeName and TypeName (so when the API settles down we should have a quick fix.
Its is advantageous to us to be able to:
It case it is not obvious this is a value object and equality is based on namespace and name.
Field Summary | |
---|---|
protected java.lang.String |
local
local part |
protected java.lang.String |
namespace
namespace / scope |
Constructor Summary | |
---|---|
NameImpl(java.lang.String local)
Constructs an instance with the local part set. |
|
NameImpl(java.lang.String namespace,
java.lang.String local)
Constructs an instance with the local part and namespace set. |
|
NameImpl(java.lang.String namespace,
java.lang.String separator,
java.lang.String local)
Constructs an instance with the local part and namespace set. |
Method Summary | |
---|---|
int |
compareTo(NameImpl other)
|
boolean |
equals(java.lang.Object obj)
value object with equality based on name and namespace. |
java.lang.String |
getLocalPart()
|
java.lang.String |
getNamespaceURI()
|
java.lang.String |
getSeparator()
|
java.lang.String |
getURI()
|
int |
hashCode()
Returns a hash code value for this operand. |
boolean |
isGlobal()
|
java.lang.String |
toString()
name or namespace:name |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.lang.String namespace
protected java.lang.String local
Constructor Detail |
---|
public NameImpl(java.lang.String local)
local
- The local part of the name.public NameImpl(java.lang.String namespace, java.lang.String local)
namespace
- The namespace or scope of the name.local
- The local part of the name.public NameImpl(java.lang.String namespace, java.lang.String separator, java.lang.String local)
namespace
- The namespace or scope of the name.local
- The local part of the name.Method Detail |
---|
public boolean isGlobal()
isGlobal
in interface org.opengis.feature.type.Name
public java.lang.String getSeparator()
getSeparator
in interface org.opengis.feature.type.Name
public java.lang.String getNamespaceURI()
getNamespaceURI
in interface org.opengis.feature.type.Name
public java.lang.String getLocalPart()
getLocalPart
in interface org.opengis.feature.type.Name
public java.lang.String getURI()
getURI
in interface org.opengis.feature.type.Name
public int hashCode()
hashCode
in interface org.opengis.feature.type.Name
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in interface org.opengis.feature.type.Name
equals
in class java.lang.Object
public java.lang.String toString()
toString
in interface org.opengis.feature.type.Name
toString
in class java.lang.Object
public int compareTo(NameImpl other)
compareTo
in interface java.lang.Comparable<NameImpl>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |