Package yalp.exceptions

Examples of yalp.exceptions.UnexpectedException


        List<String> modules = new ArrayList<String>();
        if (localModules.exists() && localModules.isDirectory()) {
            try {
                modules = dm.retrieveModules();
            } catch (Exception e) {
                throw new UnexpectedException("There was a problem parsing dependencies.yml");

            }
            for (Iterator iter = modules.iterator(); iter.hasNext(); ) {
                String moduleName = (String) iter.next();
View Full Code Here


    public InputStream get() {
        if (exists()) {
            try {
                return new FileInputStream(getFile());
            } catch (Exception e) {
                throw new UnexpectedException(e);
            }
        }
        return null;
    }
View Full Code Here

                    bais = new ByteArrayInputStream(baos.toByteArray());
                    //
                    Response.current().contentType = "image/png";
                }
            } catch (Exception e) {
                throw new UnexpectedException(e);
            }
        }
View Full Code Here

                }
            }

            return parameters;
        } catch (Exception e) {
            throw new UnexpectedException("Cannot extract parameter names", e);
        }
    }
View Full Code Here

                }
            }

            return parameters;
        } catch (Exception e) {
            throw new UnexpectedException("Cannot extract parameter names", e);
        }
    }
View Full Code Here

    public static String encodePart(String part) {
        try {
            return URLEncoder.encode(part, "utf-8");
        } catch (Exception e) {
            throw new UnexpectedException(e);
        }
    }
View Full Code Here

            // Must not call rootParamNode.getChild in that case, as it returns null. Use rootParamNode itself instead.
            ParamNode beanNode = StringUtils.isEmpty(name) ? rootParamNode : rootParamNode.getChild(name, true);
            Binder.bindBean(beanNode, o, annotations);
            return (T) o;
        } catch (Exception e) {
            throw new UnexpectedException(e);
        } finally {
            // restoring changes to paramNode
            ParamNode.restoreRemovedChildren(removedNodesList);
        }
    }
View Full Code Here

                            attachment.model = this;
                            attachment.name = field.getName();
                            field.set(this, attachment);
                        }
                    } catch (Exception ex) {
                        throw new UnexpectedException(ex);
                    }
                }
            }
            c = c.getSuperclass();
        }
View Full Code Here

                            attachment.model = this;
                            attachment.name = field.getName();
                            attachment.save();
                        }
                    } catch (Exception ex) {
                        throw new UnexpectedException(ex);
                    }
                }
            }
            c = c.getSuperclass();
        }
View Full Code Here

                    waitAllLock.countDown();
                    if (waitAllLock.getCount() == 0) {
                        try {
                            result.invoke(result.get());
                        } catch (Exception e) {
                            throw new UnexpectedException(e);
                        }
                    }
                }
            };
            for (Promise<T> f : promises) {
View Full Code Here

TOP

Related Classes of yalp.exceptions.UnexpectedException

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.