org.opengis.example.util
Class SimpleName.Scoped

Object
  extended by SimpleName
      extended by SimpleName.Scoped
All Implemented Interfaces:
Serializable, Comparable<GenericName>, GenericName, ScopedName
Enclosing class:
SimpleName

public static class SimpleName.Scoped
extends SimpleName
implements ScopedName

A ScopedName specialization of SimpleName. 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
SimpleName.Scoped(SimpleNameSpace scope, Name name)
          Creates a new instance backed by the given JNDI name.
 
Method Summary
 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 class Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface ScopedName
head, tip, toString
 
Methods inherited from interface GenericName
depth, getParsedNames, push, scope, toFullyQualifiedName, toInternationalString
 
Methods inherited from interface Comparable
compareTo
 

Constructor Detail

SimpleName.Scoped

public SimpleName.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 after SimpleName construction.

Parameters:
scope - The scope (name space) in which the given name is local, or null.
name - The JNDI name wrapped by this SimpleName (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 interface ScopedName
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 interface ScopedName
See Also:
Name.getPrefix(int)


Copyright © 1994–2014 Open Geospatial Consortium. All rights reserved.