resourcesharewire

package
v1.157.0 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2026 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Package resourcesharewire assembles resource shares (#2258) from the platform: the share store, the persona each caller resolves to, the people of a persona, and the share email.

It is a package of its own rather than a function in the composition root because that root is at its size budget.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CallerOf

func CallerOf(reg *persona.Registry) func(roles []string) resourceshare.Caller

CallerOf resolves a caller's persona for the share routes.

func TablePermission

func TablePermission(p *platform.Platform) tablesource.SharePermission

TablePermission is the permission a share gives a table registration's caller on a resource, which lets an editor share register a table over it (#2258); nil without a database.

Types

type Shares

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

Shares is the assembled service, nil on a deployment without a database, where nothing is shared and every method does nothing.

func New

func New(p *platform.Platform, notify *notifydelivery.Handle) *Shares

New assembles the service for p, telling recipients through notify.

func (*Shares) Bind

Bind wraps the resources API's claims so each request's carry the caller's share lookup, and makes them the claims the share routes authenticate with.

func (*Shares) Register

func (s *Shares) Register(mux *http.ServeMux)

Register mounts the share routes on mux, and the channel route when the deployment can post.

Jump to

Keyboard shortcuts

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