MCPcopy Create free account
hub / github.com/devfile/api / normalizeUnion

Function normalizeUnion

pkg/apis/workspaces/v1alpha2/union_implementation.go:57–68  ·  view source on GitHub ↗
(union Union, visitorType reflect.Type)

Source from the content-addressed store, hash-verified

55}
56
57func normalizeUnion(union Union, visitorType reflect.Type) error {
58 err := updateDiscriminator(union, visitorType)
59 if err != nil {
60 return err
61 }
62
63 err = cleanupValues(union, visitorType)
64 if err != nil {
65 return err
66 }
67 return nil
68}
69
70func updateDiscriminator(union Union, visitorType reflect.Type) error {
71 unionValue := reflect.ValueOf(union)

Callers 15

simplifyUnionFunction · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70
NormalizeMethod · 0.70

Calls 2

updateDiscriminatorFunction · 0.70
cleanupValuesFunction · 0.70

Tested by

no test coverage detected