Package org.apache.webbeans.exception

Examples of org.apache.webbeans.exception.WebBeansException


        }
        catch (IllegalArgumentException e)
        {
            logger.error("Delegate field is not found on the given decorator class : " + instance.getClass().getName(), e);
            throw new WebBeansException(e);

        }
        catch (IllegalAccessException e)
        {
            logger.error("Illegal access exception for field " + field.getName() + " in decorator class : " + instance.getClass().getName(), e);
View Full Code Here


                        }
                        catch (SecurityException e)
                        {
                            logger.error("Security exception, can not access decorator class : " + decClazz.getName() + " method : " + method.getName(), e);
                            throw new WebBeansException(e);

                        }
                        catch (NoSuchMethodException e)
                        {
                            continue;
View Full Code Here

        catch (Exception e)
        {
            String message = "Could not add FailOverBag to session [" + bag.getSessionId() + "].";
            LOGGER.log(Level.SEVERE, message, e);

            throw new WebBeansException(message, e);
        }
    }
View Full Code Here

        {
            String message = "Could not restore beans for session [" + bag.getSessionId()
                    + "] from [" + bag.getJvmId() + "]";
            LOGGER.log(Level.SEVERE, message, e);

            throw new WebBeansException(message, e);
        }
    }
View Full Code Here

        Class<X> type = resourceReference.getResourceType();

        try {
            return type.cast(context.lookup(jndiName));
        } catch (NamingException e) {
            throw new WebBeansException("Could not get resource of type " + type + " at jndi name " + jndiName, e);
        }
    }
View Full Code Here

                        return clazz.getDeclaredField((String)parameters);
                    case METHOD_CLASS_GETDECLAREDFIELDS:
                        return clazz.getDeclaredFields();

                    default:
                        return new WebBeansException("unknown security method: " + method);
                }
            }
            catch (Exception exception)
            {
                return exception;
View Full Code Here

    public GeronimoResourceInjectionService(WebBeansContext webBeansContext) {
        try {
            this.context = new InitialContext();
            this.webBeansContext = webBeansContext;
        } catch (NamingException e) {
            throw new WebBeansException("could not set up naming context", e);
        }
    }
View Full Code Here

                boolean acess = field.isAccessible();
                try {
                    securityService.doPrivilegedSetAccessible(field, true);
                    field.set(managedBeanInstance, getResourceReference(resourceRef));
                } catch (Exception e) {
                    throw new WebBeansException("Unable to inject field" + field, e);
                } finally {
                    securityService.doPrivilegedSetAccessible(field, acess);
                }
            }
            currentClass = currentClass.getSuperclass();
View Full Code Here

                object = ((ServletContextEvent) object).getServletContext();
                return (ServletContext)object;
            }
            else
            {
                throw new WebBeansException(WebBeansLoggerFacade.getTokenString(OWBLogConst.EXCEPT_0018));
            }
        }               
       
        throw new IllegalArgumentException("ServletContextEvent object but found null");
    }
View Full Code Here

                        maxRemoval--;
                    }
                   
                    if (maxRemoval == 0)
                    {
                        throw new WebBeansException("infinite loop detected while destroying bean " + contextual);
                    }
                }
            }

            dependentObjects = null;
View Full Code Here

TOP

Related Classes of org.apache.webbeans.exception.WebBeansException

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.