Package org.apache.isis.core.commons.exceptions

Examples of org.apache.isis.core.commons.exceptions.IsisException


            final Class<?> cls = loadBuiltIn(className);
            return internalLoadSpecification(cls);
        } catch (final ClassNotFoundException e) {
            final ObjectSpecification spec = getCache().get(className);
            if (spec == null) {
                throw new IsisException("No such class available: " + className);
            }
            return spec;
        }
    }
View Full Code Here


            if (spec != null) {
                return spec;
            }
            final ObjectSpecification specification = createSpecification(type);
            if (specification == null) {
                throw new IsisException("Failed to create specification for class " + typeName);
            }

            // put into the cache prior to introspecting, to prevent
            // infinite loops
            specificationCache.cache(typeName, specification);
View Full Code Here

            final Properties p = new Properties();
            p.load(resourceAsStream);
            final String version = p.getProperty("version");
            return version;
        } catch (final IOException e) {
            throw new IsisException(e);
        }

    }
View Full Code Here

     * Will throw an exception if an instance has already been created and is
     * not {@link ContextReplacePolicy#REPLACEABLE}.
     */
    protected IsisContext(final ContextReplacePolicy replacePolicy, final SessionClosePolicy sessionClosePolicy, final IsisSessionFactory sessionFactory) {
        if (singleton != null && !singleton.isContextReplaceable()) {
            throw new IsisException("Isis Context already set up and cannot be replaced");
        }
        singleton = this;
        this.sessionFactory = sessionFactory;
        this.sessionClosePolicy = sessionClosePolicy;
        this.replacePolicy = replacePolicy;
View Full Code Here

            final ProxyObject proxyObject = (ProxyObject) newInstance;
            proxyObject.setHandler(methodHandler);

            return newInstance;
        } catch (final InstantiationException e) {
            throw new IsisException(e);
        } catch (final IllegalAccessException e) {
            throw new IsisException(e);
        }
    }
View Full Code Here

            final ProxyObject proxyObject = (ProxyObject) newInstance;
            proxyObject.setHandler(methodHandler);

            return newInstance;
        } catch (final InstantiationException e) {
            throw new IsisException(e);
        } catch (final IllegalAccessException e) {
            throw new IsisException(e);
        }
    }
View Full Code Here

                    String line;
                    while ((line = fileInputStream.readLine()) != null) {
                        print(fileInputStream.getLineNumber() + "  " + line);
                    }
                } catch (final Exception e) {
                    throw new IsisException(e);
                } finally {
                    CloseableExtensions.closeSafely(fileInputStream);
                }
                print("");
            }
View Full Code Here

    private PerspectiveEntry entry;

    public PerspectiveEntry getPerspective() {
        if (entry == null) {
            if (entries.size() == 0) {
                throw new IsisException("No perspective in user profile");
            } else {
                entry = entries.get(0);
            }
        }
        return entry;
View Full Code Here

        for (final PerspectiveEntry entry : entries) {
            if (entry.getName().equals(name)) {
                return entry;
            }
        }
        throw new IsisException("No perspective " + name);
    }
View Full Code Here

                }
            });

            return newInstance;
        } catch (final InstantiationException e) {
            throw new IsisException(e);
        } catch (final IllegalAccessException e) {
            throw new IsisException(e);
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.isis.core.commons.exceptions.IsisException

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.