Ejemplo n.º 1
0
 /**
  * Get the index that has the given column as the first element. This method returns null if no
  * matching index is found.
  *
  * @param first if the min value should be returned
  * @return the index or null
  */
 public Index getIndexForColumn(Column column) {
   ArrayList<Index> indexes = getIndexes();
   if (indexes != null) {
     for (int i = 1, size = indexes.size(); i < size; i++) {
       Index index = indexes.get(i);
       if (index.canGetFirstOrLast()) {
         int idx = index.getColumnIndex(column);
         if (idx == 0) {
           return index;
         }
       }
     }
   }
   return null;
 }