Documentation ¶
Index ¶
- Variables
- type AlbumSharedObserver
- type AlbumUnSharedObserver
- type CatalogAuthorizer
- func (a *CatalogAuthorizer) CanShareAlbum(ctx context.Context, user usermodel.CurrentUser, albumId catalog.AlbumId) error
- func (a *CatalogAuthorizer) IsAuthorisedToListMedias(ctx context.Context, userId usermodel.CurrentUser, albumId catalog.AlbumId) error
- func (a *CatalogAuthorizer) IsAuthorisedToViewMedia(ctx context.Context, currentUser usermodel.CurrentUser, owner ownermodel.Owner, ...) error
- type CatalogQueriesPort
- type FindAlbumPort
- type HasPermissionPort
- type ReverseReader
- func (f *ReverseReader) GetAlbumSharingGrid(ctx context.Context, owner ownermodel.Owner) (map[catalog.AlbumId][]usermodel.UserId, error)
- func (f *ReverseReader) ListAlbumIdsSharedWithUser(ctx context.Context, userId usermodel.UserId) ([]catalog.AlbumId, error)
- func (f *ReverseReader) ListUsersWhoCanAccessAlbum(ctx context.Context, albumIds ...catalog.AlbumId) (map[catalog.AlbumId][]catalogviews.Availability, error)
- type ScopeReadRepositoryPort
- type ShareAlbumCase
- type UnShareAlbumCase
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrAccessDenied = errors.New("access denied")
)
Functions ¶
This section is empty.
Types ¶
type AlbumSharedObserver ¶ added in v1.6.4
type AlbumSharedObserver interface {
}type AlbumUnSharedObserver ¶ added in v1.6.4
type AlbumUnSharedObserver interface {
}type CatalogAuthorizer ¶ added in v1.6.5
type CatalogAuthorizer struct { HasPermissionPort HasPermissionPort CatalogQueriesPort CatalogQueriesPort }
func (*CatalogAuthorizer) CanShareAlbum ¶ added in v1.6.5
func (a *CatalogAuthorizer) CanShareAlbum(ctx context.Context, user usermodel.CurrentUser, albumId catalog.AlbumId) error
func (*CatalogAuthorizer) IsAuthorisedToListMedias ¶ added in v1.6.5
func (a *CatalogAuthorizer) IsAuthorisedToListMedias(ctx context.Context, userId usermodel.CurrentUser, albumId catalog.AlbumId) error
func (*CatalogAuthorizer) IsAuthorisedToViewMedia ¶ added in v1.6.5
func (a *CatalogAuthorizer) IsAuthorisedToViewMedia(ctx context.Context, currentUser usermodel.CurrentUser, owner ownermodel.Owner, mediaId catalog.MediaId) error
type CatalogQueriesPort ¶ added in v1.6.5
type FindAlbumPort ¶ added in v1.6.4
type HasPermissionPort ¶ added in v1.6.5
type ReverseReader ¶ added in v1.6.5
type ReverseReader struct {
ScopeRepository ScopeReadRepositoryPort
}
ReverseReader reads the permissions to read what can be accessed by who, and who can access what
func (*ReverseReader) GetAlbumSharingGrid ¶ added in v1.6.5
func (f *ReverseReader) GetAlbumSharingGrid(ctx context.Context, owner ownermodel.Owner) (map[catalog.AlbumId][]usermodel.UserId, error)
func (*ReverseReader) ListAlbumIdsSharedWithUser ¶ added in v1.6.5
func (*ReverseReader) ListUsersWhoCanAccessAlbum ¶ added in v1.6.5
func (f *ReverseReader) ListUsersWhoCanAccessAlbum(ctx context.Context, albumIds ...catalog.AlbumId) (map[catalog.AlbumId][]catalogviews.Availability, error)
type ScopeReadRepositoryPort ¶ added in v1.6.5
type UnShareAlbumCase ¶
type UnShareAlbumCase struct {}
func (*UnShareAlbumCase) StopSharingAlbum ¶
Click to show internal directories.
Click to hide internal directories.