DefaultStellarStatefulExecutor implements StellarStatefulExecutor, Serializable { @Override public void assign(String variable, String expression, Map<String, Object> transientState) { Object result = execute(expression, transientState); if(result == null || variable == null) { return; } state.put(variable, result); } DefaultStellarStatefulExecutor();  DefaultStellarStatefulExecutor(FunctionResolver functionResolver, Context context);  DefaultStellarStatefulExecutor(Map<String, Object> initialState); @Override Map<String, Object> getState(); @Override void assign(String variable, String expression, Map<String, Object> transientState); @Override void assign(String variable, Object value); @Override T execute(String expression, Map<String, Object> state, Class<T> clazz); @Override void clearState(); @Override void setContext(Context context); void setFunctionResolver(FunctionResolver functionResolver);  }
@Test public void testAssign() { executor.assign("foo", "2", message); Object var = executor.getState().get("foo"); assertThat(var, instanceOf(Integer.class)); assertThat(var, equalTo(2)); }