br.com.jarch.faces.converter.PickListMapJsfConverter Maven / Gradle / Ivy
package br.com.jarch.faces.converter;
import org.primefaces.component.picklist.PickList;
import org.primefaces.model.DualListModel;
import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;
import javax.faces.convert.Converter;
import javax.faces.convert.FacesConverter;
import java.util.Iterator;
import java.util.Map;
@FacesConverter("br.com.jarch.faces.converter.pickListMapConverter")
public class PickListMapJsfConverter implements Converter {
@Override
public Object getAsObject(FacesContext arg0, UIComponent arg1, String arg2) {
Object ret = null;
if (arg1 instanceof PickList) {
Object dualList = ((PickList) arg1).getValue();
DualListModel
© 2015 - 2024 Weber Informatics LLC | Privacy Policy