/** * Build a {@link Feature} with the given {@link Geometry}. * * @param geometry The Geometry to build Feature from * * @return An instance of Feature */ public static Feature of(Geometry<?> geometry) { return builder().withGeometry(geometry).build(); }
/** * Build a {@link Feature} with the given {@link Geometry}. * * @param geometry The Geometry to build Feature from * * @return An instance of Feature */ public static Feature of(Geometry<?> geometry) { return builder().withGeometry(geometry).build(); }
@Override public Feature read(JsonReader in) throws IOException { Feature.Builder builder = Feature.builder(); if (in.peek() == JsonToken.NULL) { in.nextNull();
@Override public Feature read(JsonReader in) throws IOException { Feature.Builder builder = Feature.builder(); if (in.peek() == JsonToken.NULL) { in.nextNull();
public static Builder builder(Feature feature) { return builder().withGeometry(feature.geometry).withProperties(feature.properties).withId(feature.id); }
public static Builder builder(Feature feature) { return builder().withGeometry(feature.geometry).withProperties(feature.properties).withId(feature.id); }
public static Feature featureWithGeometry(Geometry<?> geometry) { return Feature.builder().withGeometry(Point.from(12.3, 45.3)).build(); }
public static Feature featureWithId(String id) { return Feature.builder().withGeometry(Point.from(12.3, 45.3)).withId(id).build(); }
public static Feature featureWithProperties(Map<String, JsonElement> properties) { return Feature.builder().withGeometry(Point.from(12.3, 45.3)).withProperties(properties).build(); }