Examples of NotificationImpl


Examples of org.eclipse.emf.common.notify.impl.NotificationImpl

    if (isNotificationRequired())
    {
      Entry entry = (Entry)object;
      EStructuralFeature feature = entry.getEStructuralFeature();
      Object value = entry.getValue();
      NotificationImpl notification =
        createNotification
          (Notification.SET,
           feature,
           value,
           value,
View Full Code Here

Examples of org.eclipse.emf.common.notify.impl.NotificationImpl

    if (isNotificationRequired())
    {
      int index = size;
      boolean oldIsSet = isSet();
      doAddUnique(entry);
      NotificationImpl notification = createNotification(Notification.ADD, null, entry, index, oldIsSet);
      if (hasInverse())
      {
        NotificationChain notifications = inverseAdd(entry, null);
        notifications = shadowAdd(entry, notifications);
View Full Code Here

Examples of org.eclipse.emf.common.notify.impl.NotificationImpl

    {
      if (isNotificationRequired())
      {
        boolean oldIsSet = isSet();
        doAddAllUnique(index, entries, start, end);
        NotificationImpl notification;
        if (collectionSize == 0)
        {
          notification = createNotification(Notification.ADD, null, entries[0], index, oldIsSet);
        }
        else
View Full Code Here

Examples of org.eclipse.emf.common.notify.impl.NotificationImpl

    if (isNotificationRequired())
    {
      boolean oldIsSet = !isEmpty(feature);
      notifications = basicAdd(entry, notifications);
      NotificationImpl notification =
        feature.isMany() ?
          createNotification
            (Notification.ADD,
             feature,
             null,
View Full Code Here

Examples of org.eclipse.emf.common.notify.impl.NotificationImpl

    if (match != null)
    {
      if (isNotificationRequired())
      {
        NotificationImpl notification =
          feature.isMany() ?
            createNotification
              (Notification.REMOVE,
               feature,
               object,
View Full Code Here

Examples of org.eclipse.emf.common.notify.impl.NotificationImpl

      if (match != null)
      {
        if (isNotificationRequired())
        {
          @SuppressWarnings("null")
          NotificationImpl notification =
            feature.isMany() ?
              createNotification
                (Notification.REMOVE,
                 feature,
View Full Code Here

Examples of org.eclipse.emf.common.notify.impl.NotificationImpl

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

Examples of org.springmodules.xt.model.notification.NotificationImpl

       
        office1.setOfficeId("aaa");
        emp1.setMatriculationCode("1");
        office1.addEmployee(emp1);
       
        Notification notification = new NotificationImpl();
       
        assertFalse(this.compositeSpecification.compose(spec1).withMessage(new MessageImpl("wrong.office.id", Message.Type.ERROR, "Wrong Office Id"), false)
                                                                       .and(spec2).withMessage(new MessageImpl("office.unavailable", Message.Type.ERROR, "Office Not Available"), false)
                                                                       .evaluate(office1, notification));
                                                   
        assertTrue(notification.hasMessages(Message.Type.ERROR));
        assertFalse(notification.hasMessages(Message.Type.WARNING));
        assertFalse(notification.hasMessages(Message.Type.INFO));
        assertTrue(notification.getMessages(Message.Type.ERROR).length == 1);
        assertEquals("wrong.office.id", notification.getMessages(Message.Type.ERROR)[0].getCode());
        assertEquals("Wrong Office Id",notification.getMessages(Message.Type.ERROR)[0].getDefaultMessage());
    }
View Full Code Here

Examples of org.springmodules.xt.model.notification.NotificationImpl

       
        office1.setOfficeId("aaa");
        emp1.setMatriculationCode("1");
        office1.addEmployee(emp1);
       
        Notification notification = new NotificationImpl();
       
        assertFalse(this.compositeSpecification.compose(spec1).withMessage(new MessageImpl("wrong.office.id", Message.Type.WARNING, "Wrong Office Id"), false)
                                                                       .and(spec2).withMessage(new MessageImpl("office.unavailable", Message.Type.WARNING, "Office Not Available"), false)
                                                                       .evaluate(office1, notification));
                                                   
        assertFalse(notification.hasMessages(Message.Type.ERROR));
        assertTrue(notification.hasMessages(Message.Type.WARNING));
        assertFalse(notification.hasMessages(Message.Type.INFO));
        assertTrue(notification.getMessages(Message.Type.WARNING).length == 1);
        assertEquals("wrong.office.id", notification.getMessages(Message.Type.WARNING)[0].getCode());
        assertEquals("Wrong Office Id", notification.getMessages(Message.Type.WARNING)[0].getDefaultMessage());
    }
View Full Code Here

Examples of org.springmodules.xt.model.notification.NotificationImpl

       
        office1.setOfficeId("o1");
        emp1.setMatriculationCode("1");
        office1.addEmployee(emp1);
       
        Notification notification = new NotificationImpl();
       
        assertTrue(this.compositeSpecification.compose(spec1).withMessage(new MessageImpl("good.office.id", Message.Type.INFO, "Good Office Id"), true)
                                                                       .and(spec2).withMessage(new MessageImpl("office.available", Message.Type.INFO, "Office Available"), true)
                                                                       .evaluate(office1, notification));
                                                   
        assertFalse(notification.hasMessages(Message.Type.ERROR));
        assertFalse(notification.hasMessages(Message.Type.WARNING));
        assertTrue(notification.hasMessages(Message.Type.INFO));
        assertTrue(notification.getMessages(Message.Type.INFO).length == 2);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.