Package org.jsonschema2pojo.rules
Class MinLengthMaxLengthRule
java.lang.Object
org.jsonschema2pojo.rules.MinLengthMaxLengthRule
- All Implemented Interfaces:
Rule<com.sun.codemodel.JFieldVar,com.sun.codemodel.JFieldVar>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.sun.codemodel.JFieldVarapply(String nodeName, com.fasterxml.jackson.databind.JsonNode node, com.fasterxml.jackson.databind.JsonNode parent, com.sun.codemodel.JFieldVar field, Schema currentSchema) Add whatever Java source is required to the given generatable to represent this schema rule.
-
Constructor Details
-
MinLengthMaxLengthRule
-
-
Method Details
-
apply
public com.sun.codemodel.JFieldVar apply(String nodeName, com.fasterxml.jackson.databind.JsonNode node, com.fasterxml.jackson.databind.JsonNode parent, com.sun.codemodel.JFieldVar field, Schema currentSchema) Description copied from interface:RuleAdd whatever Java source is required to the given generatable to represent this schema rule.- Specified by:
applyin interfaceRule<com.sun.codemodel.JFieldVar,com.sun.codemodel.JFieldVar> - Parameters:
nodeName- the name of the JSON schema nodenode- the JSON schema node that has caused this rule to be appliedparent- the JSON parent ofnodefield- A code generation construct to which this rule should be appliedcurrentSchema- the schema to which this schema rule (and the given node) belongs.- Returns:
- the newly generated source code item that was added/created as a result of executing this rule
-