NITCbase/nitcbase.github.io

Use an enum instead of `char` as Block type argument in BlockBuffer Constructor1

Closed this issue · 1 comments

Using char type for Block type as argument in Constructor 1 is inconvenient as methods use int form of Block types. Using int as argument in Constructor 1 would collide with the signature for Constructor 2. Instead, we can define an enum like so -

enum BlockType {
    LeafIndex = IND_LEAF,
    InternalIndex = IND_INTERNAL,
    Record = REC
}

This is part of Constructor 1 issue #33