Package org.apache.ctakes.drugner.fsm.output.elements

Examples of org.apache.ctakes.drugner.fsm.output.elements.FrequencyUnitToken


      Iterator frequencyUnitTokenItr = frequencyUnitTokenSet.iterator();
      int begSegFUT = 0, endSegFUT = 0;
      while (frequencyUnitTokenItr.hasNext())
      {

        FrequencyUnitToken fut = (FrequencyUnitToken) frequencyUnitTokenItr.next();

        begSegFUT = fut.getStartOffset();
        endSegFUT = fut.getEndOffset();
        FrequencyUnitAnnotation ma = new FrequencyUnitAnnotation(jcas,
            begSegFUT, endSegFUT);
        ma.setPeriod(new Float(fut.getFrequencyUnitQuantity()).floatValue());
        ma.addToIndexes();

      }
      // The frequencyFSM can take advantage of the frequencyUnit to
      // establish conditions via the override
View Full Code Here


      Iterator frequencyUnitTokenItr = frequencyUnitTokenSet.iterator();
      int begSegFUT = 0, endSegFUT = 0;
      while (frequencyUnitTokenItr.hasNext())
      {

        FrequencyUnitToken fut = (FrequencyUnitToken) frequencyUnitTokenItr.next();

        begSegFUT = fut.getStartOffset();
        endSegFUT = fut.getEndOffset();
        FrequencyUnitAnnotation ma = new FrequencyUnitAnnotation(jcas,
            begSegFUT, endSegFUT);
        ma.setPeriod(new Float(fut.getFrequencyUnitQuantity()).floatValue());
        ma.addToIndexes();

      }
      // The frequencyFSM can take advantage of the frequencyUnit to
      // establish conditions via the override
View Full Code Here

      Iterator frequencyUnitTokenItr = frequencyUnitTokenSet.iterator();
      int begSegFUT = 0, endSegFUT = 0;
      while (frequencyUnitTokenItr.hasNext())
      {

        FrequencyUnitToken fut = (FrequencyUnitToken) frequencyUnitTokenItr.next();

        begSegFUT = fut.getStartOffset();
        endSegFUT = fut.getEndOffset();
        FrequencyUnitAnnotation ma = new FrequencyUnitAnnotation(jcas,
            begSegFUT, endSegFUT);
        ma.setPeriod(new Float(fut.getFrequencyUnitQuantity()).floatValue());
        ma.addToIndexes();

      }
      // The frequencyFSM can take advantage of the frequencyUnit to
      // establish conditions via the override
View Full Code Here

                    else
                    {
                        endToken = token;
                    }
                   
          FrequencyUnitToken fractionToken = null;
           if (fsm.equals(iv_EveryOtherHourMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_24/2);
           else if (fsm.equals(iv_SixTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_SIX);
           else if (fsm.equals(iv_FiveTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_FIVE);
           else if (fsm.equals(iv_FourTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_FOUR);
           else if (fsm.equals(iv_ThreeTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_THREE);
          else if (fsm.equals(iv_HourlyMachine) || fsm.equals(iv_HourlySuffixMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_24);
          else if (fsm.equals(iv_TwiceADayMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_TWO);
          else if (fsm.equals(iv_DailyMachine) || fsm.equals(iv_DailySuffixMachine))
            fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_ONE);
          else if (fsm.equals(iv_EveryOtherDayMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_EVERY_OTHER_DAY);
          else if (fsm.equals(iv_WeeklyMachine)|| fsm.equals(iv_WeeklySuffixMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_WEEKLY);
          else if (fsm.equals(iv_MonthlySuffixMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_MONTHLY);
          else if (fsm.equals(iv_YearlySuffixMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_YEARLY);
          else
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_PRN);
         
          rangeSet.add(fractionToken);
          fsm.reset();
View Full Code Here

                    }
                    else
                    {
                        endToken = token;
                    }
          FrequencyUnitToken fractionToken = null;
           if (fsm.equals(iv_EveryOtherHourMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_24/2);
           else if (fsm.equals(iv_SixTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_SIX);
           else if (fsm.equals(iv_FiveTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_FIVE);
           else if (fsm.equals(iv_FourTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_FOUR);
           else if (fsm.equals(iv_ThreeTimesADayMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_THREE);
          else if (fsm.equals(iv_HourlyMachine) || fsm.equals(iv_HourlySuffixMachine))
              fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_24);
          else if (fsm.equals(iv_TwiceADayMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_TWO);
          else if (fsm.equals(iv_DailyMachine) || fsm.equals(iv_DailySuffixMachine))
            fractionToken = new FrequencyUnitToken(
                startToken.getStartOffset(), endToken
                    .getEndOffset(), FrequencyUnitToken.QUANTITY_ONE);
          else if (fsm.equals(iv_EveryOtherDayMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_EVERY_OTHER_DAY);
          else if (fsm.equals(iv_WeeklyMachine)|| fsm.equals(iv_WeeklySuffixMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_WEEKLY);
          else if (fsm.equals(iv_MonthlySuffixMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_MONTHLY);
          else if (fsm.equals(iv_YearlySuffixMachine))
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_YEARLY);
          else
            fractionToken = new FrequencyUnitToken(
              startToken.getStartOffset(), endToken
                  .getEndOffset(), FrequencyUnitToken.QUANTITY_PRN);
       
          fractionSet.add(fractionToken);
          fsm.reset();
View Full Code Here

      Iterator frequencyUnitTokenItr = frequencyUnitTokenSet.iterator();
      int begSegFUT = 0, endSegFUT = 0;
      while (frequencyUnitTokenItr.hasNext())
      {

        FrequencyUnitToken fut = (FrequencyUnitToken) frequencyUnitTokenItr.next();

        begSegFUT = fut.getStartOffset();
        endSegFUT = fut.getEndOffset();
        FrequencyUnitAnnotation ma = new FrequencyUnitAnnotation(jcas,
            begSegFUT, endSegFUT);
        ma.setPeriod(new Float(fut.getFrequencyUnitQuantity()).floatValue());
        ma.addToIndexes();

      }
      // The frequencyFSM can take advantage of the frequencyUnit to
      // establish conditions via the override
View Full Code Here

TOP

Related Classes of org.apache.ctakes.drugner.fsm.output.elements.FrequencyUnitToken

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.