NewFieldsList creates a new FieldsList instance with the provided fields.
(fields ...Field)
| 10 | |
| 11 | // NewFieldsList creates a new FieldsList instance with the provided fields. |
| 12 | func NewFieldsList(fields ...Field) FieldsList { |
| 13 | l := make(FieldsList, 0, len(fields)) |
| 14 | |
| 15 | for _, f := range fields { |
| 16 | l.add(-1, f) |
| 17 | } |
| 18 | |
| 19 | return l |
| 20 | } |
| 21 | |
| 22 | // FieldsList defines a Collection slice of fields. |
| 23 | type FieldsList []Field |
searching dependent graphs…