MarshalText implements encoding.TextMarshaler.
()
| 78 | |
| 79 | // MarshalText implements encoding.TextMarshaler. |
| 80 | func (nu NullUUID) MarshalText() ([]byte, error) { |
| 81 | if nu.Valid { |
| 82 | return nu.UUID.MarshalText() |
| 83 | } |
| 84 | |
| 85 | return jsonNull, nil |
| 86 | } |
| 87 | |
| 88 | // UnmarshalText implements encoding.TextUnmarshaler. |
| 89 | func (nu *NullUUID) UnmarshalText(data []byte) error { |
nothing calls this directly
no outgoing calls
no test coverage detected