Class Name

public class Name
{
  // Constructors
  public String getName();

  // Methods
  public static Name create(String name);
  public static Name create(char val[], int offset, int len);
  public static Name create(String name, String ns);
  public static Name create(String name, Atom nameSpace);
  public boolean equals(Object that);
  public Atom getNameSpace();
  public int hashCode();
  public String toString();
}

This is a general purpose name object to allow efficient sharing of duplicate names in the system. It does this by creating a global HashTable of all names that have been constructed. Names are different from Atoms in that they can be qualified by a separate namespace string - so in effect that are compound atoms.

Constructors

getName

public String getName();

The constructor is private because all names should be constructed using the static Name.create() methods

Methods

create 

public static Name create(String name);

Create an unqualified Name.

create 

public static Name create(char val[], int offset, int len);

create 

public static Name create(String name, String ns);

Create a Name object for the given name and namespace. The strings are case sensitive.

create 

public static Name create(String name, Atom nameSpace);

Create a Name object for the given name and namespace where the name and Namespace are already Atoms. The strings are case sensitive.

equals 

public boolean equals(Object that);

getNameSpace 

public Atom getNameSpace();

hashCode 

public int hashCode();

return the hash code for this name object

toString 

public String toString();