A RangeVector har as a private structure Ada.Containers.Ordered_Sets Set with rows of Velem type. In both Integer variables of a row a CodePoint’value is stored, f = low value, l = high value. No overlapping of row value ranges is allowed.
function verify(rvA: RangeVector) return Boolean;
check that every element in value-set of the RangeVector has a lower value (f) which is smaller or equal to the higher value (l) and no lower value is less than zero. Theese values are CodePoint’Val integer values.
function exists(rvA:RangeVector;val:CodePoint) return Boolean;
A RangeVector consists of velem’s with a lower and a higher bound CodePoint’Val. Iterate through all element and search for a velem containing this val CodePoint
function length(rvA:RangeVector) return Integer;
function equal(f,l:RangeVector) return Boolean;
function less(f,l:RangeVector) return Boolean;
function reserved_urvId(s:CFix) return Boolean;
A key cannot have a name equal to a Unicode General category name.
procedure putC(rvA:in out RangeVector;val:CodePoint);
procedure putC(rvA:in out RangeVector;f:CodePoint;l:CodePoint);
insert new element in a RangeVector
procedure putGC(rvA:in out RangeVector;val:CFix);
all elements based on a Unicode General category
procedure putGC(rvA:in out RangeVector;val:CodePoint);
all elements based on a Unicode General category
procedure putSET(rvA:in out RangeVector; val:Cvar; urv:RangeVectorPack.Map_TY.Map);
retreive elements from a MAP_TY with a val-key and insert these, see Y2018-Text.Util.Urvpack for how to create new codepoint classes.
Example with putC:
and the result looks like this:
______41 .. ______43(A part of the example ExSigma)
function clone(rvA:RangeVector) return RangeVector;
Clone or copy a RangeVector
procedure merge(rvA:in out RangeVector);
Merge elements in a RangeVector.procedure clear(rvA:in out RangeVector);
Clear a RangeVector or remove all rows from a RangeVector
procedure To_CList(CMap:in out CList.map; rvA:RangeVector;head:String:="";cntMax:Integer:=Integer'Last);
List a RangeVector to a Clist.map.
Head – insert a heading before the actual listing
cntMax – limit the number of rows to list for this RangeVector.
Number of elements in a RangeVector can be rather large
function verify(value: Set_TY.Set) return Boolean;
check that every element in value-set has a lower value (f) which
is smaller or equal to the higher value (l) and no lower value is
less than zero. These values are CodePoint’Val integer values.
All though this function has nothing to do with
RangeVectors it is here for use from outside the package.