Class FeatureAgentFactory<T>

java.lang.Object
repast.simphony.space.gis.FeatureAgentFactory<T>
Direct Known Subclasses:
DefaultFeatureAgentFactory, ShapefileFeatureAgentFactory

public abstract class FeatureAgentFactory<T> extends Object
Abstract factory for adapting agents to features. This creates a FeatureType given an agent class. TODO Geotools [minor] - this class would benefit from cleanup since there's lots of duplicate code, along with subclasses: ShapefileFeatureAgentFactory DefaultFeatureAgentFactory
Author:
Nick Collier, Eric Tatara
  • Field Details

    • GEOM_ATTRIBUTE_NAME

      public static final String GEOM_ATTRIBUTE_NAME
      See Also:
    • classAttributeList

      protected List<repast.simphony.space.gis.FeatureAgentFactory.ObjectClassAttributeData> classAttributeList
  • Constructor Details

    • FeatureAgentFactory

      public FeatureAgentFactory()
  • Method Details

    • getFeature

      public abstract FeatureAgent getFeature(T agent, Geography geography)
    • getShapefileFeatureType

      protected org.opengis.feature.simple.SimpleFeatureType getShapefileFeatureType(Class agentClass, org.opengis.referencing.crs.CoordinateReferenceSystem coordRefSystem, Class<? extends org.locationtech.jts.geom.Geometry> geomClass) throws IntrospectionException, org.geotools.feature.SchemaException
      Gets a feature type appropriate for writing to shapefile.
      Parameters:
      agentClass -
      coordRefSystem -
      geomClass -
      Returns:
      Throws:
      IntrospectionException
      org.geotools.feature.SchemaException
    • getShapefileFeatureType

      protected org.opengis.feature.simple.SimpleFeatureType getShapefileFeatureType(Class agentClass, org.opengis.referencing.crs.CoordinateReferenceSystem coordRefSystem, Class<? extends org.locationtech.jts.geom.Geometry> geomClass, List<FeatureAttributeAdapter> adapters) throws IntrospectionException, org.geotools.feature.SchemaException
      Gets a feature type appropriate for writing to shapefile.
      Parameters:
      agentClass -
      coordRefSystem -
      geomClass -
      Returns:
      Throws:
      IntrospectionException
      org.geotools.feature.SchemaException
    • getFeatureType

      protected org.opengis.feature.simple.SimpleFeatureType getFeatureType(Class agentClass, org.opengis.referencing.crs.CoordinateReferenceSystem coordRefSystem, Class<? extends org.locationtech.jts.geom.Geometry> geomClass) throws IntrospectionException, org.geotools.feature.SchemaException
      Throws:
      IntrospectionException
      org.geotools.feature.SchemaException
    • getFeatureType

      protected org.opengis.feature.simple.SimpleFeatureType getFeatureType(Class agentClass, org.opengis.referencing.crs.CoordinateReferenceSystem coordRefSystem, Class<? extends org.locationtech.jts.geom.Geometry> geomClass, List<FeatureAttributeAdapter> adapters) throws IntrospectionException, org.geotools.feature.SchemaException
      Throws:
      IntrospectionException
      org.geotools.feature.SchemaException
    • createClassAttributes

      protected void createClassAttributes(Class<T> agentClass)
      Create a list of class attributes for the FeatureAgent
      Parameters:
      agentClass -