json/model/nullNode.go

16 lines
227 B
Go

package model
type NullNode struct{}
func (n NullNode) Type() NodeType {
return NullType
}
func (n NullNode) MarshalJSON() ([]byte, error) {
return []byte("null"), nil
}
func (n NullNode) Set(v any) error {
return nil
}