@Test public void testNotifyChange() { testHandlerModelSetup(); final String name = "Bart"; formHandler.notifyFieldChange(USER_NAME_FIELD_NAME, name); verify(fieldChangeHandlerManager).notifyFieldChange(eq(USER_NAME_FIELD_NAME), eq(name)); verify(userName).onFieldChange(eq(USER_NAME_FIELD_NAME), eq(name)); }
protected void notifyFieldChange(String fieldName, Object newValue) { fieldChangeManager.notifyFieldChange(fieldName, newValue); }
FormHandlerImpl implements FormHandler<T> { protected void notifyFieldChange(String fieldName, Object newValue) { fieldChangeManager.notifyFieldChange(fieldName, newValue); } }
FormHandlerImpl implements FormHandler<T> { protected void notifyFieldChange(String fieldName, Object newValue) { fieldChangeManager.notifyFieldChange(fieldName, newValue); } @Inject  FormHandlerImpl(FormValidator validator,
                           FieldChangeHandlerManager fieldChangeManager); }
FormHandlerImpl implements FormHandler<T> { protected void notifyFieldChange(String fieldName, Object newValue) { fieldChangeManager.notifyFieldChange(fieldName, newValue); } @Inject  FormHandlerImpl(FormValidator validator,
                           FieldChangeHandlerManager fieldChangeManager); @Override void setUp(T model); @Override void registerInput(FormField formField); @Override void registerInput(FormField formField,
                              Converter valueConverter); void addFieldChangeHandler(FieldChangeHandler handler); void addFieldChangeHandler(String fieldName,
                                      FieldChangeHandler handler); @Override boolean validate(); @Override boolean validate(String propertyName); @Override void setReadOnly(boolean readOnly); @Override Form getForm(); @Override void clear(); @Override void maybeFlush(); T getModel(); }
FormHandlerImpl implements FormHandler<T> { protected void notifyFieldChange(String fieldName, Object newValue) { fieldChangeManager.notifyFieldChange(fieldName, newValue); } @Inject  FormHandlerImpl(FormValidator validator,
                           FieldChangeHandlerManager fieldChangeManager); @Override void setUp(T model); @Override void registerInput(FormField formField); @Override void registerInput(FormField formField,
                              Converter valueConverter); void addFieldChangeHandler(FieldChangeHandler handler); void addFieldChangeHandler(String fieldName,
                                      FieldChangeHandler handler); @Override boolean validate(); @Override boolean validate(String propertyName); @Override void setReadOnly(boolean readOnly); @Override Form getForm(); @Override void clear(); @Override void maybeFlush(); T getModel();  }