@Test public void testLoadValuePairWithValueNotSet( ) { when( annotation.getValue( VALUE_PAIR_NAME ) ).thenReturn( null ); when( annotationSource.getValuePairSource( VALUE_PAIR_NAME ) ).thenReturn( VALUE_PAIR_SOURCE_CODE ); listItem.loadValuePair( annotation, valuePairDefinition, annotationSource ); verify( view, times( 1 ) ).setValuePairName( VALUE_PAIR_NAME ); verify( view, times( 1 ) ).setValuePairStringValue( Constants.INSTANCE.advanced_domain_annotation_list_editor_message_value_not_set( ) ); }
public void loadValuePair( final Annotation annotation, final AnnotationValuePairDefinition valuePairDefinition, final AnnotationSource annotationSource ) { this.annotation = annotation; this.valuePairDefinition = valuePairDefinition; view.setValuePairName( valuePairDefinition.getName( ) ); view.setValuePairStringValue( getValuePairStringValue( annotation, valuePairDefinition, annotationSource ) ); if ( valuePairDefinition.getDefaultValue( ) == null ) { view.showRequiredIndicator( true ); } }
AnnotationValuePairListItem implements AnnotationValuePairListItemView.Presenter, IsWidget { public void loadValuePair( final Annotation annotation, final AnnotationValuePairDefinition valuePairDefinition, final AnnotationSource annotationSource ) { this.annotation = annotation; this.valuePairDefinition = valuePairDefinition; view.setValuePairName( valuePairDefinition.getName( ) ); view.setValuePairStringValue( getValuePairStringValue( annotation, valuePairDefinition, annotationSource ) ); if ( valuePairDefinition.getDefaultValue( ) == null ) { view.showRequiredIndicator( true ); } } }
AnnotationValuePairListItem implements AnnotationValuePairListItemView.Presenter, IsWidget { public void loadValuePair( final Annotation annotation, final AnnotationValuePairDefinition valuePairDefinition, final AnnotationSource annotationSource ) { this.annotation = annotation; this.valuePairDefinition = valuePairDefinition; view.setValuePairName( valuePairDefinition.getName( ) ); view.setValuePairStringValue( getValuePairStringValue( annotation, valuePairDefinition, annotationSource ) ); if ( valuePairDefinition.getDefaultValue( ) == null ) { view.showRequiredIndicator( true ); } } AnnotationValuePairListItem( ); @Inject  AnnotationValuePairListItem( AnnotationValuePairListItemView view ); }
AnnotationValuePairListItem implements AnnotationValuePairListItemView.Presenter, IsWidget { public void loadValuePair( final Annotation annotation, final AnnotationValuePairDefinition valuePairDefinition, final AnnotationSource annotationSource ) { this.annotation = annotation; this.valuePairDefinition = valuePairDefinition; view.setValuePairName( valuePairDefinition.getName( ) ); view.setValuePairStringValue( getValuePairStringValue( annotation, valuePairDefinition, annotationSource ) ); if ( valuePairDefinition.getDefaultValue( ) == null ) { view.showRequiredIndicator( true ); } } AnnotationValuePairListItem( ); @Inject  AnnotationValuePairListItem( AnnotationValuePairListItemView view ); @Override Widget asWidget( ); void loadValuePair( final Annotation annotation,
                               final AnnotationValuePairDefinition valuePairDefinition,
                               final AnnotationSource annotationSource ); void setReadonly( boolean readonly ); void setClearValuePairHandler( AdvancedAnnotationListEditorView.ClearValuePairHandler clearValuePairHandler ); void setEditValuePairHandler( AdvancedAnnotationListEditorView.EditValuePairHandler editValuePairHandler ); @Override void onEdit( ); @Override void onClear( ); }
AnnotationValuePairListItem implements AnnotationValuePairListItemView.Presenter, IsWidget { public void loadValuePair( final Annotation annotation, final AnnotationValuePairDefinition valuePairDefinition, final AnnotationSource annotationSource ) { this.annotation = annotation; this.valuePairDefinition = valuePairDefinition; view.setValuePairName( valuePairDefinition.getName( ) ); view.setValuePairStringValue( getValuePairStringValue( annotation, valuePairDefinition, annotationSource ) ); if ( valuePairDefinition.getDefaultValue( ) == null ) { view.showRequiredIndicator( true ); } } AnnotationValuePairListItem( ); @Inject  AnnotationValuePairListItem( AnnotationValuePairListItemView view ); @Override Widget asWidget( ); void loadValuePair( final Annotation annotation,
                               final AnnotationValuePairDefinition valuePairDefinition,
                               final AnnotationSource annotationSource ); void setReadonly( boolean readonly ); void setClearValuePairHandler( AdvancedAnnotationListEditorView.ClearValuePairHandler clearValuePairHandler ); void setEditValuePairHandler( AdvancedAnnotationListEditorView.EditValuePairHandler editValuePairHandler ); @Override void onEdit( ); @Override void onClear( );  }