public void assign(ObjectModel objectModel, Object value) throws ExpressionException { this.compiledExpression.setValue(getContext(objectModel), value); }
@Override public void revertModifications(Object[] modifiedArguments, Object previousValue) { if (updatedArgumentIndex >= modifiedArguments.length) { throw new VariationRuntimeException("Failed to apply variaion \"" + getVariationID() + "\". Number of argument to modify is [" + updatedArgumentIndex + "] but arguments length is " + modifiedArguments.length); } JXPathContext context = JXPathContext.newContext(modifiedArguments[updatedArgumentIndex]); compiledExpression.setValue(context, previousValue); }
@Override public void revertModifications(Object[] modifiedArguments, Object previousValue) { if (updatedArgumentIndex >= modifiedArguments.length) { throw new VariationRuntimeException("Failed to apply variaion \"" + getVariationID() + "\". Number of argument to modify is [" + updatedArgumentIndex + "] but arguments length is " + modifiedArguments.length); } JXPathContext context = JXPathContext.newContext(modifiedArguments[updatedArgumentIndex]); compiledExpression.setValue(context, previousValue); }