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: key_type_gen.go
    path of file: ./repos/corteza/server/vendor/github.com/lestrrat-go/jwx/jwa
    
    the code of the file until where you have to start completion: // this file was auto-generated by internal/cmd/gentypes/main.go: DO NOT EDIT

package jwa

import (
	"fmt"
	"sort"
	"sync"

	"github.com/pkg/errors"
)

// KeyType represents the key type ("kty") that are su
    
func (v *KeyType) Accept(value interface{}) error {
	var tmp KeyType
	if x, ok := value.(KeyType); ok {
		tmp = x
	} else {
		var s string
		switch x := value.(type) {
		case fmt.Stringer:
			s = x.String()
		case string:
			s = x
		default:
			return errors.Errorf(`invalid type for jwa.KeyType: %T`, value)
		}
		tmp = KeyType(s)
	}
	if _, ok := allKeyTypes[tmp]; !ok {
		return errors.Errorf(`invalid jwa.KeyType value`)
	}

	*v = tmp
	return nil
}