Documentation ¶
Overview ¶
Package holder is a generated GoMock package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var VerifiableCredentialLDContextV1 = ssi.MustParseURI("https://www.w3.org/2018/credentials/v1")
VerifiableCredentialLDContextV1 holds the URI of the JSON-LD context for Verifiable Credentials.
var VerifiablePresentationLDType = ssi.MustParseURI("VerifiablePresentation")
VerifiablePresentationLDType holds the JSON-LD type for Verifiable Presentations.
Functions ¶
This section is empty.
Types ¶
type Holder ¶
type Holder interface { // BuildVP builds and signs a Verifiable Presentation using the given Verifiable Credentials. // The assertion key used for signing it is taken from signerDID's DID document. // If signerDID is not provided, it will be derived from the credentials credentialSubject.id fields. But only if all provided credentials have the same (singular) credentialSubject.id field. BuildVP(credentials []vc.VerifiableCredential, proofOptions proof.ProofOptions, signerDID *did.DID, validateVC bool) (*vc.VerifiablePresentation, error) }
Holder holds logic for Presenting credentials A Holder is a role an entity might perform by: * Possessing one or more verifiable credentials * Generating verifiable presentations from them Example holders include students, employees, and customers.
type MockHolder ¶
type MockHolder struct {
// contains filtered or unexported fields
}
MockHolder is a mock of Holder interface.
func NewMockHolder ¶
func NewMockHolder(ctrl *gomock.Controller) *MockHolder
NewMockHolder creates a new mock instance.
func (*MockHolder) BuildVP ¶
func (m *MockHolder) BuildVP(credentials []vc.VerifiableCredential, proofOptions proof.ProofOptions, signerDID *did.DID, validateVC bool) (*vc.VerifiablePresentation, error)
BuildVP mocks base method.
func (*MockHolder) EXPECT ¶
func (m *MockHolder) EXPECT() *MockHolderMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockHolderMockRecorder ¶
type MockHolderMockRecorder struct {
// contains filtered or unexported fields
}
MockHolderMockRecorder is the mock recorder for MockHolder.
func (*MockHolderMockRecorder) BuildVP ¶
func (mr *MockHolderMockRecorder) BuildVP(credentials, proofOptions, signerDID, validateVC interface{}) *gomock.Call
BuildVP indicates an expected call of BuildVP.