Class DateCutExpression
- java.lang.Object
-
- org.pentaho.reporting.engine.classic.core.function.AbstractExpression
-
- org.pentaho.reporting.engine.classic.core.function.DateCutExpression
-
- All Implemented Interfaces:
Serializable
,Cloneable
,Expression
public class DateCutExpression extends AbstractExpression
Deprecated.The VariableDateExpression is much better suited for this purpose.Prunes a date in a calendar-unware way. This method can be used to zero the milli-seconds or seconds and so on from a date-object. For more complex operations, the.VariableDateExpression
should be used instead. This expression simply executes a integer division followed by a integer multiplication on the milliseconds since 01-01-1970. For a factor of 1000, this sets the milliseconds to zero.- Author:
- Martin Schmid
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description DateCutExpression()
Deprecated.Default Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description long
getFactor()
Deprecated.Returns the factor by which the date should be pruned.String
getField()
Deprecated.Returns the name of the data-row field from where to read the date that should be modified.Object
getValue()
Deprecated.Computes the pruned date.void
setFactor(long factor)
Deprecated.Defines the factor by which the date should be pruned.void
setField(String field)
Deprecated.Defines the name of the data-row field from where to read the date that should be modified.-
Methods inherited from class org.pentaho.reporting.engine.classic.core.function.AbstractExpression
clone, getDataRow, getDependencyLevel, getInstance, getName, getReportConfiguration, getResourceBundleFactory, getRuntime, isActive, isDeepTraversing, isPreserve, setActive, setDependencyLevel, setName, setPreserve, setRuntime
-
-
-
-
Method Detail
-
getField
public String getField()
Deprecated.Returns the name of the data-row field from where to read the date that should be modified.- Returns:
- a field name.
-
setField
public void setField(String field)
Deprecated.Defines the name of the data-row field from where to read the date that should be modified.- Parameters:
field
- a field name.
-
getFactor
public long getFactor()
Deprecated.Returns the factor by which the date should be pruned.- Returns:
- a factor.
-
setFactor
public void setFactor(long factor)
Deprecated.Defines the factor by which the date should be pruned.- Parameters:
factor
- a factor.
-
getValue
public Object getValue()
Deprecated.Computes the pruned date.- Returns:
- the value of the function.
-
-