You are here


26 July, 2019 - 09:51
Available under Creative Commons-ShareAlike 4.0 International License. Download for free at

The following is an (abstract) implementation of IRACFactory using LRStruct as the underlining data structure. By varying the insertion strategy, which is an IAlgo on the internal LRStruct, we obtain different types of RAC: stack, queue, random, etc.

Figure 5.1 UML diagram of the abstract RAC and RAC factory definitions plus a few concrete RAC factories. 

The source code for the following examples can be downloaded here: