DecodeUntaggedBox2DValue decodes a value encoded by EncodeUntaggedBox2DValue.
(b []byte)
| 3032 | |
| 3033 | // DecodeUntaggedBox2DValue decodes a value encoded by EncodeUntaggedBox2DValue. |
| 3034 | func DecodeUntaggedBox2DValue(b []byte) (remaining []byte, box geopb.BoundingBox, err error) { |
| 3035 | box = geopb.BoundingBox{} |
| 3036 | remaining = b |
| 3037 | |
| 3038 | remaining, box.LoX, err = DecodeFloatAscending(remaining) |
| 3039 | if err != nil { |
| 3040 | return b, box, err |
| 3041 | } |
| 3042 | remaining, box.HiX, err = DecodeFloatAscending(remaining) |
| 3043 | if err != nil { |
| 3044 | return b, box, err |
| 3045 | } |
| 3046 | remaining, box.LoY, err = DecodeFloatAscending(remaining) |
| 3047 | if err != nil { |
| 3048 | return b, box, err |
| 3049 | } |
| 3050 | remaining, box.HiY, err = DecodeFloatAscending(remaining) |
| 3051 | if err != nil { |
| 3052 | return b, box, err |
| 3053 | } |
| 3054 | return remaining, box, err |
| 3055 | } |
| 3056 | |
| 3057 | // DecodeUntaggedGeoValue decodes a value encoded by EncodeUntaggedGeoValue into |
| 3058 | // the provided geopb.SpatialObject reference. The so parameter must already be |
nothing calls this directly
no test coverage detected
searching dependent graphs…