org.jacorb.naming

Class Name

public class Name extends Object implements Serializable

A convenience class for names and converting between Names and their string representation

Version: $Id: Name.java,v 1.14 2006/06/14 11:56:28 alphonse.bendt Exp $

Author: Gerald Brose, FU Berlin

Constructor Summary
Name()
Name(NameComponent[] n)
create a name from an array of NameComponents
Name(String string_name)
create a name from a stringified name
Name(NameComponent n)
create a name from a singleNameComponent
Method Summary
NameComponentbaseNameComponent()
NameComponent[]components()
NamectxName()
booleanequals(Object obj)
NamefullName()
inthashCode()
Stringkind()
static NameComponent[]toName(String sn)
StringtoString()
static StringtoString(NameComponent[] n)

Constructor Detail

Name

public Name()

Name

public Name(NameComponent[] n)
create a name from an array of NameComponents

Name

public Name(String string_name)
create a name from a stringified name

Name

public Name(NameComponent n)
create a name from a singleNameComponent

Method Detail

baseNameComponent

public NameComponent baseNameComponent()

Returns: a NameComponent object representing the unstructured base name of this structured name

components

public NameComponent[] components()

Returns: this name as an array of org.omg.CosNaming.NameComponent, neccessary for a number of operations on naming context

ctxName

public Name ctxName()

Returns: a Name object representing the name of the enclosing context

equals

public boolean equals(Object obj)

fullName

public Name fullName()

hashCode

public int hashCode()

kind

public String kind()

toName

public static NameComponent[] toName(String sn)

Returns: an a array of NameComponents

Throws: org.omg.CosNaming.NamingContextPackage.InvalidName

toString

public String toString()

Returns: the string representation of this name

toString

public static String toString(NameComponent[] n)

Returns: the string representation of this NameComponent array