All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class tc.util.VectorUtils

java.lang.Object
   |
   +----tc.util.VectorUtils

public class VectorUtils
extends Object
VectorUtils is a collection of static utility methods for handling Vector objects. This class is not meant to be instantiated.

Version:
0.10, 1998/02/21
Author:
FRED development team, Antti Viljamaa
See Also:
Vector

Constructor Index

 o VectorUtils()
This class is not meant to be instantiated.

Method Index

 o appendElements(Vector, Vector)
Appends elements from one vector to another.
 o asString(Vector)
Returns a string representation of a vector of elements.
 o copyElements(Vector, Vector)
Copies elements from one vector to another.
 o createVector(Object)
Creates a vector with given element.
 o createVector(Object, Object)
Creates a vector with given elements.
 o createVector(Object, Object, Object)
Creates a vector with given elements.
 o createVector(Object, Object, Object, Object)
Creates a vector with given elements.
 o createVector(Object, Object, Object, Object, Object)
Creates a vector with given elements.
 o createVector(Object, Object, Object, Object, Object, Object)
Creates a vector with given elements.
 o getElement(Vector, String)
Returns the element with the specified name (returned by toString()) from the given vector.
 o removeElements(Vector, Vector)
Removes elements of a vector from another vector.
 o sameElements(Vector, Vector)
Returns true if the two given vectors have exactly the same elements.

Constructors

 o VectorUtils
 private VectorUtils()
This class is not meant to be instantiated.

Methods

 o appendElements
 public static void appendElements(Vector to,
                                   Vector from)
Appends elements from one vector to another.

 o asString
 public static String asString(Vector v)
Returns a string representation of a vector of elements.

 o copyElements
 public static void copyElements(Vector from,
                                 Vector to)
Copies elements from one vector to another.

 o createVector
 public static Vector createVector(Object o1)
Creates a vector with given element.

 o createVector
 public static Vector createVector(Object o1,
                                   Object o2)
Creates a vector with given elements.

 o createVector
 public static Vector createVector(Object o1,
                                   Object o2,
                                   Object o3)
Creates a vector with given elements.

 o createVector
 public static Vector createVector(Object o1,
                                   Object o2,
                                   Object o3,
                                   Object o4)
Creates a vector with given elements.

 o createVector
 public static Vector createVector(Object o1,
                                   Object o2,
                                   Object o3,
                                   Object o4,
                                   Object o5)
Creates a vector with given elements.

 o createVector
 public static Vector createVector(Object o1,
                                   Object o2,
                                   Object o3,
                                   Object o4,
                                   Object o5,
                                   Object o6)
Creates a vector with given elements.

 o getElement
 public static Object getElement(Vector v,
                                 String elementName)
Returns the element with the specified name (returned by toString()) from the given vector.

Parameters:
v - The vector from which the element is searched.
elementName - The name (toString()) of the searched element.
Returns:
The found element or null if not found.
 o sameElements
 public static boolean sameElements(Vector v1,
                                    Vector v2)
Returns true if the two given vectors have exactly the same elements.

Parameters:
v1 - The first vector to compare.
v2 - The second vector to compare.
Returns:
true if the two given vectors have exactly the same elements.
 o removeElements
 public static void removeElements(Vector from,
                                   Vector what)
Removes elements of a vector from another vector.


All Packages  Class Hierarchy  This Package  Previous  Next  Index