public class ComputedValue extends Object
Modifier and Type | Class and Description |
---|---|
static class |
ComputedValue.ComputeOn |
Constructor and Description |
---|
ComputedValue() |
Modifier and Type | Method and Description |
---|---|
ComputedValue |
computeOn(ComputedValue.ComputeOn... computeOn) |
boolean |
equals(Object o) |
ComputedValue |
expression(String expression) |
ComputedValue |
failOnWarning(Boolean failOnWarning) |
int |
hashCode() |
ComputedValue |
keepNull(Boolean keepNull) |
ComputedValue |
name(String name) |
ComputedValue |
overwrite(Boolean overwrite) |
public ComputedValue name(String name)
name
- (required) The name of the target attribute. Can only be a top-level attribute, but you may return
a nested object. Cannot be _key, _id, _rev, _from, _to, or a shard key attribute.public ComputedValue expression(String expression)
expression
- (required) An AQL RETURN operation with an expression that computes the desired value. See
Computed Value Expressions
for details.public ComputedValue overwrite(Boolean overwrite)
overwrite
- (required) Whether the computed value shall take precedence over a user-provided or existing
attribute.public ComputedValue computeOn(ComputedValue.ComputeOn... computeOn)
computeOn
- (optional) An array of operations to define on which write operations the value shall be
computed. The default is ["insert", "update", "replace"].public ComputedValue keepNull(Boolean keepNull)
keepNull
- (optional) Whether the target attribute shall be set if the expression evaluates to null. You
can set the option to false to not set (or unset) the target attribute if the expression
returns null. The default is true.public ComputedValue failOnWarning(Boolean failOnWarning)
failOnWarning
- (optional) Whether to let the write operation fail if the expression produces a warning.
The default is false.Copyright © 2016–2023 ArangoDB GmbH. All rights reserved.