@Immutable public class DefaultScopedName extends AbstractName implements ScopedName
DefaultScopedName
can be instantiated by any of the following methods:
DefaultNameFactory.createGenericName(NameSpace, CharSequence[])
with an array of length 2 or moreDefaultNameFactory.parseGenericName(NameSpace, CharSequence)
with at least one separatorDefined in the sis-utility module
Modifier | Constructor and Description |
---|---|
protected |
DefaultScopedName(GenericName path,
GenericName tail)
Constructs a scoped name as the concatenation of the given generic names.
|
protected |
DefaultScopedName(NameSpace scope,
List<? extends CharSequence> names)
Constructs a scoped name from the specified list of strings.
|
Modifier and Type | Method and Description |
---|---|
List<? extends LocalName> |
getParsedNames()
Returns the sequence of local name for this generic name.
|
GenericName |
path()
Returns every element in the sequence of parsed names
except for the tip.
|
NameSpace |
scope()
Returns the scope (name space) in which this name is local.
|
GenericName |
tail()
Returns every elements in the sequence of parsed names
except for the head.
|
castOrCopy, compareTo, depth, equals, hashCode, head, push, tip, toFullyQualifiedName, toInternationalString, toString
head, tip, toString
depth, push, toFullyQualifiedName, toInternationalString
compareTo
protected DefaultScopedName(NameSpace scope, List<? extends CharSequence> names)
InternationalString
, then its
toString(Locale.ROOT)
method will be invoked for fetching an unlocalized name.
Otherwise the CharSequence.toString()
method will be used.scope
- The scope of this name, or null
for the global scope.names
- The local names. This list must have at least two elements.protected DefaultScopedName(GenericName path, GenericName tail)
path
argument.path
- The first part to concatenate.tail
- The second part to concatenate.public NameSpace scope()
"org.opengis.util.Record"
and if this instance is the "util.Record"
part, then its scope is
named "org.opengis"
.
Continuing with the above example, the full "org.opengis.util.Record"
name has
no scope. If this method is invoked on such name, then the SIS implementation returns a
global scope instance (i.e. an instance for which DefaultNameSpace.isGlobal()
returns true
) which is unique and named "global"
.
scope
in interface GenericName
scope
in class AbstractName
public GenericName tail()
tail
in interface ScopedName
public GenericName path()
path
in interface ScopedName
public List<? extends LocalName> getParsedNames()
getParsedNames
in interface GenericName
getParsedNames
in class AbstractName
null
neither empty.Copyright © 2010–2013 The Apache Software Foundation. All rights reserved.