@Test public void testSetComponentSelector() { final String type = "type"; view.setComponentSelector(type); verify(startValueComponentSelector).makeSelectorForType(type); verify(startValueContainer, times(2)).appendChild(startValueElement); verify(endValueComponentSelector).makeSelectorForType(type); verify(endValueContainer, times(2)).appendChild(endValueElement); verify(view, times(2)).setupInputFields(); }
@Override public void setComponentSelector(final String type) { startValueComponent = this.startValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(startValueContainer); startValueContainer.appendChild(startValueComponent.getElement()); endValueComponent = this.endValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(endValueContainer); endValueContainer.appendChild(endValueComponent.getElement()); setupInputFields(); }
DataTypeConstraintRangeView implements DataTypeConstraintRange.View { @Override public void setComponentSelector(final String type) { startValueComponent = this.startValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(startValueContainer); startValueContainer.appendChild(startValueComponent.getElement()); endValueComponent = this.endValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(endValueContainer); endValueContainer.appendChild(endValueComponent.getElement()); setupInputFields(); } }
DataTypeConstraintRangeView implements DataTypeConstraintRange.View { @Override public void setComponentSelector(final String type) { startValueComponent = this.startValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(startValueContainer); startValueContainer.appendChild(startValueComponent.getElement()); endValueComponent = this.endValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(endValueContainer); endValueContainer.appendChild(endValueComponent.getElement()); setupInputFields(); } @Inject  DataTypeConstraintRangeView(final HTMLDivElement startValueContainer,
                                       final HTMLDivElement endValueContainer,
                                       final HTMLInputElement includeStartValue,
                                       final HTMLInputElement includeEndValue,
                                       final TypedValueComponentSelector startValueComponentSelector,
                                       final TypedValueComponentSelector endValueComponentSelector); }
DataTypeConstraintRangeView implements DataTypeConstraintRange.View { @Override public void setComponentSelector(final String type) { startValueComponent = this.startValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(startValueContainer); startValueContainer.appendChild(startValueComponent.getElement()); endValueComponent = this.endValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(endValueContainer); endValueContainer.appendChild(endValueComponent.getElement()); setupInputFields(); } @Inject  DataTypeConstraintRangeView(final HTMLDivElement startValueContainer,
                                       final HTMLDivElement endValueContainer,
                                       final HTMLInputElement includeStartValue,
                                       final HTMLInputElement includeEndValue,
                                       final TypedValueComponentSelector startValueComponentSelector,
                                       final TypedValueComponentSelector endValueComponentSelector); @Override void init(final DataTypeConstraintRange presenter); @Override String getStartValue(); @Override String getEndValue(); @Override void setStartValue(final String value); @Override void setEndValue(final String value); @Override boolean getIncludeStartValue(); @Override void setIncludeStartValue(boolean includeStartValue); @Override boolean getIncludeEndValue(); @Override void setIncludeEndValue(boolean includeEndValue); @Override void setPlaceholders(final String placeholder); @Override void setComponentSelector(final String type); }
DataTypeConstraintRangeView implements DataTypeConstraintRange.View { @Override public void setComponentSelector(final String type) { startValueComponent = this.startValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(startValueContainer); startValueContainer.appendChild(startValueComponent.getElement()); endValueComponent = this.endValueComponentSelector.makeSelectorForType(type); RemoveHelper.removeChildren(endValueContainer); endValueContainer.appendChild(endValueComponent.getElement()); setupInputFields(); } @Inject  DataTypeConstraintRangeView(final HTMLDivElement startValueContainer,
                                       final HTMLDivElement endValueContainer,
                                       final HTMLInputElement includeStartValue,
                                       final HTMLInputElement includeEndValue,
                                       final TypedValueComponentSelector startValueComponentSelector,
                                       final TypedValueComponentSelector endValueComponentSelector); @Override void init(final DataTypeConstraintRange presenter); @Override String getStartValue(); @Override String getEndValue(); @Override void setStartValue(final String value); @Override void setEndValue(final String value); @Override boolean getIncludeStartValue(); @Override void setIncludeStartValue(boolean includeStartValue); @Override boolean getIncludeEndValue(); @Override void setIncludeEndValue(boolean includeEndValue); @Override void setPlaceholders(final String placeholder); @Override void setComponentSelector(final String type);  }