protected int keyOnList(String key,List<String> list){
  int ret=-1;
  int index=0;
  if (list != null) {
    for (    String listKey : list) {
      if (listKey.equalsIgnoreCase(key)) {
        ret=index;
        break;
      }
      index++;
    }
  }
  return ret;
}

protected int keyOnList ( String key , List < String > list ) { int ret = - 1 ; int index = 0 ; if ( list != null ) { for ( String listKey : list ) { if ( listKey . equalsIgnoreCase ( key ) ) { ret = index ; break ; } index ++ ; } } return ret ; }
figure out if the string key is in the provided list , and provide the location index of it is .
