public class BubbleSort extends SortAlgorithm
indexList| Constructor and Description |
|---|
BubbleSort()
Create a new instance of BubbleSort
|
| Modifier and Type | Method and Description |
|---|---|
java.util.ArrayList |
sort(java.lang.String valueType,
EvaluateMathDef eval,
java.util.ArrayList sortList,
boolean sortIndexes)
Run the sort over all the elements in the array.
|
getIndexList, randomisepublic java.util.ArrayList sort(java.lang.String valueType,
EvaluateMathDef eval,
java.util.ArrayList sortList,
boolean sortIndexes)
throws java.lang.Exception
sort in class SortAlgorithmvalueType - the object type being evaluated.eval - the evaluation function.sortList - the array of values to sort.sortIndexes - if true also record the new index positions from their original position.
If false do not do this, as it requires extra processing steps.java.lang.Exception - any error.