Package io.debezium.data.geometry
Class Geometry
java.lang.Object
io.debezium.data.geometry.Geometry
A semantic type for an OGC Simple Features for SQL Geometry.
Used to describe geometries on a planar basis (rather than Geography, which is a spherical basis).
See the Open Geospatial Consortium Simple Features Access specification for details on the Well-Known-Binary format http://www.opengeospatial.org/standards/sfa
WKB has to be forwards-compatible to the spec, so strict OGC WKB, and EWKB (PostGIS) are both ok.
- Author:
- Robert Coup
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic org.apache.kafka.connect.data.SchemaBuilder
builder()
Returns aSchemaBuilder
for a Geometry field.static org.apache.kafka.connect.data.Struct
createValue
(org.apache.kafka.connect.data.Schema geomSchema, byte[] wkb, Integer srid) Create a value for this schema using WKB and SRIDstatic org.apache.kafka.connect.data.Schema
schema()
Returns aSchemaBuilder
for a Geometry field, with all other default Schema settings.
-
Field Details
-
LOGICAL_NAME
- See Also:
-
WKB_FIELD
- See Also:
-
SRID_FIELD
- See Also:
-
-
Constructor Details
-
Geometry
public Geometry()
-
-
Method Details
-
builder
public static org.apache.kafka.connect.data.SchemaBuilder builder()Returns aSchemaBuilder
for a Geometry field. You can use the resulting SchemaBuilder to set additional schema settings such as required/optional, default value, and documentation.- Returns:
- the schema builder
-
schema
public static org.apache.kafka.connect.data.Schema schema()Returns aSchemaBuilder
for a Geometry field, with all other default Schema settings.- Returns:
- the schema
- See Also:
-
createValue
public static org.apache.kafka.connect.data.Struct createValue(org.apache.kafka.connect.data.Schema geomSchema, byte[] wkb, Integer srid) Create a value for this schema using WKB and SRID- Parameters:
geomSchema
- aSchema
instance which represents a geometry; may not be nullwkb
- OGC Well-Known Binary representation of the geometry; may not be nullsrid
- the coordinate reference system identifier; may be null if unset/unknown- Returns:
- a
Struct
which represents a Connect value for this schema; never null
-