public class DisplayFormat extends AbstractFormat
Modifier and Type | Field and Description |
---|---|
static ThreadLocation |
outBase
Fluid parameter to specify default output base for printing rationals.
|
static ThreadLocation |
outRadix
True if we should print a radix indicator when printing rationals.
|
Constructor and Description |
---|
DisplayFormat(boolean readable,
char language)
Create a new instance.
|
Modifier and Type | Method and Description |
---|---|
static DisplayFormat |
getCommonLispFormat(boolean readable) |
static DisplayFormat |
getEmacsLispFormat(boolean readable) |
boolean |
getReadableOutput() |
static DisplayFormat |
getSchemeFormat(boolean readable) |
void |
write(int v,
Consumer out) |
void |
writeBoolean(boolean v,
Consumer out) |
void |
writeList(LList value,
OutPort out) |
void |
writeObject(java.lang.Object obj,
Consumer out) |
void |
writeObjectRaw(java.lang.Object obj,
Consumer out) |
endAttribute, endElement, format, format, parseObject, startAttribute, startElement, write, writeInt, writeLong, writeObject, writeObject
public static final ThreadLocation outBase
public static final ThreadLocation outRadix
public DisplayFormat(boolean readable, char language)
readable
- if output should be formatted so it could be read
back in again, for example strings shoudl be quoted.language
- the programming language style to use, where
'S' is Scheme, 'C' is Common Lisp, and 'E' is Emacs Lisp.public static DisplayFormat getEmacsLispFormat(boolean readable)
public static DisplayFormat getCommonLispFormat(boolean readable)
public static DisplayFormat getSchemeFormat(boolean readable)
public boolean getReadableOutput()
public void writeBoolean(boolean v, Consumer out)
writeBoolean
in class AbstractFormat
public void write(int v, Consumer out)
write
in class AbstractFormat
public void writeObject(java.lang.Object obj, Consumer out)
writeObject
in class AbstractFormat
public void writeObjectRaw(java.lang.Object obj, Consumer out)