Hermes@Neo4j
Neo4jSpatiotemporal.DefaultLayerTemporal Class Reference
Inheritance diagram for Neo4jSpatiotemporal.DefaultLayerTemporal:
Neo4jSpatiotemporal.TemporalConstants Neo4jSpatiotemporal.LayerST Neo4jSpatiotemporal.SpatialTemporalDataset Neo4jSpatiotemporal.EditableLayerImplTemporal Neo4jSpatiotemporal.DynamicLayerTemporal Neo4jSpatiotemporal.OrderedEditableLayerTemporal Neo4jSpatiotemporal.SimplePointLayerST

Public Member Functions

String getName ()
 
SpatialTemporalDatabaseService getSpatialDatabase ()
 
LayerIndexReaderTemporal getIndex ()
 
SpatialTemporalDatabaseRecord add (Node geomNode)
 
TemporalGeometryFactory getGeometryFactory ()
 
void setCoordinateReferenceSystem (CoordinateReferenceSystem crs)
 
CoordinateReferenceSystem getCoordinateReferenceSystem ()
 
void setGeometryType (Integer geometryType)
 
Integer getGeometryType ()
 
String[] getExtraPropertyNames ()
 
void setExtraPropertyNames (String[] names)
 
void mergeExtraPropertyNames (String[] names)
 
void initialize (SpatialTemporalDatabaseService spatialDatabase, String name, Node layerNode)
 
Node getLayerNode ()
 
void delete (Listener monitor)
 
SpatialTemporalDataset getDataset ()
 
Iterable< Node > getAllGeometryNodes ()
 
boolean containsGeometryNode (Node geomNode)
 
Iterable<?extends Geometry > getAllGeometries ()
 
TemporalGeometryEncoder getGeometryEncoder ()
 
Iterable< ?extends LayerSTgetLayers ()
 
Object getStyle ()
 
PropertyMappingManagerTemporal getPropertyMappingManager ()
 

Protected Member Functions

 DefaultLayerTemporal ()
 
GraphDatabaseService getDatabase ()
 

Static Protected Member Functions

static LayerST makeLayerFromNode (SpatialTemporalDatabaseService spatialDatabase, Node layerNode)
 
static LayerST makeLayerAndNode (SpatialTemporalDatabaseService spatialDatabase, String name, Class< ?extends TemporalGeometryEncoder > geometryEncoderClass, Class< ?extends LayerST > layerClass)
 

Protected Attributes

Node layerNode
 
TemporalGeometryEncoder geometryEncoder
 
TemporalGeometryFactory geometryFactory
 
LayerRTreeIndexTemporal index
 

Additional Inherited Members

- Public Attributes inherited from Neo4jSpatiotemporal.TemporalConstants
String PROP_LAYER = "layer"
 
String PROP_LAYERNODEEXTRAPROPS = "layerprops"
 
String PROP_CRS = "layercrs"
 
String PROP_CREATIONTIME = "ctime"
 
String PROP_GEOMENCODER = "geomencoder"
 
String PROP_GEOMENCODER_CONFIG = "geomencoder_config"
 
String PROP_LAYER_CLASS = "layer_class"
 
String PROP_TYPE = "gtype"
 
String PROP_QUERY = "query"
 
String PROP_WKB = "wkb"
 
String PROP_WKT = "wkt"
 
String[] RESERVED_PROPS
 
int GTYPE_GEOMETRY = 0
 
int GTYPE_POINT = 1
 
int GTYPE_LINESTRING = 2
 
int GTYPE_POLYGON = 3
 
int GTYPE_MULTIPOINT = 4
 
int GTYPE_MULTILINESTRING = 5
 
int GTYPE_MULTIPOLYGON = 6
 

Detailed Description

Instances of Layer provide the ability for developers to add/remove and edit geometries associated with a single dataset (or layer). This includes support for several storage mechanisms, like in-node (geometries in properties) and sub-graph (geometries describe by the graph). A Layer can be associated with a dataset. In cases where the dataset contains only one layer, the layer itself is the dataset.

You should not construct the DefaultLayer directly, but use the included factor methods for creating layers based on configurations. This will instantiate the appropriate class correctly. See the methods makeLayerFromNode and makeLayerInstance.

Constructor & Destructor Documentation

Neo4jSpatiotemporal.DefaultLayerTemporal.DefaultLayerTemporal ( )
protected

The constructor is protected because we should not construct this class directly, but use the factory methods to create Layers based on configurations

Member Function Documentation

SpatialTemporalDatabaseRecord Neo4jSpatiotemporal.DefaultLayerTemporal.add ( Node  geomNode)

Add the geometry encoded in the given Node. This causes the geometry to appear in the index.

Implements Neo4jSpatiotemporal.LayerST.

boolean Neo4jSpatiotemporal.DefaultLayerTemporal.containsGeometryNode ( Node  node)

Does the dataset (or layer) contain the geometry specified by this node.

Returns
boolean true/false if the geometry node is in this Dataset or LayerST

Implements Neo4jSpatiotemporal.SpatialTemporalDataset.

void Neo4jSpatiotemporal.DefaultLayerTemporal.delete ( Listener  monitor)

Delete Layer

Implements Neo4jSpatiotemporal.LayerST.

Iterable<? extends Geometry> Neo4jSpatiotemporal.DefaultLayerTemporal.getAllGeometries ( )

Provides a method for iterating over all geometries in this dataset. This is similar to the getAllGeometryNodes() method but internally converts the Node to a Geometry.

Returns
iterable over geometries in the dataset

Implements Neo4jSpatiotemporal.SpatialTemporalDataset.

Iterable<Node> Neo4jSpatiotemporal.DefaultLayerTemporal.getAllGeometryNodes ( )

Provides a method for iterating over all nodes that represent geometries in this dataset. This is similar to the getAllNodes() methods from GraphDatabaseService but will only return nodes that this dataset considers its own, and can be passed to the GeometryEncoder to generate a Geometry. There is no restricting on a node belonging to multiple datasets, or multiple layers within the same dataset.

Returns
iterable over geometry nodes in the dataset

Implements Neo4jSpatiotemporal.SpatialTemporalDataset.

CoordinateReferenceSystem Neo4jSpatiotemporal.DefaultLayerTemporal.getCoordinateReferenceSystem ( )

Each layer can represent data stored in a specific coordinate reference system, or projection.

Returns

Implements Neo4jSpatiotemporal.LayerST.

GraphDatabaseService Neo4jSpatiotemporal.DefaultLayerTemporal.getDatabase ( )
protected
SpatialTemporalDataset Neo4jSpatiotemporal.DefaultLayerTemporal.getDataset ( )

Each layer is associated with a SpatialTemporalDataset. This can be a one-for-one match to the layer, or can be expressed as many layers on a single dataset.

Returns
SpatialTemporalDataset containing the data indexed by this layer.

Implements Neo4jSpatiotemporal.LayerST.

String [] Neo4jSpatiotemporal.DefaultLayerTemporal.getExtraPropertyNames ( )

Each layer contains geometries with optional attributes.

Returns
String array of all attribute names

Implements Neo4jSpatiotemporal.LayerST.

TemporalGeometryEncoder Neo4jSpatiotemporal.DefaultLayerTemporal.getGeometryEncoder ( )

Return the geometry encoder used by this SpatialDataset to convert individual geometries to and from the database structure.

Returns
GeometryEncoder for this dataset

Implements Neo4jSpatiotemporal.LayerST.

TemporalGeometryFactory Neo4jSpatiotemporal.DefaultLayerTemporal.getGeometryFactory ( )
Integer Neo4jSpatiotemporal.DefaultLayerTemporal.getGeometryType ( )

The layer conforms with the Geotools pattern of only allowing a single geometry per layer.

Returns
integer key for the geotools geometry type

Implements Neo4jSpatiotemporal.LayerST.

LayerIndexReaderTemporal Neo4jSpatiotemporal.DefaultLayerTemporal.getIndex ( )

Every layer using a specific implementation of the SpatialTemporalIndexReader and SpatialTemporalIndexWriter for indexing the data in that layer.

Returns
the SpatialIndexReader used to perform searches on the data in the layer

Implements Neo4jSpatiotemporal.LayerST.

Node Neo4jSpatiotemporal.DefaultLayerTemporal.getLayerNode ( )

All layers are associated with a single node in the database. This node will have properties, relationships (sub-graph) or both to describe the contents of the layer

Implements Neo4jSpatiotemporal.LayerST.

Iterable< ? extends LayerST> Neo4jSpatiotemporal.DefaultLayerTemporal.getLayers ( )

This dataset contains only one layer, itself.

Returns
iterable over all Layers that can be viewed from this dataset

Implements Neo4jSpatiotemporal.SpatialTemporalDataset.

String Neo4jSpatiotemporal.DefaultLayerTemporal.getName ( )

Every layer is defined by a unique name. Uniqueness is not enforced, but lack of uniqueness will not guarrantee the right layer returned from a search.

Returns

Implements Neo4jSpatiotemporal.LayerST.

PropertyMappingManagerTemporal Neo4jSpatiotemporal.DefaultLayerTemporal.getPropertyMappingManager ( )
SpatialTemporalDatabaseService Neo4jSpatiotemporal.DefaultLayerTemporal.getSpatialDatabase ( )

Since the layer is a key object passed around to most code, it is important to be able to access the generic spatial API from this object.

Returns
instance of the SpatialTemporalDatabaseService object for general access to the spatial database features

Implements Neo4jSpatiotemporal.LayerST.

Object Neo4jSpatiotemporal.DefaultLayerTemporal.getStyle ( )

Override this method to provide a style if your layer wishes to control its own rendering in the GIS. If a Style is returned, it is used. If a File is returned, it is opened and assumed to contain SLD contents. If a String is returned, it is assumed to contain SLD contents.

Returns
null

Implements Neo4jSpatiotemporal.LayerST.

void Neo4jSpatiotemporal.DefaultLayerTemporal.initialize ( SpatialTemporalDatabaseService  spatialDatabase,
String  name,
Node  layerNode 
)

The layer is constructed from metadata in the layer node, which requires that the layer have a no-argument constructor. The real initialization of the layer is then performed by calling this method. The layer implementation can store the passed parameters for later use satisfying the prupose of the layer API (see other LayerST methods).

Parameters
spatialDatabase
name
layerNode

Implements Neo4jSpatiotemporal.LayerST.

static LayerST Neo4jSpatiotemporal.DefaultLayerTemporal.makeLayerAndNode ( SpatialTemporalDatabaseService  spatialDatabase,
String  name,
Class< ?extends TemporalGeometryEncoder geometryEncoderClass,
Class< ?extends LayerST layerClass 
)
staticprotected

Factory method to construct a layer with the specified layer class. This can be used when creating a layer for the first time. It will also construct the underlying Node in the graph.

Parameters
spatialDatabase
name
layerClass
Returns
new Layer instance based on newly created layer Node
static LayerST Neo4jSpatiotemporal.DefaultLayerTemporal.makeLayerFromNode ( SpatialTemporalDatabaseService  spatialDatabase,
Node  layerNode 
)
staticprotected

Factory method to construct a layer from an existing layerNode. This will read the layer class from the layer node properties and construct the correct class from that.

Parameters
spatialDatabase
layerNode
Returns
new layer instance from existing layer node
void Neo4jSpatiotemporal.DefaultLayerTemporal.mergeExtraPropertyNames ( String[]  names)
void Neo4jSpatiotemporal.DefaultLayerTemporal.setCoordinateReferenceSystem ( CoordinateReferenceSystem  crs)
void Neo4jSpatiotemporal.DefaultLayerTemporal.setExtraPropertyNames ( String[]  names)
void Neo4jSpatiotemporal.DefaultLayerTemporal.setGeometryType ( Integer  geometryType)

Member Data Documentation

TemporalGeometryEncoder Neo4jSpatiotemporal.DefaultLayerTemporal.geometryEncoder
protected
TemporalGeometryFactory Neo4jSpatiotemporal.DefaultLayerTemporal.geometryFactory
protected
LayerRTreeIndexTemporal Neo4jSpatiotemporal.DefaultLayerTemporal.index
protected
Node Neo4jSpatiotemporal.DefaultLayerTemporal.layerNode
protected

The documentation for this class was generated from the following file: