Class VarListBuilderWithSort<CONTENTS>

  • Type Parameters:
    CONTENTS - This is the 'type' of the original data-structure. For instance, in the case of class FileNode and FileNode.RetTypeChoice, this shall always be type FileNode.

    public class VarListBuilderWithSort<CONTENTS>
    extends java.lang.Object
    Implementation of the FileNode class 'RetTypeChoice'.

    This class will build an suite of implementations of the VarList interface. This version provides the ability to sort the input list-class.


    • Field Detail

      • VECTOR

        🡇    
        public final VarList<java.util.Vector<CONTENTS>,​CONTENTS> VECTOR
        This VarList instance has a 'retrieve()' method that will return a Vector whose Vector-contents are of parametrized-type 'CONTENTS'. The Vector returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<Vector<CONTENTS>, CONTENTS> VECTOR;
        
      • ARRAYLIST

        🡅  🡇    
        public final VarList<java.util.ArrayList<CONTENTS>,​CONTENTS> ARRAYLIST
        This VarList instance has a 'retrieve()' method that will return an ArrayList whose ArrayList-contents are of parametrized-type 'CONTENTS'. The ArrayList returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<ArrayList<CONTENTS>, CONTENTS> ARRAYLIST;
        
      • ITERATOR

        🡅  🡇    
        public final VarList<java.util.Iterator<CONTENTS>,​CONTENTS> ITERATOR
        This VarList instance has a 'retrieve()' method that will return an Iterator whose Iterator-contents are of parametrized-type 'CONTENTS'. The Iterator returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<Iterator<CONTENTS>, CONTENTS> ITERATOR;
        
      • ARRAY

        🡅  🡇    
        public final VarList<CONTENTS[],​CONTENTS> ARRAY
        This VarList instance has a 'retrieve()' method that will return an array whose array-contents are of parametrized-type 'CONTENTS'. The array returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<CONTENTS[], CONTENTS> ARRAY;
        
      • STREAM

        🡅  🡇    
        public final VarList<java.util.stream.Stream<CONTENTS>,​CONTENTS> STREAM
        This VarList instance has a 'retrieve()' method that will return a Stream whose Stream-contents are of parametrized-type 'CONTENTS'. The Stream returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<Stream<CONTENTS>, CONTENTS> STREAM;
        
      • STREAM_BUILDER

        🡅  🡇    
        public final VarList<java.util.stream.Stream.Builder<CONTENTS>,​CONTENTS> STREAM_BUILDER
        Instances of Stream.Builder cannot be sorted. Only a built Stream may be sorted. Therefore this parameter shall always be null.
        Code:
        Exact Field Declaration Expression:
        public final VarList<Stream.Builder<CONTENTS>, CONTENTS> STREAM_BUILDER = null;
        
      • LINKEDLIST

        🡅  🡇    
        public final VarList<java.util.LinkedList<CONTENTS>,​CONTENTS> LINKEDLIST
        This VarList instance has a 'retrieve()' method that will return a LinkedList whose LinkedList-contents are of parametrized-type 'CONTENTS'. The LinkedList returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<LinkedList<CONTENTS>, CONTENTS> LINKEDLIST;
        
      • TREESET

        🡅  🡇    
        public final VarList<java.util.TreeSet<CONTENTS>,​CONTENTS> TREESET
        This VarList instance has a 'retrieve()' method that will return a TreeSet whose TreeSet-contents are of parametrized-type 'CONTENTS'. The TreeSet returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<TreeSet<CONTENTS>, CONTENTS> TREESET;
        
      • STACK

        🡅  🡇    
        public final VarList<java.util.Stack<CONTENTS>,​CONTENTS> STACK
        This VarList instance has a 'retrieve()' method that will return a Stack whose Stack-contents are of parametrized-type 'CONTENTS'. The Stack returned will have already been sorted upon return.
        Code:
        Exact Field Declaration Expression:
        public final VarList<Stack<CONTENTS>, CONTENTS> STACK;
        
    • Constructor Detail

      • VarListBuilderWithSort

        🡅    
        public VarListBuilderWithSort​(java.util.Comparator<CONTENTS> comparator,
                                      java.lang.Class<CONTENTS> listClass)
        Builds all 8 of the VarList's provided by this builder class.
        Parameters:
        comparator - This is used to sort the returned list.
        listClass - This is the class of the final list that is produced. Due to Java's type-erasure for generics, this 'class' must be obtained here.