Documentation ¶
Index ¶
- Variables
- func NewTransferAccessMethod() *ocm.AccessMethod
- func NewTransferProtocol(sourceURI, sharedSecret string, size uint64) *ocm.Protocol
- func NewWebDAVProtocol(uri, shareSecred string, perms *ocm.SharePermissions) *ocm.Protocol
- func NewWebDavAccessMethod(perms *provider.ResourcePermissions) *ocm.AccessMethod
- func NewWebappAccessMethod(mode appprovider.ViewMode) *ocm.AccessMethod
- func NewWebappProtocol(uriTemplate string, viewMode appprovider.ViewMode) *ocm.Protocol
- func ResourceIDFilter(id *provider.ResourceId) *ocm.ListOCMSharesRequest_Filter
- type Repository
Constants ¶
This section is empty.
Variables ¶
ErrShareAlreadyExisting is the error returned when the share already exists for the 3-tuple consisting of (owner, resource, grantee).
ErrShareNotFound is the error returned where the share does not exist.
Functions ¶
func NewTransferAccessMethod ¶ added in v2.17.0
func NewTransferAccessMethod() *ocm.AccessMethod
NewTransferAccessMethod is an abstraction for creating a Transfer access method.
func NewTransferProtocol ¶ added in v2.17.0
NewTransferProtocol is an abstraction for creating a Transfer protocol.
func NewWebDAVProtocol ¶ added in v2.17.0
func NewWebDAVProtocol(uri, shareSecred string, perms *ocm.SharePermissions) *ocm.Protocol
NewWebDAVProtocol is an abstraction for creating a WebDAV protocol.
func NewWebDavAccessMethod ¶ added in v2.17.0
func NewWebDavAccessMethod(perms *provider.ResourcePermissions) *ocm.AccessMethod
NewWebDavAccessMethod is an abstraction for creating a WebDAV access method.
func NewWebappAccessMethod ¶ added in v2.17.0
func NewWebappAccessMethod(mode appprovider.ViewMode) *ocm.AccessMethod
NewWebappAccessMethod is an abstraction for creating a Webapp access method.
func NewWebappProtocol ¶ added in v2.17.0
func NewWebappProtocol(uriTemplate string, viewMode appprovider.ViewMode) *ocm.Protocol
NewWebappProtocol is an abstraction for creating a Webapp protocol.
func ResourceIDFilter ¶
func ResourceIDFilter(id *provider.ResourceId) *ocm.ListOCMSharesRequest_Filter
ResourceIDFilter is an abstraction for creating filter by resource id.
Types ¶
type Repository ¶ added in v2.17.0
type Repository interface { context.Context, share *ocm.Share) (*ocm.Share, error) GetShare(ctx context.Context, user *userpb.User, ref *ocm.ShareReference) (*ocm.Share, error) DeleteShare(ctx context.Context, user *userpb.User, ref *ocm.ShareReference) error UpdateShare(ctx context.Context, user *userpb.User, ref *ocm.ShareReference, f ...*ocm.UpdateOCMShareRequest_UpdateField) (*ocm.Share, error) // it returns only shares attached to the given resource. ListShares(ctx context.Context, user *userpb.User, filters []*ocm.ListOCMSharesRequest_Filter) ([]*ocm.Share, error) StoreReceivedShare(ctx context.Context, share *ocm.ReceivedShare) (*ocm.ReceivedShare, error) ListReceivedShares(ctx context.Context, user *userpb.User) ([]*ocm.ReceivedShare, error) GetReceivedShare(ctx context.Context, user *userpb.User, ref *ocm.ShareReference) (*ocm.ReceivedShare, error) UpdateReceivedShare(ctx context.Context, user *userpb.User, share *ocm.ReceivedShare, fieldMask *field_mask.FieldMask) (*ocm.ReceivedShare, error) }StoreShare(ctx
Repository is the interface that manipulates the OCM shares repository.