public void addComment(int pos,String comment){
  List<String> list=comments.get(pos);
  if (list == null) {
    list=new ArrayList<>();
    comments.put(pos,list);
  }
  list.add(encodeString(comment));
}

public void addComment ( int pos , String comment ) { List < String > list = comments . get ( pos ) ; if ( list == null ) { list = new ArrayList < > ( ) ; comments . put ( pos , list ) ; } list . add ( encodeString ( comment ) ) ; }
adds a comment to the list of comments for a given position .
