public class PropertyImpl extends Object implements Property
| Constructor and Description |
|---|
PropertyImpl(String name,
Date value) |
PropertyImpl(String name,
String value) |
PropertyImpl(String name,
ValueType type,
Object value) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
checkType(ValueType type) |
Date |
getDate()
Gets value as Date.
|
String |
getName()
Gets name of the property.
|
String |
getString()
Gets value as String.
|
ValueType |
getType()
Gets type of value for the property.
|
Object |
getValue()
Gets value of the property as Object.
|
void |
setValue(Date value)
Sets value of the property.
|
void |
setValue(String value)
Sets value of the property.
|
protected void checkType(ValueType type) throws PropertyException
PropertyExceptionpublic Date getDate() throws PropertyException
getDate in interface PropertyPropertyException - if property cannot be transformed into Datepublic String getName()
public String getString()
public ValueType getType()
public Object getValue()
public void setValue(Date value) throws PropertyException
setValue in interface Propertyvalue - date valuePropertyException - if failed to set new valuepublic void setValue(String value) throws PropertyException
setValue in interface Propertyvalue - string valuePropertyException - if failed to set new valueCopyright © 2018. All rights reserved.