buf.append( "'" );
String text = ast.getText();
appendEscapedMultibyteChars(text, buf);
buf.append( "'" );
if ( ast instanceof DisplayableNode ) {
DisplayableNode displayableNode = ( DisplayableNode ) ast;
// Add a space before the display text.
buf.append( " " ).append( displayableNode.getDisplayText() );
}
String s = buf.toString();
return s;
}