test_class.declarator: timeInstantView
test_class.modifier: @Mock
test_class.original_string: @Mock
      TimeInstantEditor.View timeInstantView;
test_class.type: TimeInstantEditor.View
test_class.var_name: timeInstantView
test_class.declarator: timeAmountEditor
test_class.modifier: @Mock
test_class.original_string: @Mock
      TimeAmountEditor timeAmountEditor;
test_class.type: TimeAmountEditor
test_class.var_name: timeAmountEditor
test_class.declarator: changeCommand
test_class.modifier: @Mock
test_class.original_string: @Mock
      Command changeCommand;
test_class.type: Command
test_class.var_name: changeCommand
test_class.file: dashbuilder-client/dashbuilder-displayer-client/src/test/java/org/dashbuilder/displayer/client/widgets/filter/TimeInstantEditorTest.java
test_class.identifier: TimeInstantEditorTest
test_case.body: @Test
      public void testViewInitialization() {
          TimeInstant beginMonth = new TimeInstant(TimeInstant.TimeMode.BEGIN, DateIntervalType.MONTH, Month.JANUARY, new TimeAmount(10, DateIntervalType.DAY));
          TimeInstantEditor timeInstantEditor = new TimeInstantEditor(timeInstantView, timeAmountEditor);
          timeInstantEditor.init(beginMonth, changeCommand);
  
          assertEquals(timeInstantView, timeInstantEditor.view);
          verify(timeInstantView).init(timeInstantEditor);
          verify(timeInstantView).clearTimeModeSelector();
          verify(timeInstantView, times(TimeInstant.TimeMode.values().length)).addTimeModeItem(any(TimeInstant.TimeMode.class));
          verify(timeInstantView).setSelectedTimeModeIndex(TimeInstant.TimeMode.BEGIN.getIndex());
  
          verify(timeInstantView).enableIntervalTypeSelector();
          verify(timeInstantView).clearIntervalTypeSelector();
          verify(timeInstantView, times(TimeInstantEditor.INTERVAL_TYPES.size())).addIntervalTypeItem(any(DateIntervalType.class));
          verify(timeInstantView).setSelectedIntervalTypeIndex(3);
      }
test_case.class_method_signature: TimeInstantEditorTest.testViewInitialization()
test_case.full_signature: @Test public void testViewInitialization()
test_case.identifier: testViewInitialization
test_case.invocations: init assertEquals init verify clearTimeModeSelector verify addTimeModeItem verify times values any setSelectedTimeModeIndex verify getIndex enableIntervalTypeSelector verify clearIntervalTypeSelector verify addIntervalTypeItem verify times size any setSelectedIntervalTypeIndex verify
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testViewInitialization()
focal_class.declarator: INTERVAL_TYPES = Arrays.asList(
              DateIntervalType.MINUTE,
              DateIntervalType.HOUR,
              DateIntervalType.DAY,
              DateIntervalType.MONTH,
              DateIntervalType.QUARTER,
              DateIntervalType.YEAR,
              DateIntervalType.CENTURY,
              DateIntervalType.MILLENIUM)
focal_class.modifier: static
focal_class.original_string: static List<DateIntervalType> INTERVAL_TYPES = Arrays.asList(
              DateIntervalType.MINUTE,
              DateIntervalType.HOUR,
              DateIntervalType.DAY,
              DateIntervalType.MONTH,
              DateIntervalType.QUARTER,
              DateIntervalType.YEAR,
              DateIntervalType.CENTURY,
              DateIntervalType.MILLENIUM);
focal_class.type: List<DateIntervalType>
focal_class.var_name: INTERVAL_TYPES
focal_class.declarator: view
focal_class.original_string: View view;
focal_class.type: View
focal_class.var_name: view
focal_class.declarator: timeInstant = null
focal_class.original_string: TimeInstant timeInstant = null;
focal_class.type: TimeInstant
focal_class.var_name: timeInstant
focal_class.declarator: timeAmountEditor = null
focal_class.original_string: TimeAmountEditor timeAmountEditor = null;
focal_class.type: TimeAmountEditor
focal_class.var_name: timeAmountEditor
focal_class.declarator: onChangeCommand = new Command() { public void execute() {} }
focal_class.original_string: Command onChangeCommand = new Command() { public void execute() {} };
focal_class.type: Command
focal_class.var_name: onChangeCommand
focal_class.file: dashbuilder-client/dashbuilder-displayer-client/src/main/java/org/dashbuilder/displayer/client/widgets/filter/TimeInstantEditor.java
focal_class.identifier: TimeInstantEditor
focal_class.interfaces: implements IsWidget
focal_class.class_method_signature: TimeInstantEditor.TimeInstantEditor(View view, TimeAmountEditor timeAmountEditor)
focal_class.full_signature: @Inject public  TimeInstantEditor(View view, TimeAmountEditor timeAmountEditor)
focal_class.identifier: TimeInstantEditor
focal_class.modifiers: @Inject public
focal_class.parameters: (View view, TimeAmountEditor timeAmountEditor)
focal_class.signature:  TimeInstantEditor(View view, TimeAmountEditor timeAmountEditor)
focal_class.class_method_signature: TimeInstantEditor.asWidget()
focal_class.full_signature: @Override public Widget asWidget()
focal_class.identifier: asWidget
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Widget
focal_class.signature: Widget asWidget()
focal_class.class_method_signature: TimeInstantEditor.getTimeInstant()
focal_class.full_signature: public TimeInstant getTimeInstant()
focal_class.identifier: getTimeInstant
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: TimeInstant
focal_class.signature: TimeInstant getTimeInstant()
focal_class.class_method_signature: TimeInstantEditor.init(final TimeInstant ti, final Command onChangeCommand)
focal_class.full_signature: public void init(final TimeInstant ti, final Command onChangeCommand)
focal_class.identifier: init
focal_class.modifiers: public
focal_class.parameters: (final TimeInstant ti, final Command onChangeCommand)
focal_class.return: void
focal_class.signature: void init(final TimeInstant ti, final Command onChangeCommand)
focal_class.class_method_signature: TimeInstantEditor.getTimeAmountEditor()
focal_class.full_signature: public TimeAmountEditor getTimeAmountEditor()
focal_class.identifier: getTimeAmountEditor
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: TimeAmountEditor
focal_class.signature: TimeAmountEditor getTimeAmountEditor()
focal_class.class_method_signature: TimeInstantEditor.initTimeModeSelector()
focal_class.full_signature: protected void initTimeModeSelector()
focal_class.identifier: initTimeModeSelector
focal_class.modifiers: protected
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void initTimeModeSelector()
focal_class.class_method_signature: TimeInstantEditor.initIntervalTypeSelector()
focal_class.full_signature: protected void initIntervalTypeSelector()
focal_class.identifier: initIntervalTypeSelector
focal_class.modifiers: protected
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void initIntervalTypeSelector()
focal_class.class_method_signature: TimeInstantEditor.changeTimeMode()
focal_class.full_signature:  void changeTimeMode()
focal_class.identifier: changeTimeMode
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void changeTimeMode()
focal_class.class_method_signature: TimeInstantEditor.changeIntervalType()
focal_class.full_signature:  void changeIntervalType()
focal_class.identifier: changeIntervalType
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void changeIntervalType()
focal_method.body: public void init(final TimeInstant ti, final Command onChangeCommand) {
          this.timeInstant = ti != null ? ti : new TimeInstant();
          this.onChangeCommand = onChangeCommand;
          this.timeAmountEditor.init(timeInstant.getTimeAmount(), new Command() {
              public void execute() {
                  timeInstant.setTimeAmount(timeAmountEditor.getTimeAmount());
                  onChangeCommand.execute();
              }
          });
          initTimeModeSelector();
          initIntervalTypeSelector();
      }
focal_method.class_method_signature: TimeInstantEditor.init(final TimeInstant ti, final Command onChangeCommand)
focal_method.full_signature: public void init(final TimeInstant ti, final Command onChangeCommand)
focal_method.identifier: init
focal_method.invocations: init getTimeAmount setTimeAmount getTimeAmount execute initTimeModeSelector initIntervalTypeSelector
focal_method.modifiers: public
focal_method.parameters: (final TimeInstant ti, final Command onChangeCommand)
focal_method.return: void
focal_method.signature: void init(final TimeInstant ti, final Command onChangeCommand)