Class PropertyFile.Entry
- java.lang.Object
- 
- org.apache.tools.ant.taskdefs.optional.PropertyFile.Entry
 
- 
- Enclosing class:
- PropertyFile
 
 public static class PropertyFile.Entry extends java.lang.ObjectInstance of this class represents nested elements of a task propertyfile.
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classPropertyFile.Entry.OperationEnumerated attribute with the values "+", "-", "="static classPropertyFile.Entry.TypeEnumerated attribute with the values "int", "date" and "string".
 - 
Constructor SummaryConstructors Constructor Description Entry()
 - 
Method SummaryModifier and Type Method Description protected voidexecuteOn(java.util.Properties props)Apply the nested element to the properties.voidsetDefault(java.lang.String value)Initial value to set for a property if it is not already defined in the property file.voidsetKey(java.lang.String value)Name of the property name/value pairvoidsetOperation(PropertyFile.Entry.Operation value)operation to apply.voidsetPattern(java.lang.String value)For int and date type only.voidsetType(PropertyFile.Entry.Type value)Regard the value as : int, date or string (default)voidsetUnit(PropertyFile.Unit unit)The unit of the value to be applied to date +/- operations.voidsetValue(java.lang.String value)Value to set (=), to add (+) or subtract (-)
 
- 
- 
- 
Method Detail- 
setKeypublic void setKey(java.lang.String value) Name of the property name/value pair- Parameters:
- value- the key.
 
 - 
setValuepublic void setValue(java.lang.String value) Value to set (=), to add (+) or subtract (-)- Parameters:
- value- the value.
 
 - 
setOperationpublic void setOperation(PropertyFile.Entry.Operation value) operation to apply. "+" or "=" (default) for all datatypes; "-" for date and int only)\.- Parameters:
- value- the operation enumerated value.
 
 - 
setTypepublic void setType(PropertyFile.Entry.Type value) Regard the value as : int, date or string (default)- Parameters:
- value- the type enumerated value.
 
 - 
setDefaultpublic void setDefault(java.lang.String value) Initial value to set for a property if it is not already defined in the property file. For type date, an additional keyword is allowed: "now"- Parameters:
- value- the default value.
 
 - 
setPatternpublic void setPattern(java.lang.String value) For int and date type only. If present, Values will be parsed and formatted accordingly.- Parameters:
- value- the pattern to use.
 
 - 
setUnitpublic void setUnit(PropertyFile.Unit unit) The unit of the value to be applied to date +/- operations. Valid Values are:- millisecond
- second
- minute
- hour
- day (default)
- week
- month
- year
 - Parameters:
- unit- the unit enumerated value.
- Since:
- Ant 1.5
 
 - 
executeOnprotected void executeOn(java.util.Properties props) throws BuildExceptionApply the nested element to the properties.- Parameters:
- props- the properties to apply the entry on.
- Throws:
- BuildException- if there is an error.
 
 
- 
 
-