types

package
v5.4.40 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 22, 2026 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Overview

Package types is a generated GoMock package.

Index

Constants

View Source
const RevocationLDDocumentType = "application/ld+json;type=revocation"

RevocationLDDocumentType holds the content type used in network documents which contain Revocation messages of credentials in JSON-LD form

View Source
const VcDocumentType = "application/vc+json"

VcDocumentType holds the content type used in network documents which contain Verifiable Credentials

Variables

View Source
var ErrCredentialNotValidAtTime = errors.New("credential not valid at given time")

ErrCredentialNotValidAtTime is returned when the credential is not valid at the given time.

View Source
var ErrInvalidCredential = errors.New("invalid credential")

ErrInvalidCredential is returned when validation failed

View Source
var ErrMultipleFound = errors.New("multiple found")

ErrMultipleFound is returned when multiple credentials or revocations are found for the same ID.

View Source
var ErrNotFound = errors.New("credential not found")

ErrNotFound is returned when a credential can not be found based on its ID.

View Source
var ErrPresentationNotValidAtTime = errors.New("presentation not valid at given time")

ErrPresentationNotValidAtTime is returned when the presentation is not valid at the given time.

View Source
var ErrRevoked = errors.New("credential is revoked")

ErrRevoked is returned when a credential has been revoked and the required action requires it to not be revoked.

View Source
var ErrUntrusted = errors.New("credential issuer is untrusted")

ErrUntrusted is returned when a credential is resolved or searched but its issuer is not trusted.

Functions

This section is empty.

Types

type MockWriter

type MockWriter struct {
	// contains filtered or unexported fields
}

MockWriter is a mock of Writer interface.

func NewMockWriter

func NewMockWriter(ctrl *gomock.Controller) *MockWriter

NewMockWriter creates a new mock instance.

func (*MockWriter) EXPECT

func (m *MockWriter) EXPECT() *MockWriterMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockWriter) StoreCredential

func (m *MockWriter) StoreCredential(vc vc.VerifiableCredential, validAt *time.Time) error

StoreCredential mocks base method.

type MockWriterMockRecorder

type MockWriterMockRecorder struct {
	// contains filtered or unexported fields
}

MockWriterMockRecorder is the mock recorder for MockWriter.

func (*MockWriterMockRecorder) StoreCredential

func (mr *MockWriterMockRecorder) StoreCredential(vc, validAt interface{}) *gomock.Call

StoreCredential indicates an expected call of StoreCredential.

type Writer

type Writer interface {
	// StoreCredential writes a VC to storage. Before writing, it calls Verify!
	// It can handle duplicates.
	StoreCredential(vc vc.VerifiableCredential, validAt *time.Time) error
}

Writer is the interface that groups al the VC write methods

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL