public class IntProperty extends AbstractProperty
Constructor and Description |
---|
IntProperty(java.lang.Enum<?> urn)
Construct an IntProperty with no defined value.
|
IntProperty(java.lang.Enum<?> urn,
int value)
Construct an IntProperty with a defined value.
|
IntProperty(IntProperty other)
IntProperty copy constructor.
|
IntProperty(java.lang.String urn)
Construct an IntProperty with no defined value.
|
IntProperty(java.lang.String urn,
int value)
Construct an IntProperty with a defined value.
|
Modifier and Type | Method and Description |
---|---|
IntProperty |
copy()
Create a copy of this property.
|
java.lang.Integer |
getValue()
Get the value of this property.
|
void |
read(java.io.InputStream in)
Read this property from a stream.
|
void |
setValue(int value)
Set the value of this property.
|
void |
takeValue(Property p)
Take on the value of another property.
|
void |
write(java.io.OutputStream out)
Write this property to a stream.
|
fireChange, getURN, isDefined, setDefined, setEntity, toString, undefine
public IntProperty(java.lang.String urn)
urn
- The urn of this property.public IntProperty(java.lang.Enum<?> urn)
urn
- The urn of this property.public IntProperty(java.lang.String urn, int value)
urn
- The urn of this property.value
- The initial value of the property.public IntProperty(java.lang.Enum<?> urn, int value)
urn
- The urn of this property.value
- The initial value of the property.public IntProperty(IntProperty other)
other
- The IntProperty to copy.public java.lang.Integer getValue()
Property
public void setValue(int value)
AbstractProperty.isDefined()
will return true.value
- The new value.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 IntProperty copy()
Property