Skip to content

Commit 4757f90

Browse files
feat: object-oriented support for the cbuffer, npoint, pose and rgeometry temporal types
Add first-class PyMEOS classes for the four extended temporal type families, mirroring the existing tpoint/ttext pattern and reusing the exact pymeos_cffi backing functions (no reimplementation): - main: TNpoint/TCbuffer/TPose/TRgeometry (+ Inst/Seq/SeqSet) - collections: base value types Npoint/Cbuffer/Pose and their NpointSet/CbufferSet/PoseSet (rgeometry's base is a shapely geometry, reusing the existing GeometrySet) - factory + package exports wired for all four families; tests added TCbuffer additionally exposes the full spatial-relationship surface MEOS provides for it (ever / always / temporal: contains, covers, disjoint, within-distance, intersects, touches), mirroring TPoint. Verified against the MEOS headers: MEOS defines no spatial-relationship API for npoint, pose or rgeometry, so their relationship surface is complete at zero by construction (documented, not excluded) -- each type covers 100% of its real MEOS-backed surface. The factory resolves the four type tags through the compiled binding (`_meos_cffi.lib`, the same source pymeos_cffi builds its enums from), so the build imports cleanly and the types activate even where pymeos_cffi's MeosType enum does not yet wrap the cbuffer/pose/rgeometry tags. Where MEOS provides no backing function the method is omitted rather than faked: notably trgeometry has no string input parser (built via from_geometry_tpose / hexwkb).
1 parent 35008e4 commit 4757f90

21 files changed

Lines changed: 6601 additions & 0 deletions

‎pymeos/__init__.py‎

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,22 @@
6666
"TGeogPointInst",
6767
"TGeogPointSeq",
6868
"TGeogPointSeqSet",
69+
"TNpoint",
70+
"TNpointInst",
71+
"TNpointSeq",
72+
"TNpointSeqSet",
73+
"TCbuffer",
74+
"TCbufferInst",
75+
"TCbufferSeq",
76+
"TCbufferSeqSet",
77+
"TPose",
78+
"TPoseInst",
79+
"TPoseSeq",
80+
"TPoseSeqSet",
81+
"TRgeometry",
82+
"TRgeometryInst",
83+
"TRgeometrySeq",
84+
"TRgeometrySeqSet",
6985
# temporal
7086
"Temporal",
7187
"TInstant",
@@ -86,6 +102,12 @@
86102
"GeoSet",
87103
"GeometrySet",
88104
"GeographySet",
105+
"Npoint",
106+
"NpointSet",
107+
"Cbuffer",
108+
"CbufferSet",
109+
"Pose",
110+
"PoseSet",
89111
# extras
90112
"TInterpolation",
91113
# aggregators

‎pymeos/collections/__init__.py‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
from .time import *
55
from .text import *
66
from .geo import *
7+
from .npoint import *
8+
from .cbuffer import *
9+
from .pose import *
710

811
__all__ = [
912
"Set",
@@ -30,4 +33,10 @@
3033
"FloatSet",
3134
"FloatSpan",
3235
"FloatSpanSet",
36+
"Npoint",
37+
"NpointSet",
38+
"Cbuffer",
39+
"CbufferSet",
40+
"Pose",
41+
"PoseSet",
3342
]
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
from .cbuffer import Cbuffer
2+
from .cbufferset import CbufferSet
3+
4+
__all__ = ["Cbuffer", "CbufferSet"]

0 commit comments

Comments
 (0)