v2

package
v0.21.9 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2023 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Exporter

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

func NewExporter

func NewExporter(logger *zerolog.Logger, store *bdb.BoltDB) *Exporter

func (*Exporter) Export

func (s *Exporter) Export(req *dse.ExportRequest, stream dse.Exporter_ExportServer) error

type Importer

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

func NewImporter

func NewImporter(logger *zerolog.Logger, store *bdb.BoltDB) *Importer

func (*Importer) Import

func (s *Importer) Import(stream dsi.Importer_ImportServer) error

type Reader

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

func NewReader

func NewReader(logger *zerolog.Logger, store *bdb.BoltDB) *Reader

func (*Reader) CheckPermission

Check if subject has permission on object.

func (*Reader) CheckRelation

func (s *Reader) CheckRelation(ctx context.Context, req *dsr.CheckRelationRequest) (*dsr.CheckRelationResponse, error)

Check if subject has relation to object.

func (*Reader) GetGraph

func (s *Reader) GetGraph(ctx context.Context, req *dsr.GetGraphRequest) (*dsr.GetGraphResponse, error)

Get object dependency graph.

func (*Reader) GetObject

func (s *Reader) GetObject(ctx context.Context, req *dsr.GetObjectRequest) (*dsr.GetObjectResponse, error)

Get single object instance.

func (*Reader) GetObjectMany

func (s *Reader) GetObjectMany(ctx context.Context, req *dsr.GetObjectManyRequest) (*dsr.GetObjectManyResponse, error)

Get multiple object instances by id or type+key, in a single request.

func (*Reader) GetObjectType

func (s *Reader) GetObjectType(ctx context.Context, req *dsr.GetObjectTypeRequest) (*dsr.GetObjectTypeResponse, error)

Get object type (metadata).

func (*Reader) GetObjectTypes

Get all objects types (metadata) (paginated).

func (*Reader) GetObjects

func (s *Reader) GetObjects(ctx context.Context, req *dsr.GetObjectsRequest) (*dsr.GetObjectsResponse, error)

Get all object instances, optionally filtered by object type. (paginated).

func (*Reader) GetPermission

func (s *Reader) GetPermission(ctx context.Context, req *dsr.GetPermissionRequest) (*dsr.GetPermissionResponse, error)

Get permission (metadata).

func (*Reader) GetPermissions

Get all permissions (metadata) (paginated).

func (*Reader) GetRelation

func (s *Reader) GetRelation(ctx context.Context, req *dsr.GetRelationRequest) (*dsr.GetRelationResponse, error)

Get relation instances based on subject, relation, object filter.

func (*Reader) GetRelationType

Get relation type (metadata).

func (*Reader) GetRelationTypes

Get all relation types, optionally filtered by object type (metadata) (paginated).

func (*Reader) GetRelations

func (s *Reader) GetRelations(ctx context.Context, req *dsr.GetRelationsRequest) (*dsr.GetRelationsResponse, error)

Get relation instances based on subject, relation, object filter (paginated).

type Writer

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

func NewWriter

func NewWriter(logger *zerolog.Logger, store *bdb.BoltDB) *Writer

func (*Writer) DeleteObject

func (s *Writer) DeleteObject(ctx context.Context, req *dsw.DeleteObjectRequest) (*dsw.DeleteObjectResponse, error)

func (*Writer) DeleteObjectType

func (*Writer) DeletePermission

func (*Writer) DeleteRelation

func (*Writer) DeleteRelationType

func (*Writer) SetObject

func (s *Writer) SetObject(ctx context.Context, req *dsw.SetObjectRequest) (*dsw.SetObjectResponse, error)

object methods.

func (*Writer) SetObjectType

func (s *Writer) SetObjectType(ctx context.Context, req *dsw.SetObjectTypeRequest) (*dsw.SetObjectTypeResponse, error)

object type metadata methods.

func (*Writer) SetPermission

func (s *Writer) SetPermission(ctx context.Context, req *dsw.SetPermissionRequest) (*dsw.SetPermissionResponse, error)

permission metadata methods.

func (*Writer) SetRelation

func (s *Writer) SetRelation(ctx context.Context, req *dsw.SetRelationRequest) (*dsw.SetRelationResponse, error)

relation methods.

func (*Writer) SetRelationType

relation type metadata methods.

Jump to

Keyboard shortcuts

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