bundle

package
v0.0.0-...-0640eb1 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2021 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewConverter

func NewConverter(auth AuthConverter, api APIConverter, event EventConverter, document DocumentConverter) *converter

NewConverter missing godoc

func NewRepository

func NewRepository(conv EntityConverter) *pgRepository

NewRepository missing godoc

func NewService

func NewService(bndlRepo BundleRepository, apiSvc APIService, eventSvc EventService, documentSvc DocumentService, uidService UIDService) *service

NewService missing godoc

Types

type APIConverter

type APIConverter interface {
	ToGraphQL(in *model.APIDefinition, spec *model.Spec, bundleRef *model.BundleReference) (*graphql.APIDefinition, error)
	MultipleToGraphQL(in []*model.APIDefinition, specs []*model.Spec, bundleRefs []*model.BundleReference) ([]*graphql.APIDefinition, error)
	MultipleInputFromGraphQL(in []*graphql.APIDefinitionInput) ([]*model.APIDefinitionInput, []*model.SpecInput, error)
}

APIConverter missing godoc

type APIService

type APIService interface {
	ListByBundleIDs(ctx context.Context, bundleIDs []string, pageSize int, cursor string) ([]*model.APIDefinitionPage, error)
	GetForBundle(ctx context.Context, id string, bundleID string) (*model.APIDefinition, error)
	CreateInBundle(ctx context.Context, appID, bundleID string, in model.APIDefinitionInput, spec *model.SpecInput) (string, error)
	DeleteAllByBundleID(ctx context.Context, bundleID string) error
}

APIService missing godoc

type AuthConverter

type AuthConverter interface {
	ToGraphQL(in *model.Auth) (*graphql.Auth, error)
	InputFromGraphQL(in *graphql.AuthInput) (*model.AuthInput, error)
}

AuthConverter missing godoc

type BundleCollection

type BundleCollection []Entity

BundleCollection missing godoc

func (BundleCollection) Len

func (r BundleCollection) Len() int

Len missing godoc

type BundleConverter

type BundleConverter interface {
	ToGraphQL(in *model.Bundle) (*graphql.Bundle, error)
	CreateInputFromGraphQL(in graphql.BundleCreateInput) (model.BundleCreateInput, error)
	UpdateInputFromGraphQL(in graphql.BundleUpdateInput) (*model.BundleUpdateInput, error)
}

BundleConverter missing godoc

type BundleInstanceAuthConverter

type BundleInstanceAuthConverter interface {
	ToGraphQL(in *model.BundleInstanceAuth) (*graphql.BundleInstanceAuth, error)
	MultipleToGraphQL(in []*model.BundleInstanceAuth) ([]*graphql.BundleInstanceAuth, error)
}

BundleInstanceAuthConverter missing godoc

type BundleInstanceAuthService

type BundleInstanceAuthService interface {
	GetForBundle(ctx context.Context, id string, bundleID string) (*model.BundleInstanceAuth, error)
	List(ctx context.Context, id string) ([]*model.BundleInstanceAuth, error)
}

BundleInstanceAuthService missing godoc

type BundleReferenceService

type BundleReferenceService interface {
	GetForBundle(ctx context.Context, objectType model.BundleReferenceObjectType, objectID, bundleID *string) (*model.BundleReference, error)
	ListByBundleIDs(ctx context.Context, objectType model.BundleReferenceObjectType, bundleIDs []string, pageSize int, cursor string) ([]*model.BundleReference, map[string]int, error)
}

BundleReferenceService missing godoc

type BundleRepository

type BundleRepository interface {
	Create(ctx context.Context, item *model.Bundle) error
	Update(ctx context.Context, item *model.Bundle) error
	Delete(ctx context.Context, tenant, id string) error
	Exists(ctx context.Context, tenant, id string) (bool, error)
	GetByID(ctx context.Context, tenant, id string) (*model.Bundle, error)
	GetForApplication(ctx context.Context, tenant string, id string, applicationID string) (*model.Bundle, error)
	ListByApplicationIDNoPaging(ctx context.Context, tenantID, appID string) ([]*model.Bundle, error)
	ListByApplicationIDs(ctx context.Context, tenantID string, applicationIDs []string, pageSize int, cursor string) ([]*model.BundlePage, error)
}

BundleRepository missing godoc

type BundleService

type BundleService interface {
	Create(ctx context.Context, applicationID string, in model.BundleCreateInput) (string, error)
	Update(ctx context.Context, id string, in model.BundleUpdateInput) error
	Delete(ctx context.Context, id string) error
	Get(ctx context.Context, id string) (*model.Bundle, error)
}

BundleService missing godoc

type DocumentConverter

type DocumentConverter interface {
	ToGraphQL(in *model.Document) *graphql.Document
	MultipleToGraphQL(in []*model.Document) []*graphql.Document
	MultipleInputFromGraphQL(in []*graphql.DocumentInput) ([]*model.DocumentInput, error)
}

DocumentConverter missing godoc

type DocumentService

type DocumentService interface {
	GetForBundle(ctx context.Context, id string, bundleID string) (*model.Document, error)
	CreateInBundle(ctx context.Context, bundleID string, in model.DocumentInput) (string, error)
	ListByBundleIDs(ctx context.Context, bundleIDs []string, pageSize int, cursor string) ([]*model.DocumentPage, error)
}

DocumentService missing godoc

type Entity

type Entity struct {
	TenantID                      string         `db:"tenant_id"`
	ApplicationID                 string         `db:"app_id"`
	Name                          string         `db:"name"`
	Description                   sql.NullString `db:"description"`
	InstanceAuthRequestJSONSchema sql.NullString `db:"instance_auth_request_json_schema"`
	DefaultInstanceAuth           sql.NullString `db:"default_instance_auth"`
	OrdID                         sql.NullString `db:"ord_id"`
	ShortDescription              sql.NullString `db:"short_description"`
	Links                         sql.NullString `db:"links"`
	Labels                        sql.NullString `db:"labels"`
	CredentialExchangeStrategies  sql.NullString `db:"credential_exchange_strategies"`
	*repo.BaseEntity
}

Entity missing godoc

type EntityConverter

type EntityConverter interface {
	ToEntity(in *model.Bundle) (*Entity, error)
	FromEntity(entity *Entity) (*model.Bundle, error)
}

EntityConverter missing godoc

type EventConverter

type EventConverter interface {
	ToGraphQL(in *model.EventDefinition, spec *model.Spec, bundleReference *model.BundleReference) (*graphql.EventDefinition, error)
	MultipleToGraphQL(in []*model.EventDefinition, specs []*model.Spec, bundleRefs []*model.BundleReference) ([]*graphql.EventDefinition, error)
	MultipleInputFromGraphQL(in []*graphql.EventDefinitionInput) ([]*model.EventDefinitionInput, []*model.SpecInput, error)
}

EventConverter missing godoc

type EventService

type EventService interface {
	ListByBundleIDs(ctx context.Context, bundleIDs []string, pageSize int, cursor string) ([]*model.EventDefinitionPage, error)
	GetForBundle(ctx context.Context, id string, bundleID string) (*model.EventDefinition, error)
	CreateInBundle(ctx context.Context, appID, bundleID string, in model.EventDefinitionInput, spec *model.SpecInput) (string, error)
	DeleteAllByBundleID(ctx context.Context, bundleID string) error
}

EventService missing godoc

type Resolver

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

Resolver missing godoc

func NewResolver

func NewResolver(
	transact persistence.Transactioner,
	bundleSvc BundleService,
	bundleInstanceAuthSvc BundleInstanceAuthService,
	bundleReferenceSvc BundleReferenceService,
	apiSvc APIService,
	eventSvc EventService,
	documentSvc DocumentService,
	bundleConverter BundleConverter,
	bundleInstanceAuthConverter BundleInstanceAuthConverter,
	apiConv APIConverter,
	eventConv EventConverter,
	documentConv DocumentConverter,
	specSerice SpecService) *Resolver

NewResolver missing godoc

func (*Resolver) APIDefinition

func (r *Resolver) APIDefinition(ctx context.Context, obj *graphql.Bundle, id string) (*graphql.APIDefinition, error)

APIDefinition missing godoc

func (*Resolver) APIDefinitions

func (r *Resolver) APIDefinitions(ctx context.Context, obj *graphql.Bundle, group *string, first *int, after *graphql.PageCursor) (*graphql.APIDefinitionPage, error)

APIDefinitions missing godoc

func (*Resolver) APIDefinitionsDataLoader

func (r *Resolver) APIDefinitionsDataLoader(keys []dataloader.ParamAPIDef) ([]*graphql.APIDefinitionPage, []error)

APIDefinitionsDataLoader missing godoc

func (*Resolver) AddBundle

func (r *Resolver) AddBundle(ctx context.Context, applicationID string, in graphql.BundleCreateInput) (*graphql.Bundle, error)

AddBundle missing godoc

func (*Resolver) DeleteBundle

func (r *Resolver) DeleteBundle(ctx context.Context, id string) (*graphql.Bundle, error)

DeleteBundle missing godoc

func (*Resolver) Document

func (r *Resolver) Document(ctx context.Context, obj *graphql.Bundle, id string) (*graphql.Document, error)

Document missing godoc

func (*Resolver) Documents

func (r *Resolver) Documents(ctx context.Context, obj *graphql.Bundle, first *int, after *graphql.PageCursor) (*graphql.DocumentPage, error)

Documents missing godoc

func (*Resolver) DocumentsDataLoader

func (r *Resolver) DocumentsDataLoader(keys []dataloader.ParamDocument) ([]*graphql.DocumentPage, []error)

DocumentsDataLoader missing godoc

func (*Resolver) EventDefinition

func (r *Resolver) EventDefinition(ctx context.Context, obj *graphql.Bundle, id string) (*graphql.EventDefinition, error)

EventDefinition missing godoc

func (*Resolver) EventDefinitions

func (r *Resolver) EventDefinitions(ctx context.Context, obj *graphql.Bundle, group *string, first *int, after *graphql.PageCursor) (*graphql.EventDefinitionPage, error)

EventDefinitions missing godoc

func (*Resolver) EventDefinitionsDataLoader

func (r *Resolver) EventDefinitionsDataLoader(keys []dataloader.ParamEventDef) ([]*graphql.EventDefinitionPage, []error)

EventDefinitionsDataLoader missing godoc

func (*Resolver) InstanceAuth

func (r *Resolver) InstanceAuth(ctx context.Context, obj *graphql.Bundle, id string) (*graphql.BundleInstanceAuth, error)

InstanceAuth missing godoc

func (*Resolver) InstanceAuths

func (r *Resolver) InstanceAuths(ctx context.Context, obj *graphql.Bundle) ([]*graphql.BundleInstanceAuth, error)

InstanceAuths missing godoc

func (*Resolver) UpdateBundle

func (r *Resolver) UpdateBundle(ctx context.Context, id string, in graphql.BundleUpdateInput) (*graphql.Bundle, error)

UpdateBundle missing godoc

type SpecService

type SpecService interface {
	CreateByReferenceObjectID(ctx context.Context, in model.SpecInput, objectType model.SpecReferenceObjectType, objectID string) (string, error)
	UpdateByReferenceObjectID(ctx context.Context, id string, in model.SpecInput, objectType model.SpecReferenceObjectType, objectID string) error
	GetByReferenceObjectID(ctx context.Context, objectType model.SpecReferenceObjectType, objectID string) (*model.Spec, error)
	ListByReferenceObjectIDs(ctx context.Context, objectType model.SpecReferenceObjectType, objectIDs []string) ([]*model.Spec, error)
	RefetchSpec(ctx context.Context, id string) (*model.Spec, error)
}

SpecService missing godoc

type UIDService

type UIDService interface {
	Generate() string
}

UIDService missing godoc

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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