UP

JOAFIP heap file management

append of a first data record to store an object state

Current next identifier value is used for new data record, then current next identifier value is incremented by 1
The heap file size is increased to store the data record.

initial file state

final file state



append of a second data record to store an object state

Since there is no free data record identifier, the value used is the greatest existing value incremented by 1.
The heap file size is increased to store the data record.

initial file state

final file state



append of a third data record to store an object state

Current next identifier value is used for new data record, then current next identifier value is incremented by 1
The heap file size is increased to store the data record.

initial file state

final file state



Delete the data record #3

A free area replace the previous data record.
The heap file size keep unchanged.

initial file state

final file state



Delete the data record #2

A free area replace the previous data record merging with adjacent free area
The heap file size keep unchanged.

initial file state

final file state



append of a fourth data record to store an object state

Current next identifier value is used for new data record, then current next identifier value is incremented by 1
The heap file size keep unchanged since free area is large enough to contains new data record.
The free area is reduce to its previous size minus the new data record size.

initial file state

final file state



© 2007-2008, joafip