Class SymbolicChar

  • Direct Known Subclasses:
    UnknownSymbolicChar

    public class SymbolicChar
    extends java.lang.Object
    An symbolic character, that is, an object representing a single and possibly unknown character.
    • Constructor Summary

      Constructors 
      Constructor Description
      SymbolicChar​(char ch)
      Builds the symbolic character.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      char asChar()
      Converts this symbolic character to a normal character.
      boolean equals​(java.lang.Object obj)  
      int hashCode()  
      boolean is​(char ch)
      Yields true if and only if this symbolic character represent the given concrete one.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • SymbolicChar

        public SymbolicChar​(char ch)
        Builds the symbolic character.
        Parameters:
        ch - the underlying character
    • Method Detail

      • asChar

        public char asChar()
        Converts this symbolic character to a normal character.
        Returns:
        the character
      • is

        public boolean is​(char ch)
        Yields true if and only if this symbolic character represent the given concrete one.
        Parameters:
        ch - the character
        Returns:
        true if that condition holds
      • hashCode

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

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

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