xbn.array
Class VWObject

java.lang.Object
  |
  +--xbn.XBNObject
        |
        +--xbn.array.VectorWrapper
              |
              +--xbn.array.VWObject
All Implemented Interfaces:
Cloneable

public class VWObject
extends VectorWrapper
implements Cloneable

A VectorWrapper for java.lang.Objects.

Source code:  VWObject.java.  Example code  See the similar example code for VWObject.


Fields inherited from class xbn.XBNObject
bFALSE_IN_PRODUCTION, bTRUE_IN_PRODUCTION, sCNSTR, sES, sLINE_SEP
 
Constructor Summary
VWObject()
          Create a VWObject with default settings.
VWObject(boolean b_orderDirAscDesc)
          Create a VWObject.
VWObject(boolean b_addInOrder, boolean b_orderDirAscDesc)
          Create a VWObject.
VWObject(Vector v_ector)
          Create a VWObject.
VWObject(Vector v_ector, boolean b_orderDirAscDesc)
          Create a VWObject.
VWObject(Vector v_ector, boolean b_addInOrder, boolean b_orderDirAscDesc)
          Create a VWObject.
 
Method Summary
 void add(Object o_bject)
          Add an object.
 void addAPObject(APObject ap_object)
          Add an array of objects, as protected by the provided APObject.
 void addArray(Object[] a_object)
          Add an array of Objects.
protected  Object clone()
          Get a copy of this VWObject as an Object.
 Object[] getAOObject()
          Get the array of objects.
 Object getObject(int i_dx)
          Get an object from the vector, at the required array index.
 String getString(int i_dx)
          Get a string from the vector, at the required array index.
 VWObject getVWIClone()
          Get a copy of this VWObject.
 boolean isNull(int i_dx)
          Is the element at the requested array index null?
 
Methods inherited from class xbn.array.VectorWrapper
doAddInOrder, elementAt, getList, getOrderDirAscDesc, getVector, initializeVector, size
 
Methods inherited from class xbn.XBNObject
getXMsgPrefix, sop, sopl, sopl, throwAX, throwAXIfBadStr, throwAXIfNull, throwAXSpoof
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VWObject

public VWObject()

Create a VWObject with default settings.

Equal to VectorWrapper()


VWObject

public VWObject(Vector v_ector)

Create a VWObject.

Equal to VectorWrapper(v_ector)


VWObject

public VWObject(boolean b_orderDirAscDesc)

Create a VWObject.

Equal to VectorWrapper(b_orderDirAscDesc)


VWObject

public VWObject(Vector v_ector,
                boolean b_orderDirAscDesc)

Create a VWObject.

Equal to VectorWrapper(v_ector, b_orderDirAscDesc)


VWObject

public VWObject(boolean b_addInOrder,
                boolean b_orderDirAscDesc)

Create a VWObject.

Equal to VectorWrapper(b_addInOrder, b_orderDirAscDesc)


VWObject

public VWObject(Vector v_ector,
                boolean b_addInOrder,
                boolean b_orderDirAscDesc)

Create a VWObject.

Equal to VectorWrapper(v_ector, b_addInOrder, b_orderDisAscDesc)

Method Detail

add

public final void add(Object o_bject)

Add an object.

Parameters:
o_bject - The object to add. May be null.

addArray

public final void addArray(Object[] a_object)

Add an array of Objects.

Parameters:
a_object - The Object array to add. May not be null.

addAPObject

public final void addAPObject(APObject ap_object)

Add an array of objects, as protected by the provided APObject.

Equal to addArray(ap_object.[The internally-held object array])

Parameters:
ap_object - The APObject, whose protected array should be add, via addArray. May not be null.

getObject

public final Object getObject(int i_dx)

Get an object from the vector, at the required array index.

Parameters:
i_dx - The array index. Must range 0..[size() - 1], inclusive.

getString

public final String getString(int i_dx)

Get a string from the vector, at the required array index.

Overrides:
getString in class VectorWrapper
Returns:
getObject(i_dx).toString()

isNull

public final boolean isNull(int i_dx)

Is the element at the requested array index null?

Overrides:
isNull in class VectorWrapper
Returns:
(getObject(i_dx) == null)

getAOObject

public final Object[] getAOObject()

Get the array of objects. This array is composed of all those objects added since this object was created, or since the last time this function was called.

Returns:
An array containing all objects added to this object, in the same order as originally added.

getVWIClone

public final VWObject getVWIClone()

Get a copy of this VWObject.

Returns:
(VWObject)clone()

clone

protected final Object clone()
                      throws CloneNotSupportedException

Get a copy of this VWObject as an Object.

This recreates the internal vector, but points to the same object as this VWObject.

Overrides:
clone in class Object



Copyright 1997-2003, Jeff Epstein, All Rights Reserved. See top of source code files for copyright notice.

 

http://sourceforge.net/projects/xbnjava

 

SourceForge.net Logo