title: Order List of SelectItem based on value in java
body: <p>I am using Primefaces 5.1 with JSF 2.2.</p>
  
  <p>I need to ordered List of SelectItemList based on selectItem value.</p>
  
  <pre><code>List&lt;SelectItem&gt;mainList=new ArrayList&lt;SelectItem&gt;();
  mainList.add(new SelectItem("1&amp;Val1","Kumar"));
  mainList.add(new SelectItem("4&amp;Val4","Raju"));
  mainList.add(new SelectItem("5&amp;Val5","Suriya"));
  mainList.add(new SelectItem("3&amp;Val3","Kamal"));
  </code></pre>