@Test public void testEditorLoad() { EnumValuePairEditor enumEditor = new EnumValuePairEditor( view ); AnnotationValuePairDefinition valuePairDefinition = annotationDefinition.getValuePair( "enumParam1" ); enumEditor.init( valuePairDefinition ); verify( view, times( 1 ) ).initOptions( enumOptions ); verify( view, times( 1 ) ).setValuePairLabel( valuePairDefinition.getName() ); verify( view, times( 1 ) ).showValuePairRequiredIndicator( false ); }
@Override public void init( AnnotationValuePairDefinition valuePairDefinition ) { this.valuePairDefinition = valuePairDefinition; view.initOptions( createOptionsList( valuePairDefinition.enumValues() ) ); view.setValuePairLabel( ValuePairEditorUtil.buildValuePairLabel( valuePairDefinition ) ); view.showValuePairRequiredIndicator( !valuePairDefinition.hasDefaultValue() ); }
EnumValuePairEditor implements EnumValuePairEditorView.Presenter,
        ValuePairEditor<String> { @Override public void init( AnnotationValuePairDefinition valuePairDefinition ) { this.valuePairDefinition = valuePairDefinition; view.initOptions( createOptionsList( valuePairDefinition.enumValues() ) ); view.setValuePairLabel( ValuePairEditorUtil.buildValuePairLabel( valuePairDefinition ) ); view.showValuePairRequiredIndicator( !valuePairDefinition.hasDefaultValue() ); } }
EnumValuePairEditor implements EnumValuePairEditorView.Presenter,
        ValuePairEditor<String> { @Override public void init( AnnotationValuePairDefinition valuePairDefinition ) { this.valuePairDefinition = valuePairDefinition; view.initOptions( createOptionsList( valuePairDefinition.enumValues() ) ); view.setValuePairLabel( ValuePairEditorUtil.buildValuePairLabel( valuePairDefinition ) ); view.showValuePairRequiredIndicator( !valuePairDefinition.hasDefaultValue() ); } EnumValuePairEditor();  EnumValuePairEditor( EnumValuePairEditorView view ); }
EnumValuePairEditor implements EnumValuePairEditorView.Presenter,
        ValuePairEditor<String> { @Override public void init( AnnotationValuePairDefinition valuePairDefinition ) { this.valuePairDefinition = valuePairDefinition; view.initOptions( createOptionsList( valuePairDefinition.enumValues() ) ); view.setValuePairLabel( ValuePairEditorUtil.buildValuePairLabel( valuePairDefinition ) ); view.showValuePairRequiredIndicator( !valuePairDefinition.hasDefaultValue() ); } EnumValuePairEditor();  EnumValuePairEditor( EnumValuePairEditorView view ); @Override Widget asWidget(); @Override void init( AnnotationValuePairDefinition valuePairDefinition ); @Override void setValue( String value ); String getValue( ); @Override boolean isValid(); @Override void clear(); @Override void addEditorHandler( ValuePairEditorHandler editorHandler ); @Override AnnotationValuePairDefinition getValuePairDefinition(); @Override void setErrorMessage( String errorMessage ); @Override void clearErrorMessage(); @Override void showValidateButton( boolean show ); @Override void showValuePairName( boolean show ); @Override void refresh(); @Override void onValueChange(); }
EnumValuePairEditor implements EnumValuePairEditorView.Presenter,
        ValuePairEditor<String> { @Override public void init( AnnotationValuePairDefinition valuePairDefinition ) { this.valuePairDefinition = valuePairDefinition; view.initOptions( createOptionsList( valuePairDefinition.enumValues() ) ); view.setValuePairLabel( ValuePairEditorUtil.buildValuePairLabel( valuePairDefinition ) ); view.showValuePairRequiredIndicator( !valuePairDefinition.hasDefaultValue() ); } EnumValuePairEditor();  EnumValuePairEditor( EnumValuePairEditorView view ); @Override Widget asWidget(); @Override void init( AnnotationValuePairDefinition valuePairDefinition ); @Override void setValue( String value ); String getValue( ); @Override boolean isValid(); @Override void clear(); @Override void addEditorHandler( ValuePairEditorHandler editorHandler ); @Override AnnotationValuePairDefinition getValuePairDefinition(); @Override void setErrorMessage( String errorMessage ); @Override void clearErrorMessage(); @Override void showValidateButton( boolean show ); @Override void showValuePairName( boolean show ); @Override void refresh(); @Override void onValueChange();  }