You should use ArrayList
instead of Vector
. Vector
used internal synchronisation, but that is rarely good enough for actual consistency, and only slows down execution when it is not really needed.
Also see this stackoverflow question.
More Related Contents:
- What are the differences between ArrayList and Vector?
- Vector vs Collections.synchronizedList(ArrayList)
- Removing duplicates from arraylist using set
- How to check two array list are same content in same position
- Logical disjunction of a list of booleans represented by integers [closed]
- ArrayList remove methods [closed]
- ArrayList, Loop and requisite if can not work that i want – Java 11
- Why is Java Vector (and Stack) class considered obsolete or deprecated?
- How do I remove repeated elements from ArrayList?
- Sorting an ArrayList of objects using a custom sorting order
- How to convert an ArrayList containing Integers to primitive int array?
- How does a ArrayList’s contains() method evaluate objects?
- Common elements in two lists
- Concurrent Modification Exception : adding to an ArrayList
- What is the difference between List and ArrayList? [duplicate]
- ArrayList initial capacity and IndexOutOfBoundsException [duplicate]
- Convert ArrayList into 2D array containing varying lengths of arrays
- How to efficiently remove all null elements from a ArrayList or String Array?
- Count occurrences of words in ArrayList [duplicate]
- Java – How Can I Write My ArrayList to a file, and Read (load) that file to the original ArrayList?
- Print ArrayList
- Correct way to synchronize ArrayList in java
- ArrayList or List declaration in Java
- Arrays.asList() of an array
- Java serialization of multidimensional array
- How does ArrayList work?
- Create an array of ArrayList elements
- ArrayList Generic without Type
- Iterate ArrayList in JSP
- Passing ArrayList of string arrays from one activity to another in android