Example usage for com.fasterxml.jackson.module.jsonSchema.types NumberSchema NumberSchema

List of usage examples for com.fasterxml.jackson.module.jsonSchema.types NumberSchema NumberSchema

Introduction

In this page you can find the example usage for com.fasterxml.jackson.module.jsonSchema.types NumberSchema NumberSchema.

Prototype

NumberSchema

Source Link

Usage

From source file:org.brutusin.json.impl.JacksonSchemaFactory.java

@Override
public NumberSchema numberSchema() {
    return new NumberSchema() {
        @com.fasterxml.jackson.annotation.JsonProperty("default")
        private Object def;
        @com.fasterxml.jackson.annotation.JsonProperty("enum")
        private List values;
        @com.fasterxml.jackson.annotation.JsonProperty
        private IndexableProperty.IndexMode index;
        @com.fasterxml.jackson.annotation.JsonProperty
        private String[] dependsOn;

        @JsonIgnore//  w  w  w  .ja  va2s  . co m
        public String id;

        @JsonIgnore
        @Override
        public String getId() {
            return super.getId();
        }

        public String[] getDependsOn() {
            return dependsOn;
        }

        public void setDependsOn(String[] dependsOn) {
            this.dependsOn = dependsOn;
        }

        public Object getDef() {
            return def;
        }

        public void setDef(Object def) {
            this.def = def;
        }

        public List getValues() {
            return values;
        }

        public void setValues(List values) {
            this.values = values;
        }

        public IndexableProperty.IndexMode getIndex() {
            return index;
        }

        public void setIndex(IndexableProperty.IndexMode index) {
            this.index = index;
        }

        @Override
        public void enrichWithBeanProperty(BeanProperty beanProperty) {
            enrich(this, beanProperty);
        }
    };
}