Package org.apache.geronimo.interop

Examples of org.apache.geronimo.interop.SystemException


    public static Object invokeStatic(String methodSignature, Object[] args) {
        try {
            return getStaticMethod(methodSignature).invoke(null, args);
        } catch (InvocationTargetException ite) {
            throw new SystemException(ite.getTargetException());
        } catch (RuntimeException ex) {
            throw ex;
        } catch (Exception ex) {
            throw new SystemException(ex);
        }
    }
View Full Code Here


                _echoStream.println(cmd);
            }
            File dirFile = dir == null ? null : new File(dir);
            process = Runtime.getRuntime().exec(cmd, env, dirFile);
        } catch (Exception ex) {
            throw new SystemException(ex);
        }
        run(process);
    }
View Full Code Here

                _echoStream.println(cmd);
            }
            File dirFile = dir == null ? null : new File(dir);
            process = Runtime.getRuntime().exec(cmd, env, dirFile);
        } catch (Exception ex) {
            throw new SystemException(ex);
        }
        run(process);
    }
View Full Code Here

            inputThread.join();
            _errorBytes = errorThread.getBytes();
            _inputBytes = inputThread.getBytes();
            _exitValue = process.exitValue();
        } catch (Exception ex) {
            throw new SystemException(ex);
        }
    }
View Full Code Here

    public void checkStatus() {
        if (_exitValue != 0) {
            // TODO: I18N
            String result = getResult();
            throw new SystemException("Command Failed: " + _cmd
                                      + "\nExit Status: " + _exitValue
                                      + (result.length() == 0 ? "" : ("\nOutput: " + getResult())));
        }
    }
View Full Code Here

                            _echoStream.flush();
                        }
                    }
                }
            } catch (Exception ex) {
                throw new SystemException(ex);
            }
        }
View Full Code Here

            }
            return h;
        }
        catch (Exception ex)
        {
            throw new SystemException(ex);
        }
    }
View Full Code Here

                    throw (Error) ex;
                }
                if (ex instanceof RuntimeException) {
                    throw (RuntimeException) ex;
                }
                throw new SystemException(ex);
            } else {
                StringBuffer buffer = new StringBuffer();
                for (Iterator i = exceptions.iterator(); i.hasNext();) {
                    Exception ex = (Exception) i.next();
                    if (buffer.length() > 0) {
                        buffer.append("\n______________________________________________________________\n\n");
                    }
                    buffer.append(ExceptionUtil.getStackTrace(ex));
                }
                throw new SystemException(buffer.toString());
            }
        }
    }
View Full Code Here

    {
        for (;;)
        {
            if (ex instanceof SystemException)
            {
                SystemException se = (SystemException)ex;
                if (se.getCause() != null && se.getMessage() == null)
                {
                    ex = se.getCause();
                }
                else
                {
                    break;
                }
View Full Code Here

    public static RuntimeException getRuntimeException(Exception ex) {
        if (ex instanceof RuntimeException) {
            return (RuntimeException) ex;
        } else {
            return new SystemException(ex);
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.geronimo.interop.SystemException

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.