MCPcopy Index your code
hub / github.com/FiloSottile/age / HandleIdentityEncodingAsRecipient

Method HandleIdentityEncodingAsRecipient

plugin/plugin.go:131–135  ·  view source on GitHub ↗

HandleIdentityEncodingAsRecipient is like [Plugin.HandleIdentityAsRecipient] but provides the full identity encoding string to the callback.

(f func(identity string) (age.Recipient, error))

Source from the content-addressed store, hash-verified

129// HandleIdentityEncodingAsRecipient is like [Plugin.HandleIdentityAsRecipient] but
130// provides the full identity encoding string to the callback.
131func (p *Plugin) HandleIdentityEncodingAsRecipient(f func(identity string) (age.Recipient, error)) {
132 p.HandleIdentityAsRecipient(func(data []byte) (age.Recipient, error) {
133 return f(EncodeIdentity(p.name, data))
134 })
135}
136
137// HandleIdentityEncoding is like [Plugin.HandleIdentity] but provides the
138// full identity encoding string to the callback.

Callers

nothing calls this directly

Calls 2

EncodeIdentityFunction · 0.85

Tested by

no test coverage detected