Package org.goplanit.geoio.util
Class PlanitEntityFeatureTypeContext<T>
- java.lang.Object
-
- org.goplanit.geoio.util.PlanitEntityFeatureTypeContext<T>
-
- Type Parameters:
T
- type of planit entity
- Direct Known Subclasses:
PlanitConnectoidEdgeFeatureTypeContext
,PlanitConnectoidFeatureTypeContext
,PlanitConnectoidSegmentFeatureTypeContext
,PlanitLinkFeatureTypeContext
,PlanitLinkSegmentFeatureTypeContext
,PlanitNodeFeatureTypeContext
,PlanitRoutedServiceFeatureTypeContext
,PlanitServiceLegFeatureTypeContext
,PlanitServiceLegSegmentFeatureTypeContext
,PlanitServiceNodeFeatureTypeContext
,PlanitZoneFeatureTypeContext
public class PlanitEntityFeatureTypeContext<T> extends Object
Track contextual relevant information for each PLANit entity that is persisted- Author:
- markr
-
-
Field Summary
Fields Modifier and Type Field Description static String
DEFAULT_GEOMETRY_ATTRIBUTE_KEY
geotools attribute key for default geometry attribute as used here across entities
-
Constructor Summary
Constructors Modifier Constructor Description protected
PlanitEntityFeatureTypeContext(Class<T> clazz, Collection<Triple<String,String,Function<T,? extends Object>>> geoFeatureDescription)
Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
appendToFeatureTypeDescription(Triple<String,String,Function<T,? extends Object>>... featureDescriptionEntries)
append one or more additional entries to the descriptionList<Triple<String,String,Function<T,? extends Object>>>
getAttributeDescription()
String
getDefaultGeometryAttributeKey()
Access to default geometry attribute key as usedstatic <T extends org.locationtech.jts.geom.Geometry>
StringgetGisTypeFromJtsGeometryClass(Class<T> geometryClazz)
Given a type of JTS geometry in class form, provide the crresponding string representation for GIS based persistenceClass<T>
getPlanitEntityClass()
-
-
-
Field Detail
-
DEFAULT_GEOMETRY_ATTRIBUTE_KEY
public static final String DEFAULT_GEOMETRY_ATTRIBUTE_KEY
geotools attribute key for default geometry attribute as used here across entities- See Also:
- Constant Field Values
-
-
Method Detail
-
appendToFeatureTypeDescription
protected void appendToFeatureTypeDescription(Triple<String,String,Function<T,? extends Object>>... featureDescriptionEntries)
append one or more additional entries to the description- Parameters:
featureDescriptionEntries
- to append
-
getAttributeDescription
public List<Triple<String,String,Function<T,? extends Object>>> getAttributeDescription()
-
getDefaultGeometryAttributeKey
public String getDefaultGeometryAttributeKey()
Access to default geometry attribute key as used- Returns:
- attribute key used
-
getGisTypeFromJtsGeometryClass
public static <T extends org.locationtech.jts.geom.Geometry> String getGisTypeFromJtsGeometryClass(Class<T> geometryClazz)
Given a type of JTS geometry in class form, provide the crresponding string representation for GIS based persistence- Type Parameters:
T
- type of geometry- Parameters:
geometryClazz
- to get string representation for- Returns:
- string representation if supported, otherwise throw exception
-
-