|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.geotools.util.GenericName
org.geotools.util.ScopedName
public class ScopedName
Fully qualified identifier for an object.
A ScopedName
contains a LocalName
as
head and a GenericName,
which may be a LocalName
or an other ScopedName
,
as tail.
NameFactory
,
Serialized FormField Summary |
---|
Fields inherited from class org.geotools.util.GenericName |
---|
DEFAULT_SEPARATOR |
Constructor Summary | |
---|---|
ScopedName(org.opengis.util.GenericName scope,
char separator,
java.lang.CharSequence name)
Constructs a scoped name from the specified international string. |
|
ScopedName(org.opengis.util.GenericName scope,
java.lang.CharSequence name)
Constructs a scoped name from the specified international string. |
Method Summary | |
---|---|
org.opengis.util.ScopedName |
asScopedName()
Deprecated. Replaced by toFullyQualifiedName() . |
boolean |
equals(java.lang.Object object)
Compares this scoped name with the specified object for equality. |
java.util.List<org.opengis.util.LocalName> |
getParsedNames()
Returns the sequence of local name for this generic name. |
org.opengis.util.GenericName |
getScope()
Deprecated. Replaced by GenericName.scope() . |
char |
getSeparator()
Returns the separator character. |
int |
hashCode()
Returns a hash code value for this generic name. |
org.opengis.util.LocalName |
head()
Returns the head of this scoped name. |
org.opengis.util.GenericName |
path()
Returns a name which contains every element of the parsed names list except for the last element. |
org.opengis.util.ScopedName |
push(org.opengis.util.GenericName scope)
Returns this name expanded with the specified scope. |
org.opengis.util.GenericName |
tail()
Returns the tail of this scoped name. |
org.opengis.util.LocalName |
tip()
Returns a view of this object as a local name. |
org.opengis.util.GenericName |
toFullyQualifiedName()
Returns a view of this name as a fully-qualified name. |
Methods inherited from class org.geotools.util.GenericName |
---|
asLocalName, compareTo, depth, name, scope, toInternationalString, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.opengis.util.ScopedName |
---|
toString |
Methods inherited from interface org.opengis.util.GenericName |
---|
depth, name, scope, toInternationalString |
Methods inherited from interface java.lang.Comparable |
---|
compareTo |
Constructor Detail |
---|
public ScopedName(org.opengis.util.GenericName scope, java.lang.CharSequence name)
InternationalString
, then the
toString(null)
method will be used in order to fetch an unlocalized name. Otherwise, the
toString()
method will be used.
scope
- The scope (or "tail") of the variable.name
- The head (never null
).public ScopedName(org.opengis.util.GenericName scope, char separator, java.lang.CharSequence name)
InternationalString
, then the
toString(null)
method will be used in order to fetch an unlocalized name. Otherwise, the
toString()
method will be used.
scope
- The scope (or "tail") of the variable.separator
- The separator character (usually ':'
or '/'
).name
- The head (never null
).Method Detail |
---|
public org.opengis.util.LocalName head()
head().scope() == this.scope()
head
in interface org.opengis.util.GenericName
head
in interface org.opengis.util.ScopedName
head
in class GenericName
public org.opengis.util.GenericName tail()
tail().getParsedNames() == this.getParsedNames().sublist(1,end)
Note: This condition can be understood in terms of the Java
equals
method instead of the Java identity
comparator ==
.
tail
in interface org.opengis.util.ScopedName
public org.opengis.util.GenericName path()
path
in interface org.opengis.util.ScopedName
File.getPath()
@Deprecated public org.opengis.util.GenericName getScope()
GenericName.scope()
.
getScope
in class GenericName
public char getSeparator()
@Deprecated public org.opengis.util.ScopedName asScopedName()
toFullyQualifiedName()
.
this
.
asScopedName
in class GenericName
public org.opengis.util.LocalName tip()
LocalName.toString()
will differs.
tip
in interface org.opengis.util.GenericName
tip
in interface org.opengis.util.ScopedName
tip
in class GenericName
public java.util.List<org.opengis.util.LocalName> getParsedNames()
getParsedNames
in interface org.opengis.util.GenericName
getParsedNames
in class GenericName
public org.opengis.util.GenericName toFullyQualifiedName()
null
.
toFullyQualifiedName
in interface org.opengis.util.GenericName
public org.opengis.util.ScopedName push(org.opengis.util.GenericName scope)
name
with this
. In pseudo-code,
the following relationships must hold:
push(name).getParsedList() ==
name.getParsedList().addAll(getParsedNames())
push(name).scope() == name.GenericName.scope()
push(head()).tail() == this
Note: Those conditions can be understood in terms of the Java
equals
method instead of the Java identity comparator ==
.
push
in interface org.opengis.util.GenericName
public boolean equals(java.lang.Object object)
equals
in class GenericName
object
- The object to compare with this name.
true
if the given object is equals to this one.public int hashCode()
hashCode
in class GenericName
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |