MCPcopy Create free account
hub / github.com/cockroachdb/cockroachdb-parser / EncodeBox2DAscending

Function EncodeBox2DAscending

pkg/util/encoding/encoding.go:1277–1284  ·  view source on GitHub ↗

EncodeBox2DAscending encodes a bounding box in ascending order.

(b []byte, box geopb.BoundingBox)

Source from the content-addressed store, hash-verified

1275
1276// EncodeBox2DAscending encodes a bounding box in ascending order.
1277func EncodeBox2DAscending(b []byte, box geopb.BoundingBox) ([]byte, error) {
1278 b = append(b, box2DMarker)
1279 b = EncodeFloatAscending(b, box.LoX)
1280 b = EncodeFloatAscending(b, box.HiX)
1281 b = EncodeFloatAscending(b, box.LoY)
1282 b = EncodeFloatAscending(b, box.HiY)
1283 return b, nil
1284}
1285
1286// EncodeBox2DDescending encodes a bounding box in descending order.
1287func EncodeBox2DDescending(b []byte, box geopb.BoundingBox) ([]byte, error) {

Callers

nothing calls this directly

Calls 1

EncodeFloatAscendingFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…