title: How to implement multiple sort on JSF dataTable based on map value
body: <p>I'm trying to sort a list which is accessible via map structure (in its value) like this:</p>
  
  <pre><code>&lt;ui:param name="currentKey" value="..." /&gt;
  &lt;p:dataTable value="#{bean.map[currentKey].currentList}" sortMode="multiple"&gt;
      ...
  &lt;/p:dataTable&gt;
  </code></pre>
  
  <p>and corresponding bean</p>
  
  <pre><code>class Bean {
      HashMap&lt;Object, MyDataModel&gt; map; // + getter
  }
  
  class MyDataModel {
      List&lt;Object&gt; currentList; // + getter
  }
  </code></pre>
  
  <p>But I get the exception with the description:</p>
  
  <blockquote>
    <p>Multiple selection reference must be an Array or a List for datatable</p>
  </blockquote>
  
  <p>How should the <code>currentList</code> property be accessed in order for <code>sortMode="multiple"</code> to work?</p>
  
  <p>Note: I have also tried a simple version with <code>HashMap&lt;Object, List&lt;Object&gt;&gt; map</code> and the xhtml code like <code>value="#{bean.map[currentKey]}"</code> and got the same exception.</p>
  
  <ul>
  <li>JSF 2 </li>
  <li>Primefaces 5.0</li>
  </ul>