(obj ObjectMarshaler)
| 216 | } |
| 217 | |
| 218 | func (enc *jsonEncoder) AppendObject(obj ObjectMarshaler) error { |
| 219 | // Close ONLY new openNamespaces that are created during |
| 220 | // AppendObject(). |
| 221 | old := enc.openNamespaces |
| 222 | enc.openNamespaces = 0 |
| 223 | enc.addElementSeparator() |
| 224 | enc.buf.AppendByte('{') |
| 225 | err := obj.MarshalLogObject(enc) |
| 226 | enc.buf.AppendByte('}') |
| 227 | enc.closeOpenNamespaces() |
| 228 | enc.openNamespaces = old |
| 229 | return err |
| 230 | } |
| 231 | |
| 232 | func (enc *jsonEncoder) AppendBool(val bool) { |
| 233 | enc.addElementSeparator() |
no test coverage detected