Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  /*
   * Copyright (c) 2014, Francis Galiegue (fgaliegue@gmail.com)
   *
   * This software is dual-licensed under:
   *
   * - the Lesser General Public License (LGPL) version 3.0 or, at your option, any
   *   later version;
   * - the Apache Software License (ASL) version 2.0.
   *
  * The text of this file and of both licenses is available at the root of this
  * project or, if you have the jar distribution, in directory META-INF/, under
  * the names LGPL-3.0.txt and ASL-2.0.txt respectively.
  *
  * Direct link to the sources:
  *
  * - LGPL 3.0: https://www.gnu.org/licenses/lgpl-3.0.txt
  * - ASL 2.0: http://www.apache.org/licenses/LICENSE-2.0.txt
  */
 
 package com.github.fge.jsonschema.processors.data;
 
 
 
Validation data for a validation processor

The included data are the schema (in the shape of a com.github.fge.jsonschema.core.tree.SchemaTree, the instance to validate (in the shape of a com.github.fge.jsonschema.core.tree.JsonTree and a boolean indicating whether validation should go as deep as posssible.

If the boolean argument is false, then container children (array elements or object members) will not be validated if the

The com.github.fge.jsonschema.core.report.ProcessingMessage template generated contains information about both the schema and instance.

 
 public final class FullData
     implements MessageProvider
 {
     private final SchemaTree schema;
     private final JsonTree instance;
     private final boolean deepCheck;
 
     public FullData(final SchemaTree schemafinal JsonTree instance,
         final boolean deepCheck)
     {
         this. = schema;
         this. = instance;
         this. = deepCheck;
     }
 
     public FullData(final SchemaTree schemafinal JsonTree instance)
     {
         this(schemainstancefalse);
     }
 
     public FullData(final SchemaTree schema)
     {
         this(schemanull);
     }
 
     public SchemaTree getSchema()
     {
         return ;
     }
 
     public JsonTree getInstance()
     {
         return ;
     }
 
     public boolean isDeepCheck()
     {
         return ;
     }

    
Return a new full data with another schema

Parameters:
schema the schema
Returns:
a new full data instance
 
     public FullData withSchema(final SchemaTree schema)
     {
         return new FullData(schema);
     }

    
Return a new full data with another instance

Parameters:
instance the new instance
Returns:
a new full data instance
    public FullData withInstance(final JsonTree instance)
    {
        return new FullData(instance);
    }
    @Override
    public ProcessingMessage newMessage()
    {
        final ProcessingMessage ret = new ProcessingMessage();
        if ( != null)
            ret.put("schema");
        if ( != null)
            ret.put("instance");
        return ret;
    }
New to GrepCode? Check out our FAQ X