Package javax.faces

Examples of javax.faces.FacesException


                }
            });

            root = (Root) unmarshaller.unmarshal(TreeModelDataBean.class.getResource("tree-model-data.xml"));
        } catch (JAXBException e) {
            throw new FacesException(e.getMessage(), e);
        }
    }
View Full Code Here


        ELContext context = getFacesContext().getELContext();

        try {
            setLiteralAttribute(name, expression.getValue(context));
        } catch (ELException elem) {
            throw new FacesException(elem);
        }
    }
View Full Code Here

        addDefaultModules(modules);
        try {
            modules.addAll(ServiceLoader.loadServices(Module.class));
            injector.init(modules);
        } catch (ServiceException e) {
            throw new FacesException(e);
        }
        return injector;
    }
View Full Code Here

        return getServicesFactory().getInstance(target);
    }

    private static ServicesFactory getServicesFactory() {
        if (!INSTANCES.containsKey(getCurrentLoader())) {
            throw new FacesException("Service Tracker has not been initialized");
        }
        ServicesFactory service = INSTANCES.get(getCurrentLoader());
        return service;
    }
View Full Code Here

            Method postConstructMethod = introspectionData.getPostConstructMethod();
            if (postConstructMethod != null) {
                invokeMethod(bean, postConstructMethod);
            }
        } catch (IllegalArgumentException e) {
            throw new FacesException(e.getMessage(), e);
        } catch (IllegalAccessException e) {
            throw new FacesException(e.getMessage(), e);
        } catch (InvocationTargetException e) {
            throw new FacesException(e.getMessage(), e);
        }
    }
View Full Code Here

        if (converter == null && type != null && !type.equals(String.class) && !type.equals(Object.class)) {
            try {
                converter = context.getApplication().createConverter(type);
            } catch (Exception e) {
                throw new FacesException(Messages.getMessage(Messages.NO_CONVERTER_REGISTERED, type.getName()), e);
            }
        }

        return converter;
    }
View Full Code Here

    protected Object executeOperation(FacesContext context, Operation operation, String name) {
        MutableInteger counter = getCounter(context);

        try {
            if (counter.getAndIncrement() > 100) {
                throw new FacesException(Messages.getMessage(Messages.SKIN_CYCLIC_REFERENCE, name));
            }

            Object result = operation.executeLocal(context, this, name);
            if (result != null) {
                return result;
View Full Code Here

            System.arraycopy(compressed, 0, zipsrc, 0, totalOut);
            compressor.end();

            return CODEC.encode(zipsrc);
        } catch (Exception e) {
            throw new FacesException("Error encode resource data", e);
        }
    }
View Full Code Here

            System.arraycopy(uncompressed, 0, out, 0, totalOut);
            decompressor.end();

            return out;
        } catch (Exception e) {
            throw new FacesException("Error decode resource data", e);
        }
    }
View Full Code Here

            ByteArrayOutputStream baos = new ByteArrayOutputStream();
            DataOutputStream dos = new DataOutputStream(baos);
            try {
                stateHolderResource.writeState(context, dos);
            } catch (IOException e) {
                throw new FacesException(e.getMessage(), e);
            } finally {
                try {
                    dos.close();
                } catch (IOException e) {
                    RESOURCE_LOGGER.debug(e.getMessage(), e);
View Full Code Here

TOP

Related Classes of javax.faces.FacesException

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.