org.wicketstuff.select2.StringTextChoiceProvider Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of wicketstuff-select2 Show documentation
Show all versions of wicketstuff-select2 Show documentation
Bridges Apache Wicket with Select2 components
package org.wicketstuff.select2;
import java.util.Collection;
/**
* A simple {@code StringTextChoiceProvider} for Strings.
*
* @author Tom Götz ([email protected])
*/
public abstract class StringTextChoiceProvider extends ChoiceProvider
{
private static final long serialVersionUID = 1L;
@Override
public String getDisplayValue(String choice)
{
return choice;
}
@Override
public String getIdValue(String choice)
{
return choice;
}
@Override
public Collection toChoices(Collection ids)
{
return ids;
}
}