code: public void writeComment(final String comment) throws IOException {
  		
  		lineNumber++; // we're not catering for embedded newlines (must be a single-line comment)
  		
  		if( comment == null ) {
  			throw new NullPointerException(String.format("comment to write should not be null on line %d", lineNumber));
  		}
  		
  		writer.write(comment + preference.getEndOfLineSymbols());
  		
  	}
docs: {@inheritDoc}