SetIndent changes the used indentation used when encoding.
(spaces int)
| 272 | |
| 273 | // SetIndent changes the used indentation used when encoding. |
| 274 | func (e *Encoder) SetIndent(spaces int) { |
| 275 | if spaces < 0 { |
| 276 | panic("yaml: cannot indent to a negative number of spaces") |
| 277 | } |
| 278 | e.encoder.indent = spaces |
| 279 | } |
| 280 | |
| 281 | // Close closes the encoder by writing any remaining data. |
| 282 | // It does not write a stream terminating string "...". |
no outgoing calls