Package org.eclipse.emf.common.util

Examples of org.eclipse.emf.common.util.WrappedException


      }
    };
    try {
      ResourcesPlugin.getWorkspace().run(wsRunnable, null);
      if (!failedSaves.isEmpty()) {
        throw new WrappedException(createMessage(failedSaves), new RuntimeException());
      }
    } catch (final CoreException e) {
      final Throwable cause = e.getStatus().getException();
      if (cause instanceof RuntimeException) {
        throw (RuntimeException) cause;
View Full Code Here


          return file.findMaxProblemSeverity(null, true, IResource.DEPTH_INFINITE) != IMarker.SEVERITY_ERROR;
        }
      }
      return false;
    } catch (CoreException exc) {
      throw new WrappedException(exc);
    }
  }
View Full Code Here

        writer.append(content);
      } finally {
        writer.close();
      }
    } catch (IOException e) {
      throw new WrappedException(e);
    }
  }
View Full Code Here

      }
    };
    try {
      ResourcesPlugin.getWorkspace().run(wsRunnable, null);
      if (!failedSaves.isEmpty()) {
        throw new WrappedException(createMessage(failedSaves), new RuntimeException());
      }
    } catch (final CoreException e) {
      final Throwable cause = e.getStatus().getException();
      if (cause instanceof RuntimeException) {
        throw (RuntimeException) cause;
View Full Code Here

          TmpFileStoreEditorInput.UNTITLED_PROPERTY);
      }
      catch(CoreException e) {
        // Don't know what to do here - this is really bad, but doSave does not expect
        // any errors.
        throw new WrappedException(e);
      }
      if(val != null && "true".equals(val)) {
        doSaveAs();
        return;
      }
View Full Code Here

        createLink(project, linkFile, uri);
      }
      return linkFile;
    }
    catch(CoreException e) {
      throw new WrappedException(e);
    }
  }
View Full Code Here

      }
      if (p.exitValue() != 0) {
        log.error("failed to execute '" + pdfLatex + "'. Is it in your PATH?");
      }
    } catch (Exception e) {
      throw new WrappedException("pdflatex could not be run, is it in your PATH?", e);
    }
  }
View Full Code Here

        IStorage storage = ((IStorageEditorInput) editorInput).getStorage();
        return createResourceFor(storage);
      }
      throw new IllegalArgumentException("Couldn't create EMF Resource for input " + editorInput);
    } catch (CoreException e) {
      throw new WrappedException(e);
    }
  }
View Full Code Here

      }
      if (p.exitValue() != 0) {
        log.error("failed to execute '" + pdfLatex + "'. Is it in your PATH?");
      }
    } catch (Exception e) {
      throw new WrappedException("pdflatex could not be run, is it in your PATH?", e);
    }
  }
View Full Code Here

  public <R> R readOnly(URI targetURI, IUnitOfWork<R, ResourceSet> work) {
    try {
      return work.exec(resourceSet);
    }
    catch(Exception exc) {
      throw new WrappedException(exc);
    }
  }
View Full Code Here

TOP

Related Classes of org.eclipse.emf.common.util.WrappedException

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.