ComputedField class

Package: com.tecit.TFORMer.Repository

Provides access to a ComputedField which is referenced by a DataSource.

Usage and notes

Overview

With the help of ComputedFields computations can be centralized in the DataSource instead of performing the computations in the FormLayout. For example, you might

  • convert the content of an existing field if the DataSource to uppercase,

  • remove leading and trailing spaces,

  • concatenate multiple fields of the DataSource into a single one,

  • or perform numerical computations like computing the VAT.

The result of a ComputedField is available in the DataSource like any other source-field. In the expression of a ComputedField you may refer to multiple fields of the DataSource. It is also possible to use other ComputedFields already defined in the DataSource in the expression.

Aggregation


In addition, ComputedFields support Aggregation (see ComputedField.setAggregation).
Thus it is pretty simple to create serial numbers or to calculate running sums and averages which are not available in a DataSource directly.

Filter Expressions

To exclude specific Records of a DataSource from being considered by the Aggregation use filter expressions.

Methods

MemberDescription
dispose()Returns: void

Releases the resources allocated by this instance.

dump(PrintStream)Returns: void

Dumps the current instance into a text stream.

getAggregation()Returns: Aggregation

Gets the aggregation-type of the ComputedField.

getComment()Returns: String

Gets the comment for the ComputedField.

getExpression()Returns: String

Gets the aggregation expression of the ComputedField.

getFilter()Returns: String

Gets the filter expression of the ComputedField.

getName()Returns: String

Gets the name of the ComputedField.

getNext()Returns: ComputedField

Gets the next ComputedField defined in the DataSource.

getOrder()Returns: long

Gets the evaluation order of the ComputedField.

setAggregation(Aggregation)Returns: void

Sets the aggregation-type of the ComputedField.

setComment(String)Returns: void

Sets the comment for the ComputedField.

setExpression(String)Returns: void

Sets the aggregation expression of the ComputedField.

setFilter(String)Returns: void

Sets the filter expression of the ComputedField.

setName(String)Returns: void

Sets the name of the ComputedField.

setOrder(long)Returns: void

Sets the evaluation order of the ComputedField.

toString()Returns: String

Returns a string representation of the instance.

Search documentation

Search in
More scopes
Additional scopes

All contents