org.pentaho.reporting.engine.classic.core.function.date
Class DateSpanExpression

java.lang.Object
  extended by org.pentaho.reporting.engine.classic.core.function.AbstractExpression
      extended by org.pentaho.reporting.engine.classic.core.function.date.DateSpanExpression
All Implemented Interfaces:
Serializable, Cloneable, Expression

Deprecated. This can be solved using a plain formula.

public class DateSpanExpression
extends AbstractExpression

Computes the difference date between the start and the end date.

Author:
Thomas Morgner
See Also:
Serialized Form

Constructor Summary
DateSpanExpression()
          Deprecated. Default Constructor.
 
Method Summary
 String getEndDateField()
          Deprecated. Returns the name of the field that contains the end-date.
 String getStartDateField()
          Deprecated. Returns the name of the field that contains the start-date.
 Object getValue()
          Deprecated. Computes the difference between the start and the end date.
 void setEndDateField(String endDateField)
          Deprecated. Defines the name of the field that contains the end-date.
 void setStartDateField(String startDateField)
          Deprecated. Defines the name of the field that contains the start-date.
 
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
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DateSpanExpression

public DateSpanExpression()
Deprecated. 
Default Constructor.

Method Detail

getStartDateField

public String getStartDateField()
Deprecated. 
Returns the name of the field that contains the start-date.

Returns:
the start-date fieldname

setStartDateField

public void setStartDateField(String startDateField)
Deprecated. 
Defines the name of the field that contains the start-date.

Parameters:
startDateField - the start-date fieldname

getEndDateField

public String getEndDateField()
Deprecated. 
Returns the name of the field that contains the end-date.

Returns:
the end-date fieldname

setEndDateField

public void setEndDateField(String endDateField)
Deprecated. 
Defines the name of the field that contains the end-date.

Parameters:
endDateField - the start-date fieldname

getValue

public Object getValue()
Deprecated. 
Computes the difference between the start and the end date. The start-field and end-field must contain either Date objects or Number objects. If the fields contain number objects, the number will be interpreted as milliseconds since 01-Jan-1970.

Returns:
the difference between start and end or null, if the difference could not be computed.