private StringBuilder generateParameters(){
  StringBuilder parameters=new StringBuilder();
  if (filterMap == null && expandParameters == null) {
    return parameters;
  }
  parameters.append('?');
  int filterParameterCounter=0;
  if (filterMap != null && !filterMap.isEmpty()) {
    parameters.append(FILTER_PREFIX);
    for (    Map.Entry<String,String> filterEntry : filterMap.entrySet()) {
      parameters.append(String.format("%s eq '%s'",filterEntry.getKey(),filterEntry.getValue()));
      if (++filterParameterCounter < filterMap.size()) {
        parameters.append(" and ");
      }
    }
    if (expandParameters != null) {
      parameters.append("&");
    }
  }
  if (expandParameters != null) {
    parameters.append(EXPAND_PREFIX);
    Iterator iterator=expandParameters.iterator();
    parameters.append(String.format("%s",iterator.next()));
    while (iterator.hasNext()) {
      parameters.append(String.format(",%s",iterator.next()));
    }
  }
  return parameters;
}

private StringBuilder generateParameters ( ) { StringBuilder parameters = new StringBuilder ( ) ; if ( filterMap == null && expandParameters == null ) { return parameters ; } parameters . append ( '?' ) ; int filterParameterCounter = 0 ; if ( filterMap != null && ! filterMap . isEmpty ( ) ) { parameters . append ( FILTER_PREFIX ) ; for ( Map . Entry < String , String > filterEntry : filterMap . entrySet ( ) ) { parameters . append ( String . format ( "%s eq '%s'" , filterEntry . getKey ( ) , filterEntry . getValue ( ) ) ) ; if ( ++ filterParameterCounter < filterMap . size ( ) ) { parameters . append ( " and " ) ; } } if ( expandParameters != null ) { parameters . append ( "&" ) ; } } if ( expandParameters != null ) { parameters . append ( EXPAND_PREFIX ) ; Iterator iterator = expandParameters . iterator ( ) ; parameters . append ( String . format ( "%s" , iterator . next ( ) ) ) ; while ( iterator . hasNext ( ) ) { parameters . append ( String . format ( ",%s" , iterator . next ( ) ) ) ; } } return parameters ; }
returns a stringbuilder that is consisted of filtering and expanding parameters that in turn are appended to the query string used for odata client . an odata client query can have either one of filter or expand parameters ( with multiple properties if desired ) or both . < p >
