@@ -0,0 +1,1048 @@
+package Project;%0A%0A/**%0A * File: State.java%0A * %0A * Name: Chris Mahlke%0A * %0A * Description: If the character is at the head of the input string,%0A * character_transition is taken. If character is '?', any character at the head%0A * of the input string is matched. But if character is '#', then%0A * character_transition is a (second) empty string transition. If the%0A * character_transition is null, it is unused.%0A */%0Apublic class State %7B%0A%09public char character;%0A%09public State character_transition;%0A%0A%09// The empty_transition is taken on the empty string. If the%0A%09// empty_transition is null, it is unused.%0A%09public State empty_transition;%0A%0A%09// Set the empty_transition to State s.%0A%09public void on_empty_goto(State s) %7B%0A%09%09empty_transition = s;%0A%09%7D%0A%0A%09// Set the character to c and the character_transition to State s.%0A%09public void on_character_goto(char c, State s) %7B%0A%09%09character = c;%0A%09%09character_transition = s;%0A%09%7D%0A%0A%09// Reinitializes State. Sets transitions to null.%0A%09public void init() %7B%0A%09%09character = 0;%0A%09%09character_transition = empty_transition = null;%0A%09%7D%0A%7D%0A

Create State.java