- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for IsTypeSliceOfInterface (0.32 sec)
-
operator/pkg/util/reflect.go
func IsTypeInterface(t reflect.Type) bool { if t == reflect.TypeOf(nil) { return false } return t.Kind() == reflect.Interface } // IsTypeSliceOfInterface reports whether v is a slice of interface. func IsTypeSliceOfInterface(t reflect.Type) bool { if t == reflect.TypeOf(nil) { return false } return t.Kind() == reflect.Slice && t.Elem().Kind() == reflect.Interface }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Mon Jul 25 19:30:47 UTC 2022 - 8.6K bytes - Viewed (0) -
operator/pkg/util/reflect_test.go
okTypes: []any{testNilMap, testMap}, }, { desc: "IsTypeInterface", function: IsTypeInterface, okTypes: []any{}, }, { desc: "IsTypeSliceOfInterface", function: IsTypeSliceOfInterface, okTypes: []any{testSliceOfInterface}, }, } for _, tt := range tests { for vidx, v := range allTypes {
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Mon Jul 25 19:30:47 UTC 2022 - 10.2K bytes - Viewed (0)