* <li>tabs</li>
* </ol>
* @return
*/
private Machine getOralMachine() {
State startState = new NamedState("START");
State endState = new NamedState("END");
endState.setEndStateFlag(true);
Machine m = new Machine(startState);
State leftAbbreviateState = new NamedState("LEFT_FREQ");
State leftDosagesState = new NamedState("LEFT_DOSE");
State lastTextState = new NamedState("RIGHT_FREQ");
State middleATextState = new NamedState("MID_TEXT");
State firstDashState = new NamedState("FIRSTDASH");
State secondDashState = new NamedState("SECONDDASH");
State leftAbbreviatePState = new NamedState("LEFT_P");
State rightAbbreviatePOState = new NamedState("RIGHT_PO");
State firstDotPState = new NamedState("FIRSTDOTP");
Condition firstPODotCondition = new PunctuationValueCondition('.');
Condition secondPODotCondition = new PunctuationValueCondition('.');
Condition firstDashCondition = new PunctuationValueCondition('-');
Condition secondDashCondition = new PunctuationValueCondition('-');
Condition rangeCombineCondition = new DisjoinCondition(
new RangeCondition(),
new RangeStrengthCondition()
);
Condition initialMiddleTextCondition = new WordSetCondition(
iv_middleTermSet, true);
Condition firstMiddleTextCondition = new WordSetCondition(
iv_middleTermSet, true);
Condition secondMiddleTextCondition = new WordSetCondition(
iv_middleTermSet, true);
Condition thirdMiddleTextCondition = new WordSetCondition(
iv_middleTermSet, true);
Condition fourthMiddleTextCondition = new WordSetCondition(
iv_middleTermSet, true);
Condition soloCondition = new WordSetCondition(iv_singleOralWordSet, true);
Condition specificWordCondition = new WordSetCondition(
iv_specifiedOralWordSet, false);
startState.addTransition(new TextValueCondition("a", true),
leftAbbreviateState);
startState.addTransition(new TextValueCondition("p", true),
leftAbbreviatePState);
startState.addTransition(initialMiddleTextCondition, leftAbbreviateState);
startState.addTransition(rangeCombineCondition, leftDosagesState);
startState.addTransition(soloCondition, endState);
startState.addTransition(specificWordCondition, endState);
startState.addTransition(new AnyCondition(), startState);
leftAbbreviatePState.addTransition(firstPODotCondition, firstDotPState);
leftAbbreviatePState.addTransition(new AnyCondition(), startState);
firstDotPState.addTransition(soloCondition, endState);
firstDotPState.addTransition(new TextValueCondition("o", true),
rightAbbreviatePOState);
firstDotPState.addTransition(new AnyCondition(), startState);
leftAbbreviateState.addTransition(firstMiddleTextCondition,
middleATextState);
leftAbbreviateState.addTransition(firstDashCondition, firstDashState);
leftAbbreviateState.addTransition(soloCondition, endState);