Exemplo n.º 1
0
 public void validateResult(Losr losr) {
   aboveOrWithinRule.validate(losr);
   Instruction instruction = planner.instruction(losr);
   if (matchExpectedInstruction) {
     if (!instruction.equals(command.scene().instruction())) {
       throw new RoboticException("Failed to match expected instruction.");
     }
   }
 }
Exemplo n.º 2
0
 public void validatePartial(Losr losr) {
   if (losr instanceof Entity) {
     Entity e = (Entity) losr;
     if (e.spatialRelation() != null) {
       aboveOrWithinRule.validate(e, e.spatialRelation());
     }
   }
   if (losr instanceof Location) {
     markerRule.validate(losr, tokens);
   }
 }