Examples of matchesFull()


Examples of games.stendhal.common.parser.Sentence.matchesFull()

    // TODO: lowercase "and" at the beginning of a sentence is ignored, even in full match mode: "and the other gold"

    final Sentence answer = ConversationParser.parse(sentence.getOriginalText(), CONVERSION_CONTEXT);
    for (Sentence trigger : triggers) {
      if (answer.matchesFull(trigger)) {
        return true;
      }
    }
    return false;
  }
View Full Code Here

Examples of games.stendhal.common.parser.Sentence.matchesFull()

  @Test
  public final void testWithoutParser() {
    final Expression expr = new Expression("hello", "VER");
    final Sentence sentence = new SentenceImplementation(expr);

    assertTrue(sentence.matchesFull(sentence));
  }

  /**
   * Test for the answer "pestle and mortar" in response to
   * "Wonderful! Did you bring anything else with you?" (Ortiv Milquetoast).
View Full Code Here

Examples of games.stendhal.common.parser.SentenceImplementation.matchesFull()

  @Test
  public final void testWithoutParser() {
    final Expression expr = new Expression("hello", "VER");
    final Sentence sentence = new SentenceImplementation(expr);

    assertTrue(sentence.matchesFull(sentence));
  }

  /**
   * Test for the answer "pestle and mortar" in response to
   * "Wonderful! Did you bring anything else with you?" (Ortiv Milquetoast).
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.