DiscreteFieldFunction class final

A function that returns a DiscreteField when evaluated.

Use DiscreteFieldFunction.evaluate to compute the result of this function.

Results are updated when changes are made to parameters of this function (or to parameters of functions from which it is composed).

Operator overloads are available via DiscreteFieldOperators to combine fields and values using *, +, -, /, and unary -.

Values are represented as 32-bit signed integers, so arithmetic operations will wrap at the boundaries of this type.

Implemented types
Available extensions

Constructors

DiscreteFieldFunction.create(DiscreteField result)
Creates a DiscreteFieldFunction with a predefined result.
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

abs() DiscreteFieldFunction
Composes a function that returns the absolute value of this function's field result across its extent.
addOtherField(DiscreteFieldFunction otherField) DiscreteFieldFunction
Composes a function that adds, point-wise, this function's field result and another across their spatial intersection.
addValue(int value) DiscreteFieldFunction
Composes a function that adds, point-wise, a value to this function's field result across its extent.
clip(Envelope extent) DiscreteFieldFunction
Composes a function that clips this function's field result such that it does not extend beyond the provided extent.
divideByOtherField(DiscreteFieldFunction otherField) DiscreteFieldFunction
Composes a function that divides, point-wise, this function's field result by another across their spatial intersection.
divideByValue(int value) DiscreteFieldFunction
Composes a function that divides, point-wise, this function's field result by a value across its extent.
evaluate() Future<DiscreteField>
Evaluates the result of the function.
hasData() BooleanFieldFunction
Composes a function that identifies, point-wise, where this function's field result has data across its extent.
isEqualToOtherField(DiscreteFieldFunction otherField) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is equal to another.
isEqualToValue(int value) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is equal to a given value.
isGreaterThanOrEqualToOtherField(DiscreteFieldFunction otherField) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is greater than or equal to another.
isGreaterThanOrEqualToValue(int value) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is greater than or equal to a given value.
isGreaterThanOtherField(DiscreteFieldFunction otherField) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is greater than another.
isGreaterThanValue(int value) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is greater than a given value.
isLessThanOrEqualToOtherField(DiscreteFieldFunction otherField) BooleanFieldFunction
Compose a function that indicates if, point-wise, this function's field result is less than or equal to another.
isLessThanOrEqualToValue(int value) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is less than or equal to a given value.
isLessThanOtherField(DiscreteFieldFunction otherField) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is less than another.
isLessThanValue(int value) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is less than a given value.
isNotEqualToOtherField(DiscreteFieldFunction otherField) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is not equal to another.
isNotEqualToValue(int value) BooleanFieldFunction
Composes a function that indicates if, point-wise, this function's field result is not equal to a given value.
mask(BooleanFieldFunction selection) DiscreteFieldFunction
Composes a function that applies a mask to this function's field result.
multiplyByOtherField(DiscreteFieldFunction otherField) DiscreteFieldFunction
Composes a function that multiplies, point-wise, this function's field result and another across their spatial intersection.
multiplyByValue(int value) DiscreteFieldFunction
Composes a function that multiplies, point-wise, this function's field result by a value across its extent.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
replaceWithOtherFieldIf({required BooleanFieldFunction selection, required DiscreteFieldFunction otherField}) DiscreteFieldFunction
Composes a function that preserves values from this function's field result or replaces them with values from another.
replaceWithValueIf({required BooleanFieldFunction selection, required int value}) DiscreteFieldFunction
Composes a function that preserves values from this function's field result or replaces them with a constant value.
subtractOtherField(DiscreteFieldFunction otherField) DiscreteFieldFunction
Composes a function that subtracts, point-wise, another field from this function's field result across their spatial intersection.
subtractValue(int value) DiscreteFieldFunction
Composes a function that subtracts, point-wise, a value from this function's field result across its extent.
toContinuousFieldFunction() ContinuousFieldFunction
Composes a function that casts, point-wise, integer values from this function's field result to floating-point values across its extent.
toString() String
A string representation of this object.
inherited

Operators

operator *(Object other) DiscreteFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that multiplies, point-wise, this function's result by other, using DiscreteFieldFunction.multiplyByValue or DiscreteFieldFunction.multiplyByOtherField.
operator +(Object other) DiscreteFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that adds, point-wise, other to this function's result, using DiscreteFieldFunction.addValue or DiscreteFieldFunction.addOtherField.
operator -(Object other) DiscreteFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that subtracts, point-wise, other from this function's result, using DiscreteFieldFunction.subtractValue or DiscreteFieldFunction.subtractOtherField.
operator /(Object other) DiscreteFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that divides, point-wise, this function's result by other, using DiscreteFieldFunction.divideByValue or DiscreteFieldFunction.divideByOtherField.
operator <(Object other) BooleanFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that compares, point-wise, this function's result to other, using DiscreteFieldFunction.isLessThanValue or DiscreteFieldFunction.isLessThanOtherField.
operator <=(Object other) BooleanFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that compares, point-wise, this function's result to other, using DiscreteFieldFunction.isLessThanOrEqualToValue or DiscreteFieldFunction.isLessThanOrEqualToOtherField.
operator ==(Object other) bool
The equality operator.
inherited
operator >(Object other) BooleanFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that compares, point-wise, this function's result to other, using DiscreteFieldFunction.isGreaterThanValue or DiscreteFieldFunction.isGreaterThanOtherField.
operator >=(Object other) BooleanFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that compares, point-wise, this function's result to other, using DiscreteFieldFunction.isGreaterThanOrEqualToValue or DiscreteFieldFunction.isGreaterThanOrEqualToOtherField.
operator unary-() DiscreteFieldFunction

Available on DiscreteFieldFunction, provided by the DiscreteFieldOperators extension

Composes a function that multiplies, point-wise, this function's result by -1.