func (f EntityFetcherFunc) OrganizationRights(ctx context.Context, ids ttnpb.OrganizationIdentifiers) (*ttnpb.Rights, error) {
	rights, err := f(ctx, ids.GetEntityIdentifiers())
	registerRightsFetch(ctx, "organization", rights, err)
	return rights, err
}
OrganizationRights implements the Fetcher interface.
package rights
import (
	"context"
	"go.thethings.network/lorawan-stack/v3/pkg/errors"
	"go.thethings.network/lorawan-stack/v3/pkg/rpcmetadata"
	"go.thethings.network/lorawan-stack/v3/pkg/ttnpb"
	"google.golang.org/grpc"
)
type EntityFetcher interface {
	ApplicationRights(context.Context, ttnpb.ApplicationIdentifiers) (*ttnpb.Rights, error)
	ClientRights(context.Context, ttnpb.ClientIdentifiers) (*ttnpb.Rights, error)
	GatewayRights(context.Context, ttnpb.GatewayIdentifiers) (*ttnpb.Rights, error)
	OrganizationRights(context.Context, ttnpb.OrganizationIdentifiers) (*ttnpb.Rights, error)
	UserRights(context.Context, ttnpb.UserIdentifiers) (*ttnpb.Rights, error)
}
type AuthInfoFetcher interface {
	AuthInfo(context.Context) (*ttnpb.AuthInfoResponse, error)
}
type Fetcher interface {
	EntityFetcher
	AuthInfoFetcher
}
type EntityFetcherFunc func(ctx context.Context, ids *ttnpb.EntityIdentifiers) (*ttnpb.Rights, error)
func (f EntityFetcherFunc) ApplicationRights(ctx context.Context, ids ttnpb.ApplicationIdentifiers) (*ttnpb.Rights, error) {
	rights, err := f(ctx, ids.GetEntityIdentifiers())
	registerRightsFetch(ctx, "application", rights, err)
	return rights, err
}
func (f EntityFetcherFunc) ClientRights(ctx context.Context, ids ttnpb.ClientIdentifiers) (*ttnpb.Rights, error) {
	rights, err := f(ctx, ids.GetEntityIdentifiers())
	registerRightsFetch(ctx, "client", rights, err)
	return rights, err
}
func (f EntityFetcherFunc) GatewayRights(ctx context.Context, ids ttnpb.GatewayIdentifiers) (*ttnpb.Rights, error) {
	rights, err := f(ctx, ids.GetEntityIdentifiers())
	registerRightsFetch(ctx, "gateway", rights, err)
	return rights, err
}