Documentation ¶
Index ¶
- Variables
- type Config
- type RelationRepository
- func (r RelationRepository) Add(ctx context.Context, rel relation.Relation) error
- func (r RelationRepository) Check(ctx context.Context, rel relation.Relation, permissionName string) (bool, error)
- func (r RelationRepository) Delete(ctx context.Context, rel relation.Relation) error
- func (r RelationRepository) ListRelations(ctx context.Context, rel relation.Relation) ([]relation.Relation, error)
- func (r RelationRepository) LookupResources(ctx context.Context, rel relation.Relation) ([]string, error)
- func (r RelationRepository) LookupSubjects(ctx context.Context, rel relation.Relation) ([]string, error)
- type SchemaRepository
- type SpiceDB
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrWritingSchema = errors.New("error in writing schema to spicedb")
)
Functions ¶
This section is empty.
Types ¶
type RelationRepository ¶
type RelationRepository struct {
// contains filtered or unexported fields
}
func NewRelationRepository ¶
func NewRelationRepository(spiceDB *SpiceDB, fullyConsistent bool) *RelationRepository
func (RelationRepository) ListRelations ¶
func (r RelationRepository) ListRelations(ctx context.Context, rel relation.Relation) ([]relation.Relation, error)
ListRelations shouldn't be used in high TPS flows as consistency requirements are set high
func (RelationRepository) LookupResources ¶
func (RelationRepository) LookupSubjects ¶
type SchemaRepository ¶
type SchemaRepository struct {
// contains filtered or unexported fields
}
func NewSchemaRepository ¶
func NewSchemaRepository(logger log.Logger, spiceDB *SpiceDB) *SchemaRepository
func (SchemaRepository) WriteSchema ¶
func (r SchemaRepository) WriteSchema(ctx context.Context, schema string) error
Click to show internal directories.
Click to hide internal directories.