Package org.apache.commons.lang

Examples of org.apache.commons.lang.UnhandledException


                beanUtils.copyProperty(bean, "", value);
                return bean.getInstance();
            }
            catch (Exception e)
            {
                throw new UnhandledException(e);
            }
        }
View Full Code Here


        {
           return Base64.encodeBytes(IOUtils.toByteArray(content));
        }
        catch (IOException e)
        {
            throw new UnhandledException("Could not encode the stream", e);
        }
        finally
        {
            IOUtils.closeQuietly(content);
        }
View Full Code Here

            IOUtils.copyLarge(stream, output);
            output.flush();
            byte[] bytes = output.getMessageDigest().digest();
            return hex(bytes);
        } catch (NoSuchAlgorithmException e) {
            throw new UnhandledException(e);
        } finally {
            IOUtils.closeQuietly(output);
        }
    }
View Full Code Here

            IOUtils.copyLarge(dis, new NullOutputStream());
            dis.close();
            byte[] bytes = dis.getMessageDigest().digest();
            return hex(bytes);
        } catch (NoSuchAlgorithmException e) {
            throw new UnhandledException(e);
        } catch (IOException e) {
            throw new UnhandledException(e);
        } finally {
            IOUtils.closeQuietly(is);
        }
    }
View Full Code Here

                try {
                    file = new File(dir, name.substring(0, name.length() - 4));
                    OutputStream os = openOutputStream(file);
                    freemarker.process(input.getInputStream(), InstallerMojo.this, os, ftlOutputEncoding);
                } catch (IOException e) {
                    throw new UnhandledException(e);
                } finally {
                    closeQuietly(out);
                }
            } else {
                file = super.apply(input);
View Full Code Here

                try {
                    file = new File(dir, name.substring(0, name.length() - 4));
                    OutputStream os = openOutputStream(file);
                    freemarker.process(input.getInputStream(), InstallerMojo.this, os, ftlOutputEncoding);
                } catch (IOException e) {
                    throw new UnhandledException(e);
                } finally {
                    closeQuietly(out);
                }
            } else {
                file = super.apply(input);
View Full Code Here

            IOUtils.copyLarge(dis, new NullOutputStream());
            dis.close();
            byte[] bytes = dis.getMessageDigest().digest();
            return hex(bytes);
        } catch (NoSuchAlgorithmException e) {
            throw new UnhandledException(e);
        } catch (IOException e) {
            throw new UnhandledException(e);
        } finally {
            IOUtils.closeQuietly(is);
        }
    }
View Full Code Here

  @Override
  public String getKey() {
    try {
      return (String) this.eventKeyMethod.invoke(this.event);
    } catch (Exception e) {
      throw new UnhandledException("Error getting key for event " + this.event.getClass(), e);
    }
  }
View Full Code Here

            twin = (TableProperties) super.clone();
        }
        catch (CloneNotSupportedException e)
        {
            // should never happen
            throw new UnhandledException(e);
        }
        twin.properties = (Properties) this.properties.clone();
        return twin;
    }
View Full Code Here

TOP

Related Classes of org.apache.commons.lang.UnhandledException

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.