Package grammar.model.Form

Examples of grammar.model.Form.FormCategory


        for (FormCategory affectedPronoun : forms) {
          if (formContext || auxiliaryFormContext) {
            if (affectedSegments.size() == 0)
              affectedSegments.addAll(Arrays.asList(Segment.values()));
           
            FormCategory targetPronoun;
            if (inheritForm)
              targetPronoun = null; // no rule; refer to parent
            else if (parsedStringAsConstant.equals(""))
              targetPronoun = affectedPronoun;
            else if (targetTense != null && targetTense.getMood().isPersonal())
View Full Code Here


          auxiliary ? modelVerb.auxiliaryRefTenseMap : modelVerb.refTenseMap;
        Map<Tense, Map<FormCategory, Map<Segment, FormCategory>>> pm =
          auxiliary ? modelVerb.auxiliaryRefPronounMap : modelVerb.refPronounMap;

        Tense targetTense =                  tm.get(tense).get(pronounCategory).get(segment);
        FormCategory targetPronounCategory = pm.get(tense).get(pronounCategory).get(segment);
        if (targetTense == null)
          targetTense = getTargetTense(modelVerb, tense, pronounCategory, segment);
        if (targetPronounCategory == null)
          targetPronounCategory = getTargetPronounCategory(modelVerb, tense, pronounCategory, segment);
View Full Code Here

  private static FormCategory getTargetPronounCategory(
      ModelVerb modelVerb, Tense tense, FormCategory pronounCategory,
      Segment segment) {
    try {
      FormCategory targetPronounCategory = modelVerb.refPronounMap.get(tense).get(pronounCategory).get(segment);
      if (targetPronounCategory != null)
        return targetPronounCategory;
    }
    catch (NullPointerException npe) {
      // Legitimate
    }
    for (ModelVerb parent : modelVerb.parents) {
      FormCategory targetPronounCategory =
        getTargetPronounCategory(parent, tense, pronounCategory, segment);
      if (targetPronounCategory != null)
        return targetPronounCategory;
    }
View Full Code Here

TOP

Related Classes of grammar.model.Form.FormCategory

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.