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

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


    Condition leftIntCondition = new NumberCondition();
    Condition decIntCondition = new NumberCondition();
    Condition rightIntCondition = new NumberCondition();

    Condition rightDecimalCondition = new DecimalCondition();
    Condition dashCondition = new PunctuationValueCondition('-');
   
    Condition dotCondition = new PunctuationValueCondition('.');

    Condition rightDoseagesCondition = new FractionStrengthCondition();
 
    startState.addTransition(leftIntCondition, leftNumIntegerState);
    startState.addTransition(rangeCondition, leftNumIntegerState);
View Full Code Here


        ntFalseTermState);
    formState.addTransition(new AnyCondition(), startState);

    dosageState.addTransition(strengthFormCondition, ntEndState);
    dosageState
        .addTransition(new PunctuationValueCondition('-'), hyphState);

    dosageState.addTransition(new PunctuationValueCondition('('),
        leftParenState);
    dosageState.addTransition(new TextValueCondition("of", false), ofState);
    dosageState.addTransition(new AnyCondition(), startState);

    ofState.addTransition(new TextValueCondition("a", false), aState);
View Full Code Here

    //Mayo SPM 2/20/2012 Changed due to separation of strength tokens
//    startState.addTransition(new StrengthUnitCondition(), ntEndState);
    startState.addTransition(new StrengthUnitCombinedCondition(), endState);
    startState.addTransition(new AnyCondition(), startState);
   
    dateState.addTransition(new NegateCondition( new PunctuationValueCondition('/')), connectState);
    dateState.addTransition(new AnyCondition(), startState);
   
    //Mayo SPM 2/20/2012 Changed due to separation of strength tokens
    connectState.addTransition(new StrengthUnitCondition(), ntEndState);
    connectState.addTransition(new StrengthUnitCombinedCondition(), endState);
    connectState.addTransition(new PunctuationValueCondition('-'), unitState);
    connectState.addTransition(new PunctuationValueCondition('.'), decimalState);
    connectState.addTransition(new AnyCondition(), startState);
   
    //Mayo SPM 2/20/2012 Changed due to separation of strength tokens
    decimalState.addTransition(new StrengthUnitCondition(), ntEndState);
    decimalState.addTransition(new StrengthUnitCombinedCondition(), endState);
    decimalState.addTransition(new PunctuationValueCondition('-'), unitState);
    decimalState.addTransition(new NumberCondition(), complexState);
    decimalState.addTransition(new AnyCondition(), startState);
   
    //Mayo SPM 2/20/2012 Changed due to separation of strength tokens
    unitState.addTransition(new StrengthUnitCondition(), ntEndHyphState);
    unitState.addTransition(new StrengthUnitCombinedCondition(), endState);
    unitState.addTransition(new AnyCondition(), startState);
   
    complexState.addTransition(new PunctuationValueCondition('-'), hyphenState);
    complexState.addTransition(new AnyCondition(), startState);
   
    //Mayo SPM 2/20/2012 Changed due to separation of strength tokens
    hyphenState.addTransition(new StrengthUnitCondition(), ntEndHyphState);
    hyphenState.addTransition(new AnyCondition() , startState);
View Full Code Here

    State lastTextState = new NamedState("LAST_TEXT");
    State middleTextState = new NamedState("MID_TEXT");
    State firstDashState = new NamedState("FIRSTDASH");
    State secondDashState = new NamedState("SECONDDASH");

    Condition firstDashCondition = new PunctuationValueCondition('-');
    Condition secondDashCondition = new PunctuationValueCondition('-');

    Condition firstMiddleTextCondition = new WordSetCondition(
        iv_middleNumericTermSet, true);
    Condition secondMiddleTextCondition = new WordSetCondition(
        iv_middleNumericTermSet, true);
View Full Code Here

    State systolicState = new NamedState("SYSTOLIC");
    State fslashState = new NamedState("FSLASH");

    Condition systolicCondition = new IntegerRangeCondition(80, 200);
    Condition diastolicCondition = new IntegerRangeCondition(60, 160);
    Condition fslashCondition = new PunctuationValueCondition('/');

    startState.addTransition(systolicCondition, systolicState);
    startState.addTransition(new AnyCondition(), startState);

    systolicState.addTransition(fslashCondition, fslashState);
View Full Code Here

    State dayNumState = new NamedState("DAY_NUM");
    State dayYearSeparatorState = new NamedState("DAY_YEAR_SEP");

    Condition monthNumCondition = new IntegerRangeCondition(MIN_MONTH,
        MAX_MONTH);
    Condition mdFslashCondition = new PunctuationValueCondition('/');
    Condition mdDashCondition = new PunctuationValueCondition('-');
    Condition dyFslashCondition = new PunctuationValueCondition('/');
    Condition dyDashCondition = new PunctuationValueCondition('-');
    Condition dayNumCondition = new IntegerRangeCondition(MIN_DAY, MAX_DAY);
    Condition yearNumCondition = new IntegerRangeCondition(MIN_YEAR,
        MAX_YEAR);

    // condition that is not a fslash or dash
View Full Code Here

    Condition monthFullTextCondition = new WordSetCondition(
        iv_monthFullNameSet, false);
    Condition monthShortTextCondition = new WordSetCondition(
        iv_monthShortNameSet, false);
    Condition dayNumCondition = new IntegerRangeCondition(MIN_DAY, MAX_DAY);
    Condition periodCondition = new PunctuationValueCondition('.');
    Condition yearNumCondition = new IntegerRangeCondition(MIN_YEAR,
        MAX_YEAR);
    Condition commaCondition = new PunctuationValueCondition(',');

    // condition for not being a comma or year number
    Condition notCommaNotYearNumCondition = new CombineCondition(
        new NegateCondition(commaCondition), new NegateCondition(
            yearNumCondition));
View Full Code Here

    State leftNumTextState = new NamedState("LEFT_NUM_TEXT");
    State dashState = new NamedState("DASH");

    Condition leftIntCondition = new IntegerCondition();
    Condition rightIntCondition = new IntegerCondition();
    Condition dashCondition = new PunctuationValueCondition('-');
    Condition leftRomanNumeralCondition = new RomanNumeralCondition();
    Condition rightRomanNumeralCondition = new RomanNumeralCondition();
    Condition leftNumTextCondition = new WordSetCondition(iv_textNumberSet,
        false);
    Condition rightNumTextCondition = new WordSetCondition(
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 IntegerCondition();
    Condition fslashCondition = new PunctuationValueCondition('/');
    Condition intDenominatorCondition = new IntegerCondition();
    Condition decimalCondition = new DecimalCondition();
    Condition textNumeratorCondition = new WordSetCondition(
        iv_textNumeratorSet, false);
    Condition textDenominatorCondition = new WordSetCondition(
View Full Code Here

    Machine m = new Machine(startState);
    State titleNameState = new NamedState("TITLENAME");

    Condition titleNameCondition = new WordSetCondition(iv_fullTextSet,
        false);
    Condition periodCondition = new PunctuationValueCondition('.');

    startState.addTransition(titleNameCondition, titleNameState);
    startState.addTransition(new AnyCondition(), startState);

    titleNameState.addTransition(periodCondition, 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.