public class IntArrayProperty extends AbstractProperty
Constructor and Description |
---|
IntArrayProperty(java.lang.Enum<?> urn)
Construct an IntArrayProperty with no defined value.
|
IntArrayProperty(java.lang.Enum<?> urn,
int[] values)
Construct an IntArrayProperty with a defined value.
|
IntArrayProperty(IntArrayProperty other)
IntArrayProperty copy constructor.
|
IntArrayProperty(java.lang.String urn)
Construct an IntArrayProperty with no defined value.
|
IntArrayProperty(java.lang.String urn,
int[] values)
Construct an IntArrayProperty with a defined value.
|
Modifier and Type | Method and Description |
---|---|
IntArrayProperty |
copy()
Create a copy of this property.
|
int[] |
getValue()
Get the value of this property.
|
void |
push(int i)
Add a value to the array.
|
void |
read(java.io.InputStream in)
Read this property from a stream.
|
void |
setValue(int[] values)
Set the value of this property.
|
void |
takeValue(Property p)
Take on the value of another property.
|
java.lang.String |
toString() |
void |
write(java.io.OutputStream out)
Write this property to a stream.
|
fireChange, getURN, isDefined, setDefined, setEntity, undefine
public IntArrayProperty(java.lang.String urn)
urn
- The urn of this property.public IntArrayProperty(java.lang.Enum<?> urn)
urn
- The urn of this property.public IntArrayProperty(java.lang.String urn, int[] values)
urn
- The urn of this property.values
- The initial values of the property.public IntArrayProperty(java.lang.Enum<?> urn, int[] values)
urn
- The urn of this property.values
- The initial values of the property.public IntArrayProperty(IntArrayProperty other)
other
- The IntArrayProperty to copy.public int[] getValue()
Property
public void setValue(int[] values)
AbstractProperty.isDefined()
will return true.values
- The new values.public void push(int i)
i
- The value to add.public void takeValue(Property p)
Property
p
- The other property to inspect.public void write(java.io.OutputStream out) throws java.io.IOException
Property
out
- The stream to write to.java.io.IOException
- If the write fails.public void read(java.io.InputStream in) throws java.io.IOException
Property
in
- The stream to read from.java.io.IOException
- If the read fails.public java.lang.String toString()
toString
in class AbstractProperty
public IntArrayProperty copy()
Property