FieldNames returns a slice with the name of all list fields.
()
| 39 | |
| 40 | // FieldNames returns a slice with the name of all list fields. |
| 41 | func (l FieldsList) FieldNames() []string { |
| 42 | result := make([]string, len(l)) |
| 43 | |
| 44 | for i, field := range l { |
| 45 | result[i] = field.GetName() |
| 46 | } |
| 47 | |
| 48 | return result |
| 49 | } |
| 50 | |
| 51 | // AsMap returns a map with all registered list field. |
| 52 | // The returned map is indexed with each field name. |