()
| 14 | } |
| 15 | |
| 16 | func (gt GravityType) MarshalJSON() ([]byte, error) { |
| 17 | for k, v := range GravityTypes { |
| 18 | if v == gt { |
| 19 | return fmt.Appendf([]byte{}, "%q", k), nil |
| 20 | } |
| 21 | } |
| 22 | return fmt.Appendf([]byte{}, "%s", "null"), nil |
| 23 | } |
| 24 | |
| 25 | const ( |
| 26 | GravityUnknown GravityType = iota |
nothing calls this directly
no outgoing calls
no test coverage detected