Package javax.faces.webapp

Examples of javax.faces.webapp.UIComponentTag$UIComponentTagWrapper


  }

  @Override
  public int doStartTag() throws JspException
  {
    UIComponentTag tag = UIComponentTag.getParentUIComponentTag(pageContext);
    if (tag == null)
    {
      throw new JspException(_LOG.getMessage(
        "RETURNACTIONLISTENER_MUST_INSIDE_UICOMPONENT_TAG"));
    }

    // Only run on the first time the tag executes
    if (!tag.getCreated())
      return SKIP_BODY;

    UIComponent component = tag.getComponentInstance();
    if (!(component instanceof ActionSource))
    {
      throw new JspException(_LOG.getMessage(
        "RETURNACTIONLISTENER_MUST_INSIDE_UICOMPONENT_TAG"));
    }
View Full Code Here


  }

  @Override
  public int doStartTag() throws JspException
  {
    UIComponentTag tag =
        UIComponentTag.getParentUIComponentTag(pageContext);
    if (tag == null)
    {
      _LOG.severe("VALIDATOR_NOT_INSIDE_UICOMPONENT");
      return SKIP_BODY;
    }

    // make sure that this UIComponent has just been created:
    if (tag.getCreated())
    {
      // Create and register an instance with the appropriate component
      Validator validator = createValidator();
      if (validator != null)
      {
        EditableValueHolder evh = (EditableValueHolder) tag.getComponentInstance();
        evh.addValidator(validator);
      }
      else
      {
        _LOG.warning("CANNOT_CREATE_VALIDATOR", new String[] {_validatorId, _binding});
View Full Code Here

public class ResetActionListenerTag extends TagSupport
{
  @Override
  public int doStartTag() throws JspException
  {
    UIComponentTag tag = UIComponentTag.getParentUIComponentTag(pageContext);
    if (tag == null)
    {
      throw new JspException(_LOG.getMessage(
        "RESETACTIONLISTENER_MUST_INSIDE_UICOMPONENT_TAG"));
    }

    // Only run on the first time the tag executes
    if (!tag.getCreated())
      return SKIP_BODY;

    UIComponent component = tag.getComponentInstance();
    if (!(component instanceof ActionSource))
    {
      throw new JspException(_LOG.getMessage(
        "RESETACTIONlISTENER_MUST_INSIDE_UICOMPONENT_TAG"));
    }
View Full Code Here

  }

  @Override
  public int doStartTag() throws JspException
  {
    UIComponentTag tag = UIComponentTag.getParentUIComponentTag(pageContext);
    if (tag == null)
    {
      throw new JspException(_LOG.getMessage(
        "SETACTIONLISTENER_MUST_INSIDE_UICOMPONENT_TAG"));
    }

    // Only run on the first time the tag executes
    if (!tag.getCreated())
      return SKIP_BODY;

    UIComponent component = tag.getComponentInstance();
    if (!(component instanceof ActionSource))
    {
      throw new JspException(_LOG.getMessage(
        "SETACTIONLISTENER_MUST_INSIDE_UICOMPONENT_TAG"));
    }
View Full Code Here

     *
     * @return next transition
     * @exception JspException general JSP tag
     */
    public int doStartTag() throws JspException {
          UIComponentTag parentTag = UIComponentTag.getParentUIComponentTag(pageContext);
          if (parentTag == null) {
             throw new JspException(messages.getMessage("clayparent.notfound"));
          }

          UIComponent parentComponent = parentTag.getComponentInstance();
          if (parentComponent == null) {
              throw new JspException(messages.getMessage("clayparent.notfound"));
          }

          if (!(parentComponent instanceof Clay)) {
View Full Code Here

    // Fields
           

  public int doStartTag() throws JspException {

    UIComponentTag parentTag = UIComponentTag
        .getParentUIComponentTag(pageContext);

    if (parentTag == null) {
      throw new JspException(Messages.getMessage(
          Messages.NO_UI_COMPONENT_TAG_ANCESTOR_ERROR, this
              .getClass().getName()));
    }

    if (type == null && binding == null) {
      throw new JspException("Either of the following attributes is "
          + "required: type binding");
    }

    // Process only newly created components
    if (parentTag.getCreated()) {

      FacesContext context = FacesContext.getCurrentInstance();
      Application application = context.getApplication();

      org.richfaces.event.DragListener listener = null;

      UIComponent component = parentTag.getComponentInstance();

      // First try to access listener binding
      if (binding != null) {
        ValueBinding valueBinding = application
            .createValueBinding(binding);
View Full Code Here

    // Fields
           

  public int doStartTag() throws JspException {

    UIComponentTag parentTag = UIComponentTag
        .getParentUIComponentTag(pageContext);

    if (parentTag == null) {
      throw new JspException(Messages.getMessage(
          Messages.NO_UI_COMPONENT_TAG_ANCESTOR_ERROR, this
              .getClass().getName()));
    }

    if (type == null && binding == null) {
      throw new JspException("Either of the following attributes is "
          + "required: type binding");
    }

    // Process only newly created components
    if (parentTag.getCreated()) {

      FacesContext context = FacesContext.getCurrentInstance();
      Application application = context.getApplication();

      org.richfaces.event.NodeExpandedListener listener = null;

      UIComponent component = parentTag.getComponentInstance();

      // First try to access listener binding
      if (binding != null) {
        ValueBinding valueBinding = application
            .createValueBinding(binding);
View Full Code Here

    // Fields
           

  public int doStartTag() throws JspException {

    UIComponentTag parentTag = UIComponentTag
        .getParentUIComponentTag(pageContext);

    if (parentTag == null) {
      throw new JspException(Messages.getMessage(
          Messages.NO_UI_COMPONENT_TAG_ANCESTOR_ERROR, this
              .getClass().getName()));
    }

    if (type == null && binding == null) {
      throw new JspException("Either of the following attributes is "
          + "required: type binding");
    }

    // Process only newly created components
    if (parentTag.getCreated()) {

      FacesContext context = FacesContext.getCurrentInstance();
      Application application = context.getApplication();

      org.richfaces.event.NodeSelectedListener listener = null;

      UIComponent component = parentTag.getComponentInstance();

      // First try to access listener binding
      if (binding != null) {
        ValueBinding valueBinding = application
            .createValueBinding(binding);
View Full Code Here

    }

    protected void setParentProperties(UIAjaxSupport uiComponent)  {

        //Find parent UIComponentTag
        UIComponentTag componentTag = null;
    try {
      componentTag = UIComponentTag.getParentUIComponentTag(pageContext);
          if (componentTag == null) {
              throw new IllegalArgumentException(
                  Messages.getMessage(Messages.NO_UI_COMPONENT_TAG_ANCESTOR_ERROR, "AjaxSupportTag"));
          }

          if (componentTag.getCreated()) {
              //Component was just created, so we add the Listener
              UIComponent component = componentTag.getComponentInstance();
              uiComponent.setParentProperties(component);
          }
    } catch (ClassCastException e) {
      // JSF 1.2 - tags have other parent.
    }
View Full Code Here

        if (type == null) {
            throw new JspException(Messages.getMessage(Messages.NULL_TYPE_ATTRIBUTE_ERROR));
        }

        //Find parent UIComponentTag
        UIComponentTag componentTag = UIComponentTag
                .getParentUIComponentTag(pageContext);
        if (componentTag == null) {
            throw new JspException(
                Messages.getMessage(Messages.NO_UI_COMPONENT_TAG_ANCESTOR_ERROR, "AjaxListenerTag"));
        }

        if (componentTag.getCreated()) {
            //Component was just created, so we add the Listener
            UIComponent component = componentTag.getComponentInstance();
            if (component instanceof AjaxSource) {
                AjaxListener listener;
                if(null != binding){
                  ValueBinding valueBinding;
                  try {
View Full Code Here

TOP

Related Classes of javax.faces.webapp.UIComponentTag$UIComponentTagWrapper

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.