test_class.declarator: DICTIONARY_PATH = "src" + File.separator + "test" + File.separator + "resources" + File.separator + "enums.xml"
test_class.modifier: private static final
test_class.original_string: private static final String DICTIONARY_PATH = "src" + File.separator + "test" + File.separator + "resources" + File.separator + "enums.xml";
test_class.type: String
test_class.var_name: DICTIONARY_PATH
test_class.file: BackEnd/Core/sailfish-core/src/test/java/com/exactpro/sf/common/messages/TestEnumValidatorVisitor.java
test_class.identifier: TestEnumValidatorVisitor
test_class.superclass: extends EPSTestCase
test_case.body: @Test
      public void testValidation() throws EPSCommonException, FileNotFoundException {
          IDictionaryStructureLoader loader = new XmlDictionaryStructureLoader();
          IDictionaryStructure dictionary = loader.load(new FileInputStream(new File(getBaseDir(), DICTIONARY_PATH)));
          IMessageStructure structure = dictionary.getMessages().get("Message");
  
          IMessage nested1 = new MapMessage(dictionary.getNamespace(), "NestedMessage");
  
          nested1.addField("NestedSimple", 3);
          nested1.addField("NestedCollection", Arrays.asList(4, 5));
  
          IMessage nested2 = new MapMessage(dictionary.getNamespace(), "NestedMessage");
  
          nested2.addField("NestedSimple", 6);
          nested2.addField("NestedCollection", Arrays.asList(7, 8));
  
          IMessage nested3 = new MapMessage(dictionary.getNamespace(), "NestedMessage");
  
          nested3.addField("NestedSimple", 9);
          nested3.addField("NestedCollection", Arrays.asList(10, 11));
  
          IMessage message = new MapMessage(dictionary.getNamespace(), structure.getName());
  
          message.addField("Simple", 3);
          message.addField("Collection", Arrays.asList(4, 5));
          message.addField("NestedMessage", nested1);
          message.addField("NestedMessageCollection", Arrays.asList(nested2, nested3));
  
          EnumValidatorVisitor visitor = new EnumValidatorVisitor();
          List<String> errors = visitor.getErrors();
  
          MessageStructureReader.READER.traverse(visitor, structure, message, MessageStructureReaderHandlerImpl.instance());
  
          int i = 0;
  
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'Simple': 3 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'Collection[0]': 4 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'Collection[1]': 5 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessage.NestedSimple': 3 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessage.NestedCollection[0]': 4 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessage.NestedCollection[1]': 5 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessageCollection[0].NestedSimple': 6 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessageCollection[0].NestedCollection[0]': 7 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessageCollection[0].NestedCollection[1]': 8 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessageCollection[1].NestedSimple': 9 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessageCollection[1].NestedCollection[0]': 10 (expected values: [1, 2])");
          Assert.assertEquals(errors.get(i++), "Unknown value in field 'NestedMessageCollection[1].NestedCollection[1]': 11 (expected values: [1, 2])");
      }
test_case.class_method_signature: TestEnumValidatorVisitor.testValidation()
test_case.full_signature: @Test public void testValidation()
test_case.identifier: testValidation
test_case.invocations: load getBaseDir get getMessages getNamespace addField addField asList getNamespace addField addField asList getNamespace addField addField asList getNamespace getName addField addField asList addField addField asList getErrors traverse instance assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get assertEquals get
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testValidation()
focal_class.declarator: errors
focal_class.modifier: private final
focal_class.original_string: private final List<String> errors;
focal_class.type: List<String>
focal_class.var_name: errors
focal_class.declarator: path
focal_class.modifier: private final
focal_class.original_string: private final Deque<String> path;
focal_class.type: Deque<String>
focal_class.var_name: path
focal_class.file: BackEnd/Core/sailfish-core/src/main/java/com/exactpro/sf/common/messages/EnumValidatorVisitor.java
focal_class.identifier: EnumValidatorVisitor
focal_class.interfaces: implements IMessageStructureVisitor
focal_class.class_method_signature: EnumValidatorVisitor.EnumValidatorVisitor()
focal_class.full_signature: public  EnumValidatorVisitor()
focal_class.identifier: EnumValidatorVisitor
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  EnumValidatorVisitor()
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Boolean value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Boolean value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Boolean value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Boolean value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitBooleanCollection(String fieldName, List<Boolean> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitBooleanCollection(String fieldName, List<Boolean> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitBooleanCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Boolean> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitBooleanCollection(String fieldName, List<Boolean> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Byte value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Byte value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Byte value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Byte value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitByteCollection(String fieldName, List<Byte> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitByteCollection(String fieldName, List<Byte> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitByteCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Byte> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitByteCollection(String fieldName, List<Byte> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Character value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Character value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Character value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Character value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitCharCollection(String fieldName, List<Character> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitCharCollection(String fieldName, List<Character> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitCharCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Character> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitCharCollection(String fieldName, List<Character> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, LocalDate value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, LocalDate value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, LocalDate value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, LocalDate value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitDateCollection(String fieldName, List<LocalDate> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitDateCollection(String fieldName, List<LocalDate> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitDateCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<LocalDate> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitDateCollection(String fieldName, List<LocalDate> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, LocalTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, LocalTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, LocalTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, LocalTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitTimeCollection(String fieldName, List<LocalTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitTimeCollection(String fieldName, List<LocalTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitTimeCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<LocalTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitTimeCollection(String fieldName, List<LocalTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, LocalDateTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, LocalDateTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, LocalDateTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, LocalDateTime value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitDateTimeCollection(String fieldName, List<LocalDateTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitDateTimeCollection(String fieldName, List<LocalDateTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitDateTimeCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<LocalDateTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitDateTimeCollection(String fieldName, List<LocalDateTime> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Double value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Double value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Double value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Double value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitDoubleCollection(String fieldName, List<Double> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitDoubleCollection(String fieldName, List<Double> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitDoubleCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Double> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitDoubleCollection(String fieldName, List<Double> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Float value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Float value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Float value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Float value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitFloatCollection(String fieldName, List<Float> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitFloatCollection(String fieldName, List<Float> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitFloatCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Float> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitFloatCollection(String fieldName, List<Float> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Integer value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Integer value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Integer value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Integer value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitIntCollection(String fieldName, List<Integer> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitIntCollection(String fieldName, List<Integer> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitIntCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Integer> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitIntCollection(String fieldName, List<Integer> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Long value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Long value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Long value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Long value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitLongCollection(String fieldName, List<Long> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitLongCollection(String fieldName, List<Long> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitLongCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Long> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitLongCollection(String fieldName, List<Long> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, BigDecimal value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, BigDecimal value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, BigDecimal value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, BigDecimal value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitBigDecimalCollection(String fieldName, List<BigDecimal> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitBigDecimalCollection(String fieldName, List<BigDecimal> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitBigDecimalCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<BigDecimal> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitBigDecimalCollection(String fieldName, List<BigDecimal> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, Short value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, Short value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, Short value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, Short value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitShortCollection(String fieldName, List<Short> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitShortCollection(String fieldName, List<Short> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitShortCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<Short> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitShortCollection(String fieldName, List<Short> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, String value, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, String value, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, String value, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, String value, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitStringCollection(String fieldName, List<String> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.full_signature: @Override public void visitStringCollection(String fieldName, List<String> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.identifier: visitStringCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<String> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitStringCollection(String fieldName, List<String> values, IFieldStructure fldStruct, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visit(String fieldName, IMessage message, IFieldStructure complexField, boolean isDefault)
focal_class.full_signature: @Override public void visit(String fieldName, IMessage message, IFieldStructure complexField, boolean isDefault)
focal_class.identifier: visit
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, IMessage message, IFieldStructure complexField, boolean isDefault)
focal_class.return: void
focal_class.signature: void visit(String fieldName, IMessage message, IFieldStructure complexField, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.visitMessageCollection(String fieldName, List<IMessage> messages, IFieldStructure complexField, boolean isDefault)
focal_class.full_signature: @Override public void visitMessageCollection(String fieldName, List<IMessage> messages, IFieldStructure complexField, boolean isDefault)
focal_class.identifier: visitMessageCollection
focal_class.modifiers: @Override public
focal_class.parameters: (String fieldName, List<IMessage> messages, IFieldStructure complexField, boolean isDefault)
focal_class.return: void
focal_class.signature: void visitMessageCollection(String fieldName, List<IMessage> messages, IFieldStructure complexField, boolean isDefault)
focal_class.class_method_signature: EnumValidatorVisitor.checkValues(IFieldStructure field, List<?> values)
focal_class.full_signature: private void checkValues(IFieldStructure field, List<?> values)
focal_class.identifier: checkValues
focal_class.modifiers: private
focal_class.parameters: (IFieldStructure field, List<?> values)
focal_class.return: void
focal_class.signature: void checkValues(IFieldStructure field, List<?> values)
focal_class.class_method_signature: EnumValidatorVisitor.checkValue(IFieldStructure field, Object value, boolean updatePath)
focal_class.full_signature: private void checkValue(IFieldStructure field, Object value, boolean updatePath)
focal_class.identifier: checkValue
focal_class.modifiers: private
focal_class.parameters: (IFieldStructure field, Object value, boolean updatePath)
focal_class.return: void
focal_class.signature: void checkValue(IFieldStructure field, Object value, boolean updatePath)
focal_class.class_method_signature: EnumValidatorVisitor.getErrors()
focal_class.full_signature: public List<String> getErrors()
focal_class.identifier: getErrors
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: List<String>
focal_class.signature: List<String> getErrors()
focal_method.body: public List<String> getErrors() {
          return errors;
      }
focal_method.class_method_signature: EnumValidatorVisitor.getErrors()
focal_method.full_signature: public List<String> getErrors()
focal_method.identifier: getErrors
focal_method.modifiers: public
focal_method.parameters: ()
focal_method.return: List<String>
focal_method.signature: List<String> getErrors()