Class JavaScriptOrJSONCFormat


public final class JavaScriptOrJSONCFormat extends AbstractJSONLikeFormat
"JavaScript or JSON" CFormat; for generating output that's compatible with both JSON and JavaScript. This format is therefore resilient against configuration mistakes, where we generate output in one language, but use the CFormat for the other. The small price to pay is that we can't utilize some language-specific opportunities to make the output a bit shorter, but that hardly matters in practice. This is the default of Configurable.getCFormat() starting from incompatible_improvements 2.3.32.

Experimental class! This class is too new, and might will change over time. Therefore, for now most methods are not exposed outside FreeMarker. The class itself and some members are exposed as they are needed for configuring FreeMarker.

Since:
2.3.32
See Also:
JavaScriptCFormat, JSONCFormat