In Oracle Event Processing, an event may contain one or more properties that represent a geometry form. These properties are typed as com.oracle.cep.cartridge.spatial.Geometry
, which is a Java class provided by the Spatial cartridge.
A geometry type may represent the following forms:
Point
Rectangle
Line String
Polygons
Rectangles and polygons, in general, are also called closed shapes , as they are made of lines that link together. The following diagram describes some of these forms:
The line (or arc) separating the interior of a polygon from its external is called its boundary .
To create an event property containing a point form, you can use the following static Java method on the Geometry
class:
com.oracle.cep.cartridge.spatial.Geometry.createPoint @spatial(double x, double y)
This method takes two arguments, representing the x
and y
coordinate of a two-dimensional point, and returns an object of Geometry
type.
To avoid having to type the full package name for the Geometry...