package documentation

Utilities to work with Bounds objects.

From __init__.py:

Function copy Undocumented
Function from_extent Create Bounds from an Extent.
Function from_request_bbox Create Bounds from a KVP BBOX param.
Function intersect Undocumented
Function transform Undocumented
Function union Undocumented
def from_request_bbox(bbox: str, default_crs: gws.ICrs = None, always_xy=False) -> t.Optional[gws.Bounds]: (source)

Create Bounds from a KVP BBOX param.

See OGC 06-121r9, 10.2.3 Bounding box KVP encoding.

Parameters
bbox:strA string with four coordinates, optionally followed by a CRS spec.
default_crs:gws.ICrsDefault Crs.
always_xyIf True, coordinates are assumed to be in the XY (lon/lat) order
Returns
t.Optional[gws.Bounds]A Bounds object.
def from_extent(extent: gws.Extent, crs: gws.ICrs, always_xy=False) -> gws.Bounds: (source)

Create Bounds from an Extent.

Parameters
extent:gws.ExtentAn Extent.
crs:gws.ICrsA Crs object.
always_xyIf True, coordinates are assumed to be in the XY (lon/lat) order
Returns
gws.BoundsA Bounds object.

Undocumented

def union(bs: list[gws.Bounds]) -> gws.Bounds: (source)

Undocumented

def intersect(b1: gws.Bounds, b2: gws.Bounds) -> bool: (source)

Undocumented

def transform(b: gws.Bounds, crs_to: gws.ICrs) -> gws.Bounds: (source)

Undocumented