Package org.richfaces.component

Examples of org.richfaces.component.UIComboBox


    protected Class<? extends UIComponent> getComponentClass() {
      return UIComboBox.class;
    }

    protected void doDecode(FacesContext context, UIComponent component) {
  UIComboBox comboBox = null;

  if (component instanceof UIComboBox) {
      comboBox = (UIComboBox) component;
  } else {
      if (logger.isDebugEnabled()) {
    logger.debug("No decoding necessary since the component " + component.getId() + " is not an instance or a sub class of UIComboBox");
      }
      return;
  }
 
  String clientId = comboBox.getClientId(context);
  if (clientId == null) {
      throw new NullPointerException("component client id is NULL");
  }

  if (InputUtils.isDisabled(comboBox) || InputUtils.isReadOnly(comboBox)) {
      if (logger.isDebugEnabled()) {
        logger.debug(("No decoding necessary since the component " + component.getId() + " is disabled"));
      }
  }

  Map <String, String> request = context.getExternalContext().getRequestParameterMap();
  String newValue = (String) request.get(clientId);
  if (newValue != null) {
      comboBox.setSubmittedValue(newValue);
  }
    }
View Full Code Here


    }
   
    public List<Object> encodeItems(FacesContext context, UIComponent component) throws IOException, IllegalArgumentException {
      List <Object>values = new ArrayList<Object>();
    if (isAcceptableComponent(component)) {
      UIComboBox comboBox = (UIComboBox) component;
      values.addAll(encodeSuggestionValues(context, comboBox));
      List<SelectItem> selectItems = SelectUtils.getSelectItems(context, component);
      for (SelectItem selectItem : selectItems) {
          String convertedValue = getConvertedStringValue(context, component, selectItem.getValue());
        encodeSuggestion(context, comboBox, convertedValue, RICH_COMBOBOX_ITEM_CLASSES);
View Full Code Here

    protected Class<? extends UIComponent> getComponentClass() {
      return UIComboBox.class;
    }

    protected void doDecode(FacesContext context, UIComponent component) {
  UIComboBox comboBox = null;

  if (component instanceof UIComboBox) {
      comboBox = (UIComboBox) component;
  } else {
      if (logger.isDebugEnabled()) {
    logger.debug("No decoding necessary since the component " + component.getId() + " is not an instance or a sub class of UIComboBox");
      }
      return;
  }
 
  String clientId = comboBox.getClientId(context);
  if (clientId == null) {
      throw new NullPointerException("component client id is NULL");
  }

  if (InputUtils.isDisabled(comboBox) || InputUtils.isReadOnly(comboBox)) {
      if (logger.isDebugEnabled()) {
        logger.debug(("No decoding necessary since the component " + component.getId() + " is disabled"));
      }
  }

  Map <String, String> request = context.getExternalContext().getRequestParameterMap();
  String newValue = (String) request.get(clientId);
  if (newValue != null) {
      comboBox.setSubmittedValue(newValue);
  }
    }
View Full Code Here

    public List<Object> encodeItems(FacesContext context, UIComponent component) throws IOException, IllegalArgumentException {
  if (!isAcceptableComponent(component)) {
      return null;
  }

  UIComboBox comboBox = (UIComboBox) component;
  Object suggestionValues = comboBox.getSuggestionValues();
  ResponseWriter writer = context.getResponseWriter();
  List <Object>values = encodeSuggestionValues(context, component, writer, suggestionValues);
  List<SelectItem> selectItems = SelectUtils.getSelectItems(context, component);
  for (SelectItem selectItem : selectItems) {
      String value = getConvertedStringValue(context, comboBox, selectItem.getValue());
View Full Code Here

    protected Class<? extends UIComponent> getComponentClass() {
      return UIComboBox.class;
    }

    protected void doDecode(FacesContext context, UIComponent component) {
  UIComboBox comboBox = null;

  if (component instanceof UIComboBox) {
      comboBox = (UIComboBox) component;
  } else {
      if (logger.isDebugEnabled()) {
    logger.debug("No decoding necessary since the component " + component.getId() + " is not an instance or a sub class of UIComboBox");
      }
      return;
  }
 
  String clientId = comboBox.getClientId(context);
  if (clientId == null) {
      throw new NullPointerException("component client id is NULL");
  }

  if (InputUtils.isDisabled(comboBox) || InputUtils.isReadOnly(comboBox)) {
      if (logger.isDebugEnabled()) {
        logger.debug(("No decoding necessary since the component " + component.getId() + " is disabled"));
      }
  }

  Map <String, String> request = context.getExternalContext().getRequestParameterMap();
  String newValue = (String) request.get(clientId);
  if (newValue != null) {
      comboBox.setSubmittedValue(newValue);
  }
    }
View Full Code Here

    }
   
    public List<Object> encodeItems(FacesContext context, UIComponent component) throws IOException, IllegalArgumentException {
      List <Object>values = new ArrayList<Object>();
    if (isAcceptableComponent(component)) {
      UIComboBox comboBox = (UIComboBox) component;
      values.addAll(encodeSuggestionValues(context, comboBox));
      List<SelectItem> selectItems = SelectUtils.getSelectItems(context, component);
      for (SelectItem selectItem : selectItems) {
          values.add(encodeSuggestion(context, comboBox, selectItem.getValue(), RICH_COMBOBOX_ITEM_CLASSES));
      }
View Full Code Here

    protected Class<? extends UIComponent> getComponentClass() {
      return UIComboBox.class;
    }

    protected void doDecode(FacesContext context, UIComponent component) {
  UIComboBox comboBox = null;

  if (component instanceof UIComboBox) {
      comboBox = (UIComboBox) component;
  } else {
      if (logger.isDebugEnabled()) {
    logger.debug("No decoding necessary since the component " + component.getId() + " is not an instance or a sub class of UIComboBox");
      }
      return;
  }
 
  String clientId = comboBox.getClientId(context);
  if (clientId == null) {
      throw new NullPointerException("component client id is NULL");
  }

  if (InputUtils.isDisabled(comboBox) || InputUtils.isReadOnly(comboBox)) {
      if (logger.isDebugEnabled()) {
        logger.debug(("No decoding necessary since the component " + component.getId() + " is disabled"));
      }
  }

  Map <String, String> request = context.getExternalContext().getRequestParameterMap();
  String newValue = (String) request.get(clientId);
  if (newValue != null) {
      comboBox.setSubmittedValue(newValue);
  }
    }
View Full Code Here

    }
   
    public List<Object> getItems(FacesContext context, UIComponent component) throws IOException, IllegalArgumentException {
      List <Object>values = new ArrayList<Object>();
    if (isAcceptableComponent(component)) {
      UIComboBox comboBox = (UIComboBox) component;
      values.addAll(encodeSuggestionValues(context, comboBox));
      List<SelectItem> selectItems = SelectUtils.getSelectItems(context, component);
      for (SelectItem selectItem : selectItems) {
          String convertedValue = getConvertedStringValue(context, component, selectItem.getValue());
          if("".equals(convertedValue)) {
View Full Code Here

    protected Class<? extends UIComponent> getComponentClass() {
      return UIComboBox.class;
    }

    protected void doDecode(FacesContext context, UIComponent component) {
  UIComboBox comboBox = null;

  if (component instanceof UIComboBox) {
      comboBox = (UIComboBox) component;
  } else {
      if (logger.isDebugEnabled()) {
    logger.debug("No decoding necessary since the component " + component.getId() + " is not an instance or a sub class of UIComboBox");
      }
      return;
  }
 
  String clientId = comboBox.getClientId(context);
  if (clientId == null) {
      throw new NullPointerException("component client id is NULL");
  }

  if (InputUtils.isDisabled(comboBox) || InputUtils.isReadOnly(comboBox)) {
      if (logger.isDebugEnabled()) {
        logger.debug(("No decoding necessary since the component " + component.getId() + " is disabled"));
      }
  }

  Map <String, String> request = context.getExternalContext().getRequestParameterMap();
  String newValue = (String) request.get(clientId);
  if (newValue != null) {
      comboBox.setSubmittedValue(newValue);
  }
    }
View Full Code Here

    }
   
    public List<Object> getItems(FacesContext context, UIComponent component) throws IOException, IllegalArgumentException {
      List <Object>values = new ArrayList<Object>();
    if (isAcceptableComponent(component)) {
      UIComboBox comboBox = (UIComboBox) component;
      values.addAll(encodeSuggestionValues(context, comboBox));
      List<SelectItem> selectItems = SelectUtils.getSelectItems(context, component);
      for (SelectItem selectItem : selectItems) {
          String convertedValue = getConvertedStringValue(context, component, selectItem.getValue());
          if("".equals(convertedValue)) {
View Full Code Here

TOP

Related Classes of org.richfaces.component.UIComboBox

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.