@Test public void testGetValue() { final String dateValue = "dateValue"; final String timeValue = "timeValue"; when(dateSelector.getValue()).thenReturn(dateValue); when(timeSelector.getValue()).thenReturn(timeValue); final DateTimeValue actual = view.getValue(); assertEquals(dateValue, actual.getDate()); assertEquals(timeValue, actual.getTime()); }
@Override public DateTimeValue getValue() { final String dateValue = dateSelector.getValue(); final String timeValue = timeSelector.getValue(); final DateTimeValue dateTimeValue = new DateTimeValue(); dateTimeValue.setDate(dateValue); dateTimeValue.setTime(timeValue); return dateTimeValue; }
DateTimeSelectorView implements DateTimeSelector.View { @Override public DateTimeValue getValue() { final String dateValue = dateSelector.getValue(); final String timeValue = timeSelector.getValue(); final DateTimeValue dateTimeValue = new DateTimeValue(); dateTimeValue.setDate(dateValue); dateTimeValue.setTime(timeValue); return dateTimeValue; } }
DateTimeSelectorView implements DateTimeSelector.View { @Override public DateTimeValue getValue() { final String dateValue = dateSelector.getValue(); final String timeValue = timeSelector.getValue(); final DateTimeValue dateTimeValue = new DateTimeValue(); dateTimeValue.setDate(dateValue); dateTimeValue.setTime(timeValue); return dateTimeValue; } @Inject  DateTimeSelectorView(final HTMLDivElement dateSelectorContainer,
                                final HTMLDivElement timeSelectorContainer,
                                final DateSelector dateSelector,
                                final TimeSelector timeSelector,
                                final ConstraintPlaceholderHelper placeholderHelper); }
DateTimeSelectorView implements DateTimeSelector.View { @Override public DateTimeValue getValue() { final String dateValue = dateSelector.getValue(); final String timeValue = timeSelector.getValue(); final DateTimeValue dateTimeValue = new DateTimeValue(); dateTimeValue.setDate(dateValue); dateTimeValue.setTime(timeValue); return dateTimeValue; } @Inject  DateTimeSelectorView(final HTMLDivElement dateSelectorContainer,
                                final HTMLDivElement timeSelectorContainer,
                                final DateSelector dateSelector,
                                final TimeSelector timeSelector,
                                final ConstraintPlaceholderHelper placeholderHelper); @Override DateTimeValue getValue(); @Override void setValue(final DateTimeValue value); @Override void setOnValueChanged(final Consumer<Event> onValueChanged); @Override void setOnValueInputBlur(final Consumer<BlurEvent> blurEvent); @Override void select(); @Override void init(final DateTimeSelector presenter); }
DateTimeSelectorView implements DateTimeSelector.View { @Override public DateTimeValue getValue() { final String dateValue = dateSelector.getValue(); final String timeValue = timeSelector.getValue(); final DateTimeValue dateTimeValue = new DateTimeValue(); dateTimeValue.setDate(dateValue); dateTimeValue.setTime(timeValue); return dateTimeValue; } @Inject  DateTimeSelectorView(final HTMLDivElement dateSelectorContainer,
                                final HTMLDivElement timeSelectorContainer,
                                final DateSelector dateSelector,
                                final TimeSelector timeSelector,
                                final ConstraintPlaceholderHelper placeholderHelper); @Override DateTimeValue getValue(); @Override void setValue(final DateTimeValue value); @Override void setOnValueChanged(final Consumer<Event> onValueChanged); @Override void setOnValueInputBlur(final Consumer<BlurEvent> blurEvent); @Override void select(); @Override void init(final DateTimeSelector presenter);  }