Skip to content

@graphty/graphty-element / format / makeMask

Function: makeMask() ​

makeMask(length, fill?): U32

Defined in: graph-format/dist/src/util/mask.d.ts:17

Allocate a packed mask over length indices: ceil(length / 32) words, every bit clear, or every bit below length set when fill is true (design section 7.4).

Parameters ​

length ​

number

the number of indices the mask covers (nodeCount, edgeCount or arcCount)

fill? ​

boolean

the initial value of every bit; defaults to false

Returns ​

U32

the mask words