add defaultSeqIndent method

This commit is contained in:
Natasha Sarkar
2021-06-24 12:05:54 -07:00
committed by Katrina Verey
parent d5a2009d3f
commit 298d977ee7

View File

@@ -283,6 +283,11 @@ func (e *Encoder) CompactSeqIndent() {
e.encoder.emitter.compact_sequence_indent = true
}
// DefaultSeqIndent makes it so that '- ' is not considered part of the indentation.
func (e *Encoder) DefaultSeqIndent() {
e.encoder.emitter.compact_sequence_indent = false
}
// Close closes the encoder by writing any remaining data.
// It does not write a stream terminating string "...".
func (e *Encoder) Close() (err error) {