public class ParameterBlock extends Object implements Cloneable, Serializable
Modifier and Type | Field and Description |
---|---|
protected Vector<Object> |
parameters |
protected Vector<Object> |
sources |
Constructor and Description |
---|
ParameterBlock() |
ParameterBlock(Vector<Object> sources) |
ParameterBlock(Vector<Object> sources,
Vector<Object> parameters) |
protected Vector<Object> parameters
public ParameterBlock()
public ParameterBlock(Vector<Object> sources)
public ParameterBlock(Vector<Object> sources, Vector<Object> parameters)
public Object shallowClone()
public Object clone()
Object
o == o.clone()
is falseo.getClass() == o.clone().getClass()
is trueo.equals(o)
is trueHowever, these are not strict requirements, and may
be violated if necessary. Of the three requirements, the
last is the most commonly violated, particularly if the
subclass does not override Object.equals(Object)
.
If the Object you call clone() on does not implement
Cloneable
(which is a placeholder interface), then
a CloneNotSupportedException is thrown. Notice that
Object does not implement Cloneable; this method exists
as a convenience for subclasses that do.
Object's implementation of clone allocates space for the new Object using the correct class, without calling any constructors, and then fills in all of the new field values with the old field values. Thus, it is a shallow copy. However, subclasses are permitted to make a deep copy.
All array types implement Cloneable, and override
this method as follows (it should never fail):
public Object clone() { try { super.clone(); } catch (CloneNotSupportedException e) { throw new InternalError(e.getMessage()); } }
public ParameterBlock addSource(Object source)
public ParameterBlock setSource(Object source, int index)
public RenderedImage getRenderedSource(int index)
public RenderableImage getRenderableSource(int index)
public int getNumSources()
public Vector<Object> getSources()
public void setSources(Vector<Object> sources)
public void removeSources()
public int getNumParameters()
public Vector<Object> getParameters()
public void setParameters(Vector<Object> parameters)
public void removeParameters()
public ParameterBlock add(Object o)
public ParameterBlock add(byte b)
public ParameterBlock add(char c)
public ParameterBlock add(short s)
public ParameterBlock add(int i)
public ParameterBlock add(long l)
public ParameterBlock add(float f)
public ParameterBlock add(double d)
public ParameterBlock set(Object o, int index)
public ParameterBlock set(byte b, int index)
public ParameterBlock set(char c, int index)
public ParameterBlock set(short s, int index)
public ParameterBlock set(int i, int index)
public ParameterBlock set(long l, int index)
public ParameterBlock set(float f, int index)
public ParameterBlock set(double d, int index)
public Object getObjectParameter(int index)
public byte getByteParameter(int index)
public char getCharParameter(int index)
public short getShortParameter(int index)
public int getIntParameter(int index)
public long getLongParameter(int index)
public float getFloatParameter(int index)
public double getDoubleParameter(int index)
public Class[] getParamClasses()