Package com.google.gwt.event.shared

Examples of com.google.gwt.event.shared.UmbrellaException


    return root;
  }

  public static UmbrellaException createUmbrellaException() {
    Set<Throwable> causes = new HashSet<Throwable>();
    UmbrellaException exception = new UmbrellaException(causes);
    SerializationException e1 = new SerializationException("Test Message 1", exception);
    SerializationException e2 = new SerializationException("Test Message 2", e1);
    causes.add(e1);
    causes.add(e2);
    return exception;
View Full Code Here


public class ExceptionsTest extends RpcTestBase {

  private ExceptionsTestServiceAsync exceptionsTestService;

  public void testUmbrellaException() {
    final UmbrellaException expected = TestSetFactory.createUmbrellaException();
    checkException(expected, new AsyncCallback<UmbrellaException>() {
      @Override
      public void onFailure(Throwable caught) {
        TestSetValidator.rethrowException(caught);
      }
View Full Code Here

    view.draw();
  }

  private Throwable unwrap(Throwable e) {  
      if(e instanceof UmbrellaException) {  
        UmbrellaException ue = (UmbrellaException) e; 
        if(ue.getCauses().size() == 1) {  
          return unwrap(ue.getCauses().iterator().next())
       
      } 
      return e; 
    }
View Full Code Here

        causes = doFire(firstPriorityHandlers, event, causes);
        causes = doFire(normalPriorityHandlers, event, causes);
        causes = doFire(lastPriorityHandlers, event, causes);

        if (causes != null) {
            throw new UmbrellaException(causes);
        }
    }
View Full Code Here

        root.add(errorNode);
    }

    public void log(Throwable e) {
        if (e instanceof UmbrellaException) {
            UmbrellaException ue = (UmbrellaException) e;
            for (Throwable t : ue.getCauses()) {
                log(t);
            }
            return;
        }
        log(Util.getSimpleName(e) + ": " + e.getMessage());
View Full Code Here

        GWT.log(e.getMessage(), e);
    }

    public void error(Throwable e) {
        if (e instanceof UmbrellaException) {
            UmbrellaException ue = (UmbrellaException) e;
            for (Throwable t : ue.getCauses()) {
                error(t);
            }
            return;
        }
        error(Util.getSimpleName(e) + ": " + e.getMessage());
View Full Code Here

        globalPopup.center();
    }

    public static Throwable unwrapUmbrellaException(Throwable e) {
        if (e instanceof UmbrellaException) {
            UmbrellaException ue = (UmbrellaException) e;
            if (ue.getCauses().size() == 1) {
                return unwrapUmbrellaException(ue.getCauses().iterator().next());
            }
        }
        return e;
    }
View Full Code Here

        GWT.log(e.getMessage(), e);
    }

    public void error(Throwable e) {
        if (e instanceof UmbrellaException) {
            UmbrellaException ue = (UmbrellaException) e;
            for (Throwable t : ue.getCauses()) {
                error(t);
            }
            return;
        }
        error(Util.getSimpleName(e) + ": " + e.getMessage());
View Full Code Here

        root.add(errorNode);
    }

    public void log(Throwable e) {
        if (e instanceof UmbrellaException) {
            UmbrellaException ue = (UmbrellaException) e;
            for (Throwable t : ue.getCauses()) {
                log(t);
            }
            return;
        }
        log(Util.getSimpleName(e) + ": " + e.getMessage());
View Full Code Here

        causes.add(t);
      }
    }

    if (causes != null) {
      throw new UmbrellaException(causes);
    }
  }
View Full Code Here

TOP

Related Classes of com.google.gwt.event.shared.UmbrellaException

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.