You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: yaml.go
    path of file: ./repos/ko/vendor/sigs.k8s.io/kind/pkg/apis/config/v1alpha4
    
    the code of the file until where you have to start completion: /*
Copyright 2019 The Kubernetes Authors.

Licensed under the Apache License, V
    
func (p *PortMapping) UnmarshalYAML(unmarshal func(interface{}) error) error {
	// first unmarshal in the alias type (to avoid a recursion loop on unmarshal)
	type PortMappingAlias PortMapping
	var a PortMappingAlias
	if err := unmarshal(&a); err != nil {
		return err
	}
	// now handle the protocol field
	a.Protocol = PortMappingProtocol(strings.ToUpper(string(a.Protocol)))
	switch a.Protocol {
	case "": // unset, will be defaulted
	case PortMappingProtocolTCP:
	case PortMappingProtocolUDP:
	case PortMappingProtocolSCTP:
	default:
		return errors.Errorf("Unknown PortMappingProtocol: %q", a.Protocol)
	}
	// and copy over the fields
	*p = PortMapping(a)
	return nil
}