Package org.opengis.example.util
Class SimpleName.Scoped
- Object
-
- SimpleName
-
- Scoped
-
- All Implemented Interfaces:
Serializable
,Comparable<GenericName>
,GenericName
,ScopedName
- Enclosing class:
- SimpleName
public static class SimpleName.Scoped extends SimpleName implements ScopedName
AScopedName
specialization ofSimpleName
. The JNDI name wrapped by this class shall contain more than one component.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class SimpleName
SimpleName.Local, SimpleName.Member, SimpleName.Scoped, SimpleName.Type
-
-
Field Summary
-
Fields inherited from class SimpleName
name
-
-
Constructor Summary
Constructors Constructor Description Scoped(SimpleNameSpace scope, Name name)
Creates a new instance backed by the given JNDI name.
-
Method Summary
Modifier and Type Method Description GenericName
path()
Returns every elements of the parsed names list except for the tip.GenericName
tail()
Returns every elements of the parsed names list except for the head.-
Methods inherited from class SimpleName
compareTo, depth, equals, getParsedNames, hashCode, head, jndiName, push, scope, tip, toFullyQualifiedName, toInternationalString, toString
-
Methods inherited from interface GenericName
compareTo, depth, getParsedNames, push, scope, toFullyQualifiedName, toInternationalString
-
Methods inherited from interface ScopedName
head, tip, toString
-
-
-
-
Constructor Detail
-
Scoped
public Scoped(SimpleNameSpace scope, Name name) throws IllegalArgumentException
Creates a new instance backed by the given JNDI name. This constructor does not clone the given JNDI name. While this implementation is robust to change in the wrapped object, it is a better practice to keep the JNDI name unmodified afterSimpleName
construction.- Parameters:
scope
- the scope (name space) in which the given name is local, ornull
.name
- the JNDI name wrapped by thisSimpleName
(not cloned).- Throws:
IllegalArgumentException
- if the given name has less than 2 components.
-
-
Method Detail
-
tail
public GenericName tail()
Returns every elements of the parsed names list except for the head. This implementation creates a new generic name from the JNDI name suffix.- Specified by:
tail
in interfaceScopedName
- See Also:
Name.getSuffix(int)
-
path
public GenericName path()
Returns every elements of the parsed names list except for the tip. This implementation creates a new generic name from the JNDI name prefix.- Specified by:
path
in interfaceScopedName
- See Also:
Name.getPrefix(int)
-
-