Skip to content

Bordered and BorderedM

Андрей Мулик edited this page Sep 21, 2023 · 1 revision

Bordered and BorderedM

Bordered is a class of types that have a fixed dimension, represented by a pair of (immutable) indices of the same type - the smallest and the largest.

BorderedM is a class of types that have a dynamic dimension, represented by a pair of (changeable) indices of the same type - the smallest and the largest.

Historical reference

Initially, the sizeOf and getSizeOf methods were found in the Bordered and BorderedM classes. Starting with sdp-0.3, they are moved into Estimate and EstimateM and inherited from them.

Historically, Bordered and BorderedM were implemented in the SDP.Linear and SDP.LinearM modules. Starting with sdp-0.3 they are moved to a separate module SDP.Bordered and re-exported from SDP.Linear and SDP.LinearM for backward compatibility.

The types sizesOf and getSizesOf changed in sdp-0.3 to return (:&) - a typed fixed-length list. Previously, regular lists were returned.

API

Function Bordered Added BorderedM Added
Get bounds bounds 0.2 getBounds 0.2
Get lower bound lower 0.2 getLower 0.2
Get upper bound upper 0.2 getUpper 0.2
Get sizes sizesOf 0.2 getSizesOf 0.2
Is there an element with this index? indexIn 0.2 nowIndexIn 0.2
List of all indexes indices 0.2 getIndices 0.2
Is there an element with this offset? offsetOf 0.2 getOffsetOf 0.2
Change borders to specified viewOf 0.3 getViewOf 0.3