Generic Interpreter 1.3
Private API

gi
Class Lexicon.Match

java.lang.Object
  extended by gi.Lexicon.Expression
      extended by gi.Lexicon.Alphabet
          extended by gi.Lexicon.Match
All Implemented Interfaces:
Cloneable
Direct Known Subclasses:
Lexicon.NonMatch
Enclosing class:
Lexicon

protected static class Lexicon.Match
extends Lexicon.Alphabet

This class implements an Alphabet containing some characters.

Version:
1.3
Author:
© 1999-2009 Craig A. Rich <carich@csupomona.edu>

Field Summary
(package private)  Object A
          The Character or String representing this Alphabet.
 
Fields inherited from class gi.Lexicon.Expression
f, i
 
Constructor Summary
  Lexicon.Match(char a)
          Constructs an Alphabet containing one character, and builds the NFA constructed from this Expression.
private Lexicon.Match(Integer i, char a, Integer f)
          Constructs an Alphabet containing one character, and builds the NFA constructed from this Expression.
private Lexicon.Match(Integer i, Object A, Integer f)
          Constructs an Alphabet containing some characters, and builds the NFA constructed from this Expression.
  Lexicon.Match(Object A)
          Constructs an Alphabet containing some characters, and builds the NFA constructed from this Expression.
 
Method Summary
 Object clone()
          Creates a clone of this Alphabet, and replicates the NFA constructed from this Expression.
(package private)  boolean contains(char a)
          Indicates whether a character occurs in this Alphabet.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

A

final Object A

The Character or String representing this Alphabet.

Constructor Detail

Lexicon.Match

private Lexicon.Match(Integer i,
                      Object A,
                      Integer f)

Constructs an Alphabet containing some characters, and builds the NFA constructed from this Expression.

Parameters:
i - the initial state of the NFA constructed.
A - the Character or String of characters in this Alphabet.
f - the final state of the NFA constructed.

Lexicon.Match

private Lexicon.Match(Integer i,
                      char a,
                      Integer f)

Constructs an Alphabet containing one character, and builds the NFA constructed from this Expression.

Parameters:
i - the initial state of the NFA constructed.
a - the character in this Alphabet.
f - the final state of the NFA constructed.

Lexicon.Match

public Lexicon.Match(char a)

Constructs an Alphabet containing one character, and builds the NFA constructed from this Expression.

Parameters:
a - the character in this Alphabet.

Lexicon.Match

public Lexicon.Match(Object A)

Constructs an Alphabet containing some characters, and builds the NFA constructed from this Expression.

Parameters:
A - the Character or String of characters in this Alphabet.
Method Detail

contains

boolean contains(char a)

Indicates whether a character occurs in this Alphabet.

Specified by:
contains in class Lexicon.Alphabet
Parameters:
a - the character whose status is requested.
Returns:
true if a occurs in this Alphabet; false otherwise.

clone

public Object clone()

Creates a clone of this Alphabet, and replicates the NFA constructed from this Expression.

Specified by:
clone in class Lexicon.Expression
Returns:
a clone of this Alphabet.

 

© 1999-2009 Craig A. Rich <carich@csupomona.edu>