A feature is something that can be drawn on a map, while a simple feature is one that does not contain any complicated internal structure. A SimpleFeature is "flat" recording of key value pairs. At least one of the values should be a Geometry, and the list of keys is known ahead of time.
Related
- Working with GeoTools Features (Deprecated GeoTools 2.4 code)
How to Create a SimpleFeature
You can create a SimpleFeature using the a builder:
GeometryFactory geomFactory = new GeometryFactory(); SimpleFeatureBuilder build = new SimpleFeatureBuilder( featureType ); //add the attributes build.add( geomFactory.createPoint( new Coordinate(40,50) ); build.add( 12 ); build.add( "My Name" ); SimpleFeature feature = builder.build( "Flag.12" );