All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.anwiba.spatial.osm.nominatim.schema.v01_0.Place Maven / Gradle / Ivy

There is a newer version: 1.2.50
Show newest version
//Copyright (c) 2017 by Andreas W. Bartels ([email protected])
package net.anwiba.spatial.osm.nominatim.schema.v01_0;

import java.lang.reflect.InvocationTargetException;
import java.util.LinkedHashMap;
import java.util.Map;
import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonProperty;
import net.anwiba.commons.ensure.Conditions;
import net.anwiba.commons.ensure.Ensure;
import net.anwiba.commons.reflection.OptionalReflectionMethodInvoker;
import net.anwiba.spatial.geo.json.v01_0.Geometry;

public class Place {

    private String place_id = null;
    private String licence = null;
    private String osm_type = null;
    private String osm_id = null;
    private String[] boundingbox = null;
    private String lat = null;
    private String lon = null;
    private String display_name = null;
    private String place_rank = null;
    private String category = null;
    private String type = null;
    private Double importance = Double.valueOf(0.0D);
    private Address address = null;
    private Geometry geojson = null;
    private final Map _unknownMembers = new LinkedHashMap();

    @JsonProperty("place_id")
    public void setPlace_id(final String place_id) {
        this.place_id = place_id;
    }

    @JsonProperty("place_id")
    public String getPlace_id() {
        return this.place_id;
    }

    @JsonProperty("licence")
    public void setLicence(final String licence) {
        this.licence = licence;
    }

    @JsonProperty("licence")
    public String getLicence() {
        return this.licence;
    }

    @JsonProperty("osm_type")
    public void setOsm_type(final String osm_type) {
        this.osm_type = osm_type;
    }

    @JsonProperty("osm_type")
    public String getOsm_type() {
        return this.osm_type;
    }

    @JsonProperty("osm_id")
    public void setOsm_id(final String osm_id) {
        this.osm_id = osm_id;
    }

    @JsonProperty("osm_id")
    public String getOsm_id() {
        return this.osm_id;
    }

    @JsonProperty("boundingbox")
    public void setBoundingbox(final String[] boundingbox) {
        this.boundingbox = boundingbox;
    }

    @JsonProperty("boundingbox")
    public String[] getBoundingbox() {
        return this.boundingbox;
    }

    @JsonProperty("lat")
    public void setLat(final String lat) {
        this.lat = lat;
    }

    @JsonProperty("lat")
    public String getLat() {
        return this.lat;
    }

    @JsonProperty("lon")
    public void setLon(final String lon) {
        this.lon = lon;
    }

    @JsonProperty("lon")
    public String getLon() {
        return this.lon;
    }

    @JsonProperty("display_name")
    public void setDisplay_name(final String display_name) {
        this.display_name = display_name;
    }

    @JsonProperty("display_name")
    public String getDisplay_name() {
        return this.display_name;
    }

    @JsonProperty("place_rank")
    public void setPlace_rank(final String place_rank) {
        this.place_rank = place_rank;
    }

    @JsonProperty("place_rank")
    public String getPlace_rank() {
        return this.place_rank;
    }

    @JsonProperty("category")
    public void setCategory(final String category) {
        this.category = category;
    }

    @JsonProperty("category")
    public String getCategory() {
        return this.category;
    }

    @JsonProperty("type")
    public void setType(final String type) {
        this.type = type;
    }

    @JsonProperty("type")
    public String getType() {
        return this.type;
    }

    @JsonProperty("importance")
    public void setImportance(final Double importance) {
        this.importance = importance;
    }

    @JsonProperty("importance")
    public Double getImportance() {
        return this.importance;
    }

    @JsonProperty("address")
    public void setAddress(final Address address) {
        this.address = address;
    }

    @JsonProperty("address")
    public Address getAddress() {
        return this.address;
    }

    @JsonProperty("geojson")
    public void setGeojson(final Geometry geojson) {
        this.geojson = geojson;
    }

    @JsonProperty("geojson")
    public Geometry getGeojson() {
        return this.geojson;
    }

    private void _inject(java.lang.String name, Object value) {
        try {
            OptionalReflectionMethodInvoker setterInvoker = OptionalReflectionMethodInvoker.createSetter(this.getClass(), "JsonProperty", "value", name);
            setterInvoker.invoke(this, value);
        } catch (InvocationTargetException exception) {
            throw new RuntimeException(exception);
        }
    }

    @JsonAnySetter
    public void set(final java.lang.String name, final Object value) {
        Ensure.ensureThatArgument(name, Conditions.notNull());
        _inject(name, value);
        this._unknownMembers.put(name, value);
    }

    @JsonAnyGetter
    public Map get() {
        if (this._unknownMembers.isEmpty()) {
            return null;
        }
        return this._unknownMembers;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy