Package javax.faces.component

Examples of javax.faces.component.UISelectItems


    if (LOG.isDebugEnabled()) {
      for (Object o : selectOne.getChildren()) {
        LOG.debug("ITEMS " + o);
        if (o instanceof UISelectItems) {
          UISelectItems uiitems = (UISelectItems) o;
          Object v = uiitems.getValue();
          LOG.debug("VALUE " + v);
          if (v != null) {
            LOG.debug("VALUE " + v.getClass().getName());
          }
        }
View Full Code Here


                                      ui.isNoSelectionOption());
            }
            updateSingeItemIterator(ui, item);
            items = singleItemIterator;
        } else if (kid instanceof UISelectItems) {
            UISelectItems ui = (UISelectItems) kid;
            Object value = ui.getValue();
            if (value != null) {
                if (value instanceof SelectItem) {
                    updateSingeItemIterator(ui, (SelectItem) value);
                    items = singleItemIterator;
                } else if (value.getClass().isArray()) {
View Full Code Here

        return languagesSelectItems;
    }

    protected void validateValue(FacesContext context, Object value) {
      UISelectItems selectItems = new UISelectItems();
      selectItems.setTransient(true);
      selectItems.setValue(getLanguagesChoicesAsSelectItemList());
      getChildren().add(selectItems);
     
      super.validateValue(context,value);
    }
View Full Code Here

        return countriesSelectItems;
    }

    protected void validateValue(FacesContext context, Object value) {
      UISelectItems selectItems = new UISelectItems();
      selectItems.setTransient(true);
      selectItems.setValue(getCountriesChoicesAsSelectItemList());
      getChildren().add(selectItems);
     
      super.validateValue(context,value);
    }
View Full Code Here

     * @param value
     */
    @Override
    protected void validateValue(FacesContext facesContext, Object value) {
        if (this instanceof SelectItemsInterface) {
            UISelectItems pseudoSelectItems = SelectManyHelper.getPseudoSelectItems((SelectItemsInterface) this);
            if (pseudoSelectItems != null) {
                this.getChildren().add(pseudoSelectItems);
                super.validateValue(facesContext, value);
                this.getChildren().remove(pseudoSelectItems);
                return;
View Full Code Here

        }
        return converter;
    }

    public static UISelectItems getPseudoSelectItems(SelectItemsInterface selectItemsInterface) {
        UISelectItems selectItems = null;
        if (selectItemsInterface.getVar() != null && selectItemsInterface.getItemValues() != null) {
            selectItems = new UISelectItems();
            selectItems.setValue(selectItemsInterface.getItemValues());
            selectItems.getAttributes().put("var", selectItemsInterface.getVar());
            if (selectItemsInterface.getItemValue() != null) {
                selectItems.getAttributes().put("itemValue", selectItemsInterface.getItemValue());
            }
            if (selectItemsInterface.getItemLabel() != null) {
                selectItems.getAttributes().put("itemLabel", selectItemsInterface.getItemLabel());
            }
        }
        return selectItems;
    }
View Full Code Here

     * @param value
     */
    @Override
    protected void validateValue(FacesContext facesContext, Object value) {
        if (this instanceof SelectItemsInterface) {
            UISelectItems pseudoSelectItems = SelectManyHelper.getPseudoSelectItems((SelectItemsInterface) this);
            if (pseudoSelectItems != null) {
                this.getChildren().add(pseudoSelectItems);
                super.validateValue(facesContext, value);
                this.getChildren().remove(pseudoSelectItems);
                return;
View Full Code Here

            if (child.get(i) instanceof UISelectItem){
                UISelectItem item = (UISelectItem)child.get(i);
                WmlRenderUtils.writeOption((SelectItem)item.getValue(), comp, writer);
            }
            if (child.get(i) instanceof UISelectItems){               
                UISelectItems item = (UISelectItems)child.get(i);               
                WmlRenderUtils.writeOptions(item.getValue(), comp, writer);
            }
        }
       
        writer.endElement(Attributes.SELECT);
    }
View Full Code Here

            if (child.get(i) instanceof UISelectItem){
                UISelectItem item = (UISelectItem)child.get(i);
                WmlRenderUtils.writeOption((SelectItem)item.getValue(), comp, writer);
            }
            if (child.get(i) instanceof UISelectItems){               
                UISelectItems item = (UISelectItems)child.get(i);               
                WmlRenderUtils.writeOptions(item.getValue(), comp, writer);
            }
        }
       
        writer.endElement(Attributes.SELECT);
    }
View Full Code Here

    if (LOG.isDebugEnabled()) {
      for (Object o : component.getChildren()) {
        LOG.debug("ITEMS " + o);
        if (o instanceof UISelectItems) {
          UISelectItems uiitems = (UISelectItems) o;
          Object v = uiitems.getValue();
          LOG.debug("VALUE " + v);
          if (v != null) {
            LOG.debug("VALUE " + v.getClass().getName());
          }
        }
View Full Code Here

TOP

Related Classes of javax.faces.component.UISelectItems

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.