gnu.text
Class Char

java.lang.Object
  extended by gnu.text.Char
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable, java.lang.Comparable

public class Char
extends java.lang.Object
implements java.lang.Comparable, java.io.Externalizable

A wrapper for characters. #author Per Bothner

See Also:
Serialized Form

Constructor Summary
Char()
          Should only be used for serialization.
 
Method Summary
 char charValue()
           
 int compareTo(java.lang.Object o)
           
 boolean equals(java.lang.Object obj)
           
 int hashCode()
           
 int intValue()
           
static Char make(int ch)
           
static int nameToChar(java.lang.String name)
           
 void readExternal(java.io.ObjectInput in)
           
 java.lang.Object readResolve()
           
static java.lang.String toScmReadableString(int ch)
           
 java.lang.String toString()
           
 void writeExternal(java.io.ObjectOutput out)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Char

public Char()
Should only be used for serialization.

Method Detail

charValue

public final char charValue()

intValue

public final int intValue()

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

make

public static Char make(int ch)

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

nameToChar

public static int nameToChar(java.lang.String name)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

toScmReadableString

public static java.lang.String toScmReadableString(int ch)

writeExternal

public void writeExternal(java.io.ObjectOutput out)
                   throws java.io.IOException
Specified by:
writeExternal in interface java.io.Externalizable
Throws:
java.io.IOException

readExternal

public void readExternal(java.io.ObjectInput in)
                  throws java.io.IOException,
                         java.lang.ClassNotFoundException
Specified by:
readExternal in interface java.io.Externalizable
Throws:
java.io.IOException
java.lang.ClassNotFoundException

readResolve

public java.lang.Object readResolve()
                             throws java.io.ObjectStreamException
Throws:
java.io.ObjectStreamException

compareTo

public int compareTo(java.lang.Object o)
Specified by:
compareTo in interface java.lang.Comparable