@Test public void fromFeature_shouldConstructFromFeatureObject() throws Exception { assertThat(SimpleFeature.fromFeature(getTestFeature())).isEqualTo(getTestSimpleFeature()); }
public static SimpleFeature fromFeature(Feature feature) { return SimpleFeature.builder() .id(feature.properties.id) .gid(feature.properties.gid) .name(feature.properties.name) .country(feature.properties.country) .countryAbbr(feature.properties.country_a) .region(feature.properties.region) .regionAbbr(feature.properties.region_a) .county(feature.properties.county) .localAdmin(feature.properties.localadmin) .locality(feature.properties.locality) .neighborhood(feature.properties.neighbourhood) .confidence(feature.properties.confidence) .label(feature.properties.label) .layer(feature.properties.layer) .lat(feature.geometry.coordinates.get(1)) .lng(feature.geometry.coordinates.get(0)) .build(); }
SimpleFeature implements Parcelable { public static SimpleFeature fromFeature(Feature feature) { return SimpleFeature.builder() .id(feature.properties.id) .gid(feature.properties.gid) .name(feature.properties.name) .country(feature.properties.country) .countryAbbr(feature.properties.country_a) .region(feature.properties.region) .regionAbbr(feature.properties.region_a) .county(feature.properties.county) .localAdmin(feature.properties.localadmin) .locality(feature.properties.locality) .neighborhood(feature.properties.neighbourhood) .confidence(feature.properties.confidence) .label(feature.properties.label) .layer(feature.properties.layer) .lat(feature.geometry.coordinates.get(1)) .lng(feature.geometry.coordinates.get(0)) .build(); } }
SimpleFeature implements Parcelable { public static SimpleFeature fromFeature(Feature feature) { return SimpleFeature.builder() .id(feature.properties.id) .gid(feature.properties.gid) .name(feature.properties.name) .country(feature.properties.country) .countryAbbr(feature.properties.country_a) .region(feature.properties.region) .regionAbbr(feature.properties.region_a) .county(feature.properties.county) .localAdmin(feature.properties.localadmin) .locality(feature.properties.locality) .neighborhood(feature.properties.neighbourhood) .confidence(feature.properties.confidence) .label(feature.properties.label) .layer(feature.properties.layer) .lat(feature.geometry.coordinates.get(1)) .lng(feature.geometry.coordinates.get(0)) .build(); }  }
SimpleFeature implements Parcelable { public static SimpleFeature fromFeature(Feature feature) { return SimpleFeature.builder() .id(feature.properties.id) .gid(feature.properties.gid) .name(feature.properties.name) .country(feature.properties.country) .countryAbbr(feature.properties.country_a) .region(feature.properties.region) .regionAbbr(feature.properties.region_a) .county(feature.properties.county) .localAdmin(feature.properties.localadmin) .locality(feature.properties.locality) .neighborhood(feature.properties.neighbourhood) .confidence(feature.properties.confidence) .label(feature.properties.label) .layer(feature.properties.layer) .lat(feature.geometry.coordinates.get(1)) .lng(feature.geometry.coordinates.get(0)) .build(); }  static SimpleFeature create(String id, String gid, String name, String country,
      String countryAbbr, String region, String regionAbbr, String county, String localAdmin,
      String locality, String neighborhood, Double confidence, String label, String layer,
      double lat, double lng); abstract String id(); abstract String gid(); abstract String name(); abstract String country(); abstract String countryAbbr(); abstract String region(); abstract String regionAbbr(); abstract String county(); abstract String localAdmin(); abstract String locality(); abstract String neighborhood(); abstract Double confidence(); abstract String label(); abstract String layer(); abstract double lat(); abstract double lng(); static Builder builder(); abstract Builder toBuilder(); static SimpleFeature fromFeature(Feature feature); String address(); Feature toFeature(); Parcel toParcel(); static SimpleFeature readFromParcel(Parcel in); boolean isAddress(); }
SimpleFeature implements Parcelable { public static SimpleFeature fromFeature(Feature feature) { return SimpleFeature.builder() .id(feature.properties.id) .gid(feature.properties.gid) .name(feature.properties.name) .country(feature.properties.country) .countryAbbr(feature.properties.country_a) .region(feature.properties.region) .regionAbbr(feature.properties.region_a) .county(feature.properties.county) .localAdmin(feature.properties.localadmin) .locality(feature.properties.locality) .neighborhood(feature.properties.neighbourhood) .confidence(feature.properties.confidence) .label(feature.properties.label) .layer(feature.properties.layer) .lat(feature.geometry.coordinates.get(1)) .lng(feature.geometry.coordinates.get(0)) .build(); }  static SimpleFeature create(String id, String gid, String name, String country,
      String countryAbbr, String region, String regionAbbr, String county, String localAdmin,
      String locality, String neighborhood, Double confidence, String label, String layer,
      double lat, double lng); abstract String id(); abstract String gid(); abstract String name(); abstract String country(); abstract String countryAbbr(); abstract String region(); abstract String regionAbbr(); abstract String county(); abstract String localAdmin(); abstract String locality(); abstract String neighborhood(); abstract Double confidence(); abstract String label(); abstract String layer(); abstract double lat(); abstract double lng(); static Builder builder(); abstract Builder toBuilder(); static SimpleFeature fromFeature(Feature feature); String address(); Feature toFeature(); Parcel toParcel(); static SimpleFeature readFromParcel(Parcel in); boolean isAddress(); static final String ADDRESS_LAYER; }