Package com.fasterxml.jackson.module.jsonSchema.customProperties

Examples of com.fasterxml.jackson.module.jsonSchema.customProperties.TitleSchemaFactoryWrapper


    public Pet pet;
  }
 
  public void testAddingTitle() throws Exception
  {
    TitleSchemaFactoryWrapper visitor = new TitleSchemaFactoryWrapper();
    ObjectMapper mapper = new ObjectMapper();

    mapper.acceptJsonFormatVisitor(Person.class, visitor);
    JsonSchema schema = visitor.finalSchema();

    assertTrue("schema should be an objectSchema.", schema.isObjectSchema());
    String title = schema.asObjectSchema().getTitle();
    assertNotNull(title);
    assertTrue("schema should have a title", title.indexOf("Person") != -1);
View Full Code Here

TOP

Related Classes of com.fasterxml.jackson.module.jsonSchema.customProperties.TitleSchemaFactoryWrapper

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.