public void addAttribute(String alias,String typeUri,boolean required,int count) throws MessageException {
  if (alias.indexOf(',') > -1 || alias.indexOf('.') > -1 || alias.indexOf(':') > -1 || alias.indexOf('\n') > -1)   throw new MessageException("Characters [.,:\\n] are not allowed in attribute aliases: " + alias);
  _parameters.set(new Parameter("type." + alias,typeUri));
  String level=required ? "required" : "if_available";
  Parameter levelParam=_parameters.getParameter(level);
  Parameter newParam;
  if (levelParam == null) {
    newParam=new Parameter(level,alias);
  }
 else {
    newParam=new Parameter(level,levelParam.getValue() + "," + alias);
    _parameters.removeParameters(level);
  }
  _parameters.set(newParam);
  setCount(alias,count);
  if (DEBUG)   _log.debug("Added new attribute to fetch request; type: " + typeUri + " alias: "+ alias+ " count: "+ count+ " required: "+ required);
}

public void addAttribute ( String alias , String typeUri , boolean required , int count ) throws MessageException { if ( alias . indexOf ( ',' ) > - 1 || alias . indexOf ( '.' ) > - 1 || alias . indexOf ( ':' ) > - 1 || alias . indexOf ( '\n' ) > - 1 ) throw new MessageException ( "Characters [.,:\\n] are not allowed in attribute aliases: " + alias ) ; _parameters . set ( new Parameter ( "type." + alias , typeUri ) ) ; String level = required ? "required" : "if_available" ; Parameter levelParam = _parameters . getParameter ( level ) ; Parameter newParam ; if ( levelParam == null ) { newParam = new Parameter ( level , alias ) ; } else { newParam = new Parameter ( level , levelParam . getValue ( ) + "," + alias ) ; _parameters . removeParameters ( level ) ; } _parameters . set ( newParam ) ; setCount ( alias , count ) ; if ( DEBUG ) _log . debug ( "Added new attribute to fetch request; type: " + typeUri + " alias: " + alias + " count: " + count + " required: " + required ) ; }
adds an attribute to the fetch request .
