Package org.apache.ctakes.core.fsm.condition

Examples of org.apache.ctakes.core.fsm.condition.PunctuationValueCondition


//        iv_fullTextSet, false), endState);
//    startState.addTransition(new WordSetCondition(
//        iv_fullTextSet, false), endState);
   
    startState.addTransition(new WordSetCondition(iv_fullTextSet, false), endState);
    startState.addTransition(new PunctuationValueCondition('-'), unitState);
    startState.addTransition(new SymbolValueCondition('%'), endState);
    startState.addTransition(new AnyCondition(), startState);
   
    unitState.addTransition(new WordSetCondition(iv_fullTextSet, false), ntFalseTermState);
    unitState.addTransition(new SymbolValueCondition('%'), endState);
View Full Code Here


        iv_fullTextSet, false), endState);
//    startState.addTransition(new WordSetCondition(
//        iv_fullTextSet, false), endState);
//   
//    startState.addTransition(new WordSetCondition(iv_fullTextSet, false), endState);
    startState.addTransition(new PunctuationValueCondition('-'), unitState);
    startState.addTransition(new SymbolValueCondition('%'), endState);
    startState.addTransition(new AnyCondition(), startState);
   
    unitState.addTransition(new ContainsSetTextValueCondition(iv_fullTextSet, false), ntFalseTermState);
    unitState.addTransition(new SymbolValueCondition('%'), endState);
View Full Code Here

    State middleATextState = new NamedState("MID_TEXT");
    State firstDashState = new NamedState("FIRSTDASH");
    State secondDashState = new NamedState("SECONDDASH");
 

    Condition firstDashCondition = new PunctuationValueCondition('-');
    Condition secondDashCondition = new PunctuationValueCondition('-');
    Condition rangeCombineCondition = new DisjoinCondition(
    new RangeCondition(),
    new RangeStrengthCondition()
    );
 
View Full Code Here

    State middleATextState = new NamedState("MID_TEXT");
    State firstDashState = new NamedState("FIRSTDASH");
    State secondDashState = new NamedState("SECONDDASH");
 
 
    Condition firstDashCondition = new PunctuationValueCondition('-');
    Condition secondDashCondition = new PunctuationValueCondition('-');
    Condition rangeCombineCondition = new DisjoinCondition(
    new RangeCondition(),
    new RangeStrengthCondition()
    );
 
View Full Code Here

    State leftAbbreviatePState = new NamedState("LEFT_P");
      State rightAbbreviatePVState = new NamedState("RIGHT_PV");
      State firstDotPState = new NamedState("FIRSTDOTP");

      //Condition secondPVDotCondition = 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_singleTopicalWordSet, true);
 
   
 
    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(new AnyCondition(), startState);
 
    leftAbbreviatePState.addTransition(new PunctuationValueCondition('.'), firstDotPState);
    leftAbbreviatePState.addTransition(new AnyCondition(), startState);

    firstDotPState.addTransition(soloCondition, endState);
    firstDotPState.addTransition(new TextValueCondition("v", true),
        rightAbbreviatePVState);
    firstDotPState.addTransition(new AnyCondition(), startState);
    leftAbbreviateState.addTransition(firstMiddleTextCondition,
        middleATextState);
    leftAbbreviateState.addTransition(firstDashCondition, firstDashState);
    leftAbbreviateState.addTransition(soloCondition, endState);
    leftAbbreviateState.addTransition(new AnyCondition(), startState);
 
    firstDashState
        .addTransition(thirdMiddleTextCondition, middleATextState);
    firstDashState.addTransition(new AnyCondition(), startState);
 
    middleATextState
        .addTransition(secondMiddleTextCondition, lastTextState);
    middleATextState.addTransition(secondDashCondition, secondDashState);
    middleATextState.addTransition(new AnyCondition(), startState);
 
    secondDashState.addTransition(fourthMiddleTextCondition, lastTextState);
    secondDashState.addTransition(new AnyCondition(), startState);
 
    lastTextState.addTransition(new AnyCondition(), startState);
 
    rightAbbreviatePVState.addTransition(new PunctuationValueCondition('.'), endState);
    rightAbbreviatePVState.addTransition(new AnyCondition(), startState);

    endState.addTransition(new AnyCondition(), startState);
 
    return m;
View Full Code Here

    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()
    );
 
View Full Code Here

      State hypenState = new NamedState("HYPHEN");
      State dotLeftState = new NamedState("DOT_LEFT");
      State dotRightState = new NamedState("DOT_RIGHT");
      Condition intNumeratorCondition = new NumberCondition();
      Condition decPartInt = new NumberCondition();
      Condition fslashCondition = new PunctuationValueCondition('/');
      Condition intDenominatorCondition = new NumberCondition();
      Condition decDenominatorCondition = new DecimalCondition();
      Condition decimalCondition = new DecimalCondition();
      Condition containsdotCondition = new PunctuationValueCondition('.');
      Condition leftContainsShortDose = new ContainsSetTextValueCondition(
        iv_textNumeratorSet, false);
   
      startState.addTransition(intNumeratorCondition, numeratorLeftState);
      startState.addTransition(leftContainsShortDose, numeratorLeftState);
      startState.addTransition(new DecimalCondition(), numeratorLeftState);
      startState.addTransition(new AnyCondition(), startState);
     
      numeratorLeftState.addTransition(containsdotCondition, dotLeftState);
      numeratorLeftState.addTransition(fslashCondition, fslashState);
      numeratorLeftState.addTransition(new PunctuationValueCondition('-'), numeratorRightState);
      numeratorLeftState.addTransition(new AnyCondition(), startState);
     
      dotLeftState.addTransition(decPartInt, hypenState);
      dotLeftState.addTransition(decDenominatorCondition, hypenState);
      dotLeftState.addTransition(new AnyCondition(), startState);
   
      hypenState.addTransition(new PunctuationValueCondition('-'), numeratorRightState);
      hypenState.addTransition(new AnyCondition(), startState);
     
      numeratorRightState.addTransition(new NumberCondition(), endState);
      numeratorRightState.addTransition(new DecimalCondition(), endState);
      numeratorRightState.addTransition(new AnyCondition(), startState);
     
      dotRightState.addTransition(new PunctuationValueCondition('.'), fslashState);
      dotRightState.addTransition(new AnyCondition(), startState);
     
      decPartNumState.addTransition(fslashCondition, fslashState);
      decPartNumState.addTransition(new AnyCondition(), startState);
     
View Full Code Here

        State numeratorNumState = new NamedState("NUMERATOR_NUM");
        State fslashState = new NamedState("FORWARD_SLASH");
        State numeratorTextState = new NamedState("NUMERATOR_TEXT");

        Condition intNumeratorCondition = new NumberCondition();
        Condition fslashCondition = new PunctuationValueCondition('/');
        Condition intDenominatorCondition = new NumberCondition();
        Condition decimalCondition = new DecimalCondition();
        Condition textNumeratorCondition =
            new WordSetCondition(iv_textNumeratorSet, false);
        Condition textDenominatorCondition =
View Full Code Here

 
   
    startState.addTransition(new WordSetCondition(iv_textNumberSet, false), leftNumTextState);
    startState.addTransition(new AnyCondition(), startState);
 
    leftNumTextState.addTransition(new PunctuationValueCondition('-'), dash2State);
    leftNumTextState.addTransition(new WordSetCondition(iv_rangeSet, false), rightNumTextState);
    leftNumTextState.addTransition(new AnyCondition(), startState);
 
     
      dash2State.addTransition(rightIntCondition, endState);
    dash2State.addTransition(rightNumTextCondition, endState);
    dash2State.addTransition(new WordSetCondition(iv_rangeSet, false), middleDash);
    dash2State.addTransition(new AnyCondition(), startState);
   
    middleDash.addTransition(new PunctuationValueCondition('-'), dashAnotherState);
    middleDash.addTransition(new AnyCondition(), startState);
   
    rightNumTextState.addTransition(new NumberCondition(), endState);
    rightNumTextState.addTransition(new WordSetCondition(iv_textNumberSet, false), endState);
    rightNumTextState.addTransition(new AnyCondition(), startState);
View Full Code Here

      startState.addTransition(leftIntCondition, leftNumIntegerState);
      startState.addTransition(new WordSetCondition(iv_hyphenatedSet, false), endState);
      startState.addTransition(new WordSetCondition(iv_textNumberSet, false), leftNumTextState);
      startState.addTransition(new AnyCondition(), startState);
 
      leftNumIntegerState.addTransition(new PunctuationValueCondition('-'), dashState);
      leftNumIntegerState.addTransition(new AnyCondition(), startState);
 
      leftNumTextState.addTransition(new PunctuationValueCondition('-'), dash1State);
      leftNumTextState.addTransition(new AnyCondition(), startState);
 
      dashState.addTransition(rightIntCondition, endState);
      dashState.addTransition(new WordSetCondition(iv_textNumberSet, false), endState);
 
View Full Code Here

TOP

Related Classes of org.apache.ctakes.core.fsm.condition.PunctuationValueCondition

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.