PublishedLayer
Publish a host-selected main-schema relation for the lifetime of a with block.
__init__(self, connection: DuckDBPyConnection, view: str)
Use typed arguments with a DuckDB connection configured by your application.
Publish a host-selected main-schema relation for the lifetime of a with block.
__init__(self, connection: DuckDBPyConnection, view: str)west: floatsouth: floateast: floatnorth: floatA half-open interval of absolute instants.
start: datetimeend: datetimefeature_id: intlongitude: floatlatitude: floatlabel: str | Nonex: inty: intcount: intlongitude: floatlatitude: floatcount: inttotal: float | int | NoneEQ = '='NE = '<>'LT = '<'LE = '<='GT = '>'GE = '>='IS_NULL = 'IS NULL'IS_NOT_NULL = 'IS NOT NULL'Column name and value type registered by the application host.
name: strvalue_type: typecolumn_id: stroperator: FilterOperatorvalue: str | int | float | bool | None = Noneterms: tuple['FilterSpec', ...]terms: tuple['FilterSpec', ...]Read WGS84 points from a trusted host-selected main-schema relation. The host provisions a tenant-scoped connection and a primary/unique feature_id. Longitudes in the source use the [-180, 180] convention.
__init__(self, connection: DuckDBPyConnection, relation: str, *, attributes=None, time_column: str | None=None, catalog: str | None=None)fetch(self, viewport: Viewport, *, where: FilterSpec | None=None, time: TimeRange | None=None) → list[MapPoint]fetch_at_zoom(self, viewport: Viewport, zoom: int, *, where: FilterSpec | None=None, time: TimeRange | None=None) → list[GridCell] | list[MapPoint]Use a world-aligned degree grid below zoom 14 and points at higher zoom.
polygon_statistics(self, ring: tuple[tuple[float, float], ...], *, sum_attribute: str | None=None) → SelectionStatisticsAggregate original point coordinates inside a closed WGS84 selection ring.
ALL_MATCHES = 'all_matches'LOWEST_ID = 'lowest_id'region_counts: tuple[tuple[int, int], ...]unmatched: intno_position: intCount registered, same-CRS points in regions using inclusive polygon boundaries.
__init__(self, connection: DuckDBPyConnection, points: str, regions: str)count(self, assignment: BoundaryAssignment) → RegionCountsfeature_id: intgeometry: dictattributes: dictProject registered geometry attributes and select features by a WGS84 viewport.
__init__(self, connection: DuckDBPyConnection, relation: str, *, source_crs: str, attributes: Mapping[str, str] | None=None, catalog: str | None=None)fetch(self, viewport: Viewport) → list[GeometryFeature]Return each matching ID once, including shapes that touch an edge.
fetch_clipped(self, viewport: Viewport, *, buffer_degrees: float=0) → list[GeometryFeature]Return display geometry clipped to the viewport plus its optional angular buffer.
value: strcatalog: strrelation: strversion: strattributes: Mapping[str, AttributeColumn] | None = Nonetime_column: str | None = Nonedetails: Mapping[str, str] | None = Nonefeature_id: intfound: boolattributes: dictBind versioned point layers to catalog identities and host-supplied grants.
__init__(self, connection: DuckDBPyConnection, layers: Mapping[LayerId, RegisteredLayer], authorize: Callable[[object, LayerId, str], bool])fetch(self, principal: object, layer_id: LayerId, viewport: Viewport, *, zoom: int | None=None, where: FilterSpec | None=None, time: TimeRange | None=None) → tuple[str, list[MapPoint] | list[GridCell]]Fetch one authorized layer version, rejecting a replaced catalog.
details(self, principal: object, layer_id: LayerId, *, version: str, feature_ids: list[int]) → list[FeatureDetails]Fetch only the declared detail fields for an authorized immutable version.
zoom: intx: inty: intEncode a host-registered EPSG:3857 relation as Mapbox Vector Tiles.
__init__(self, connection: DuckDBPyConnection, relation: str, layer_name: str, *, attributes: Mapping[str, str] | None=None, catalog: str | None=None)fetch(self, tile: TileId, *, buffer: int=256) → bytesReturn an empty tile as zero bytes. Buffer size is in tile coordinates.
Use point occupancy for a committed Web Mercator snapshot to skip empty tiles.
__init__(self, layer, version, levels)build(cls, layer: VectorTileLayer, version: str, *, max_zoom: int=10, max_cells: int=500000) → 'TileOccupancy'might_have_feature(self, version: str, tile: TileId, *, buffer: int=256) → boolfetch(self, version: str, tile: TileId, *, buffer: int=256) → bytesHost-supplied cache identity for a tenant's authorized tile projection.
tenant: strlayer: strvisibility: strversion: str | Noneprojection: strbody: bytes | Noneetag: str | Nonenot_modified: boolAn LRU of immutable tiles with byte and entry limits.
__init__(self, *, max_entries: int, max_bytes: int)fetch(self, scope: TileScope, tile: TileId, generate: Callable[[], bytes], *, authorize: Callable[[TileScope], bool], if_none_match: str | None=None) → TileResponseResolve a tile under current grants and omit its body on an exact ETag match.
One authorized subscriber to shared generation work.
__init__(self, future, release, authorized)result(self, timeout=None) → bytescancel(self) → boolCoalesce in-flight tile generation while tracking subscriber cancellation.
__init__(self, *, workers: int)close(self)subscribe(self, scope: TileScope, tile: TileId, generate: Callable[[Event], bytes], *, authorize: Callable[[TileScope], bool]) → TileSubscription