Package javax.faces.view.facelets

Examples of javax.faces.view.facelets.TagException


        {
            if (log.isLoggable(Level.SEVERE))
            {
                log.log(Level.SEVERE, "Cannot create PropertyDescriptor for attribute ",e);
            }
            throw new TagException(tag,e);
        }
    }
View Full Code Here


    public void apply(FaceletContext ctx, UIComponent parent) throws IOException
    {
        // make sure our parent is not null
        if (parent == null)
        {
            throw new TagException(_delegate.getTag(), "Parent UIComponent was null");
        }
       
        FacesContext facesContext = ctx.getFacesContext();

        // possible facet scoped
View Full Code Here

    public void apply(FaceletContext ctx, UIComponent parent)
            throws IOException
    {
        if (parent == null)
        {
            throw new TagException(this.tag, "Parent UIComponent was null");
        }
        if (! (parent instanceof UIViewRoot) )
        {
            throw new TagException(this.tag, "Parent UIComponent "+parent.getId()+" should be instance of UIViewRoot");
        }
        FaceletCompositionContext mctx = FaceletCompositionContext.getCurrentInstance(ctx);
        if (mctx.isBuildingViewMetadata())
        {
            UIComponent metadataFacet = parent.getFacet(UIViewRoot.METADATA_FACET_NAME);
View Full Code Here

        }
        else if (UIComponent.isCompositeComponent(parent))
        {
            if (getFor() == null)
            {
                throw new TagException(_delegate.getTag(), "is nested inside a composite component"
                        + " but does not have a for attribute.");
            }
            FaceletCompositionContext mctx = FaceletCompositionContext.getCurrentInstance(ctx);
            mctx.addAttachedObjectHandler(parent, _delegate);
        }
        else
        {
            throw new TagException(_delegate.getTag(), "Parent not composite component or an instance of ValueHolder: " + parent);
        }     
    }
View Full Code Here

     */
    protected Converter createConverter(FaceletContext ctx)
    {
        if (_delegate.getConverterId(ctx) == null)
        {
            throw new TagException(
                                   _delegate.getTag(),
                                   "Default behavior invoked of requiring a converter-id passed in the constructor, must override ConvertHandler(ConverterConfig)");
        }
        return ctx.getFacesContext().getApplication().createConverter(_delegate.getConverterId(ctx));
    }
View Full Code Here

                ve.setValue(faceletContext, c);
            }
        }
        if (c == null)
        {
            throw new TagException(_delegate.getTag(), "No Converter was created");
        }
        _delegate.setAttributes(faceletContext, c);
        vh.setConverter(c);
        Object lv = vh.getLocalValue();
        FacesContext faces = faceletContext.getFacesContext();
View Full Code Here

            // used to create a tag outside jsf implementation to attach targets.
            mctx.addAttachedObjectHandler(parent, _delegate);
        }
        else
        {
            throw new TagException(_delegate.getTag(), "Parent not composite component or an instance of ClientBehaviorHolder: " + parent);
        }
       
    }
View Full Code Here

   
    protected Behavior createBehavior(FaceletContext ctx)
    {
        if (_delegate.getBehaviorId() == null)
        {
            throw new TagException(
                                   _delegate.getTag(),
                                   "No behavior id defined");
        }
        return ctx.getFacesContext().getApplication().createBehavior(_delegate.getBehaviorId());
    }
View Full Code Here

                ve.setValue(faceletContext, behavior);
            }
        }
        if (behavior == null)
        {
            throw new TagException(_delegate.getTag(), "No Validator was created");
        }
        _delegate.setAttributes(faceletContext, behavior);
       
        if (behavior instanceof ClientBehavior)
        {
View Full Code Here

           
            String facetName = _name.getValue(ctx);
   
            if (_required != null && _required.getBoolean(ctx) && parentCompositeComponent.getFacet(facetName) == null)
            {
                throw new TagException(this.tag, "Cannot find facet with name '"+facetName+"' in composite component");
            }
           
            c.getAttributes().put(UIComponent.FACETS_KEY, facetName);
        }
    }
View Full Code Here

TOP

Related Classes of javax.faces.view.facelets.TagException

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.