Package org.eclipse.emf.common.notify

Examples of org.eclipse.emf.common.notify.Notification


          }
        }
        Adapter adapter = oldObject;
        if (eDeliver())
        {
          Notification notification =
            new NotificationImpl(Notification.REMOVING_ADAPTER, oldObject, null, index)
            {
              @Override
              public Object getNotifier()
              {
View Full Code Here


  /*
   * Javadoc copied from interface.
   */
  public synchronized void load(Map options) throws IOException {
    if (!isLoaded) {
      Notification notification = setLoaded(true);
      isLoading = true;

      if (errors != null) {
        errors.clear();
      }
View Full Code Here

    assertEquals(item2, itemCaptor.getValue());
    assertEquals(treeCell, cellCaptor.getValue());
    assertEquals(adapterFactory, adapterFactoryCaptor.getValue());

    // notify the adapter
    Notification notification = mock(Notification.class);
    when(notification.getNotifier()).thenReturn(item2);
    adapter2.notifyChanged(notification);

    verify(cellFactory, times(3)).applyItemProviderStyle(itemCaptor.capture(), cellCaptor.capture(), adapterFactoryCaptor.capture());
    assertEquals(item2, itemCaptor.getValue());
    assertEquals(treeCell, cellCaptor.getValue());
View Full Code Here

    assertEquals(item2, itemCaptor.getValue());
    assertEquals(listCell, cellCaptor.getValue());
    assertEquals(adapterFactory, adapterFactoryCaptor.getValue());

    // notify the adapter
    Notification notification = mock(Notification.class);
    when(notification.getNotifier()).thenReturn(item2);
    adapter2.notifyChanged(notification);

    verify(cellFactory, times(3)).applyItemProviderStyle(itemCaptor.capture(), cellCaptor.capture(), adapterFactoryCaptor.capture());
    assertEquals(item2, itemCaptor.getValue());
    assertEquals(listCell, cellCaptor.getValue());
View Full Code Here

    assertEquals(COLUMN_INDEX, columnIndexCaptor.getValue());
    assertEquals(tableCell, cellCaptor.getValue());
    assertEquals(adapterFactory, adapterFactoryCaptor.getValue());

    // notify the adapter
    Notification notification = mock(Notification.class);
    when(notification.getNotifier()).thenReturn(item2);
    adapter2.notifyChanged(notification);

    verify(cellFactory, times(3)).applyTableItemProviderStyle(itemCaptor.capture(), columnIndexCaptor.capture(), cellCaptor.capture(),
        adapterFactoryCaptor.capture());
    assertEquals(item2, itemCaptor.getValue());
View Full Code Here

    assertEquals(childItems.get(0), treeItem.getChildren().get(0).getValue());

    Object childItem2 = new Object();
    childItems.add(childItem2);
   
    Notification notification = mock(Notification.class);
    when(notification.getFeature()).thenReturn(mock(EReference.class));
    adapter1.notifyChanged(notification);

    assertEquals(childItems.get(0), treeItem.getChildren().get(0).getValue());
    assertEquals(childItems.get(1), treeItem.getChildren().get(1).getValue());
  }
View Full Code Here

TOP

Related Classes of org.eclipse.emf.common.notify.Notification

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.