Class Scrambler


  • public class Scrambler
    extends Object
    A simple class for scrambling input data intended for testing performance under different circumstances.
    • Constructor Detail

      • Scrambler

        public Scrambler()
        A simple constructor which initializes the randomizer
    • Method Detail

      • scramble

        public void scramble​(Cell[][] data,
                             int column,
                             Scrambler.ScrambleType scrambleType)
        Lightweight scrambling method. Used to prepare data before measuring sorting performance.
        Parameters:
        data - a 2-D array of type Cell to scramble
        column - the index of the column used for scrambling in case of RISING or FALLING scrambleType.
        scrambleType - an enum value of type Scrambler.ScrambleType denoting how to scramble data.