Package oracle.pgx.algorithm
Interface Reduction
-
public interface ReductionAn atomic reduction of one or more variables (argMinMax).
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description <T> ReductionandUpdate(PgxVertex vertex, VertexProperty<T> property, T value)If the reduction in the Reduction applies, also update the property the property specified here.<T1,T2>
ReductionandUpdate(T1 lhs, T2 rhs)If the reduction in the Reduction applies, also update the variable specified here.static <T> ReductionupdateMaxValue(PgxVertex vertex, VertexProperty<T> property, T value)Create an atomic reduction of a vertex property.static <T1,T2>
ReductionupdateMaxValue(T1 lhs, T2 rhs)Create an atomic reduction of a variable.static <T> ReductionupdateMinValue(PgxVertex vertex, VertexProperty<T> property, T value)Create an atomic reduction of a vertex property.static <T1,T2>
ReductionupdateMinValue(T1 lhs, T2 rhs)Create an atomic reduction of a variable.
-
-
-
Method Detail
-
updateMinValue
static <T> Reduction updateMinValue(PgxVertex vertex, VertexProperty<T> property, T value)
Create an atomic reduction of a vertex property. If the given value is less than the current value of the node property, then update the node property to the given value.- Type Parameters:
T-- Parameters:
vertex-property-value-- Returns:
-
updateMinValue
static <T1,T2> Reduction updateMinValue(T1 lhs, T2 rhs)
Create an atomic reduction of a variable. If the value on the rhs is less than the value on the lhs, then update the value on the lhs.- Type Parameters:
T1-T2-- Parameters:
lhs-rhs-- Returns:
-
updateMaxValue
static <T> Reduction updateMaxValue(PgxVertex vertex, VertexProperty<T> property, T value)
Create an atomic reduction of a vertex property. If the given value is greater than the current value of the node property, then update the node property to the given value.- Type Parameters:
T-- Parameters:
vertex-property-value-- Returns:
-
updateMaxValue
static <T1,T2> Reduction updateMaxValue(T1 lhs, T2 rhs)
Create an atomic reduction of a variable. If the value on the rhs is greater than the value on the lhs, then update the value on the lhs.- Type Parameters:
T1-T2-- Parameters:
lhs-rhs-- Returns:
-
andUpdate
<T> Reduction andUpdate(PgxVertex vertex, VertexProperty<T> property, T value)
If the reduction in the Reduction applies, also update the property the property specified here.- Type Parameters:
T-- Parameters:
vertex-property-value-- Returns:
-
andUpdate
<T1,T2> Reduction andUpdate(T1 lhs, T2 rhs)
If the reduction in the Reduction applies, also update the variable specified here.- Type Parameters:
T1-T2-- Parameters:
lhs-rhs-- Returns:
-
-