Files
Quic/api/graphql/generated.go
T

13102 lines
437 KiB
Go

// Code generated by github.com/99designs/gqlgen, DO NOT EDIT.
package api
import (
"bytes"
"context"
"embed"
"errors"
"fmt"
"math"
"strconv"
"sync/atomic"
"time"
"github.com/99designs/gqlgen/graphql"
"github.com/99designs/gqlgen/graphql/introspection"
"github.com/photoview/photoview/api/graphql/models"
gqlparser "github.com/vektah/gqlparser/v2"
"github.com/vektah/gqlparser/v2/ast"
)
// region ************************** generated!.gotpl **************************
// NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.
func NewExecutableSchema(cfg Config) graphql.ExecutableSchema {
return &executableSchema{SchemaData: cfg.Schema, Resolvers: cfg.Resolvers, Directives: cfg.Directives, ComplexityRoot: cfg.Complexity}
}
type Config = graphql.Config[ResolverRoot, DirectiveRoot, ComplexityRoot]
type ResolverRoot interface {
Album() AlbumResolver
FaceGroup() FaceGroupResolver
ImageFace() ImageFaceResolver
Media() MediaResolver
Mutation() MutationResolver
Query() QueryResolver
ShareToken() ShareTokenResolver
SiteInfo() SiteInfoResolver
Subscription() SubscriptionResolver
User() UserResolver
}
type DirectiveRoot struct {
IsAdmin func(ctx context.Context, obj any, next graphql.Resolver) (res any, err error)
IsAuthorized func(ctx context.Context, obj any, next graphql.Resolver) (res any, err error)
}
type ComplexityRoot struct {
Album struct {
FilePath func(childComplexity int) int
ID func(childComplexity int) int
Media func(childComplexity int, order *models.Ordering, paginate *models.Pagination, onlyFavorites *bool) int
Owner func(childComplexity int) int
ParentAlbum func(childComplexity int) int
Path func(childComplexity int) int
Shares func(childComplexity int) int
SubAlbums func(childComplexity int, order *models.Ordering, paginate *models.Pagination) int
Thumbnail func(childComplexity int) int
Title func(childComplexity int) int
}
AuthorizeResult struct {
Status func(childComplexity int) int
Success func(childComplexity int) int
Token func(childComplexity int) int
}
Coordinates struct {
Latitude func(childComplexity int) int
Longitude func(childComplexity int) int
}
FaceGroup struct {
ID func(childComplexity int) int
ImageFaceCount func(childComplexity int) int
ImageFaces func(childComplexity int, paginate *models.Pagination) int
Label func(childComplexity int) int
}
FaceRectangle struct {
MaxX func(childComplexity int) int
MaxY func(childComplexity int) int
MinX func(childComplexity int) int
MinY func(childComplexity int) int
}
ImageFace struct {
FaceGroup func(childComplexity int) int
ID func(childComplexity int) int
Media func(childComplexity int) int
Rectangle func(childComplexity int) int
}
Media struct {
Album func(childComplexity int) int
Blurhash func(childComplexity int) int
Date func(childComplexity int) int
Downloads func(childComplexity int) int
Exif func(childComplexity int) int
Faces func(childComplexity int) int
Favorite func(childComplexity int) int
HighRes func(childComplexity int) int
ID func(childComplexity int) int
Path func(childComplexity int) int
Shares func(childComplexity int) int
Thumbnail func(childComplexity int) int
Title func(childComplexity int) int
Type func(childComplexity int) int
VideoMetadata func(childComplexity int) int
VideoWeb func(childComplexity int) int
}
MediaDownload struct {
MediaURL func(childComplexity int) int
Title func(childComplexity int) int
}
MediaEXIF struct {
Aperture func(childComplexity int) int
Camera func(childComplexity int) int
Coordinates func(childComplexity int) int
DateShotWithOffset func(childComplexity int) int
Description func(childComplexity int) int
Exposure func(childComplexity int) int
ExposureProgram func(childComplexity int) int
Flash func(childComplexity int) int
FocalLength func(childComplexity int) int
ID func(childComplexity int) int
Iso func(childComplexity int) int
Lens func(childComplexity int) int
Maker func(childComplexity int) int
Media func(childComplexity int) int
}
MediaURL struct {
FileSize func(childComplexity int) int
Height func(childComplexity int) int
URL func(childComplexity int) int
Width func(childComplexity int) int
}
Mutation struct {
AuthorizeUser func(childComplexity int, username string, password string) int
ChangeUserPreferences func(childComplexity int, language *string) int
CombineFaceGroups func(childComplexity int, destinationFaceGroupID int, sourceFaceGroupIDs []int) int
CreateUser func(childComplexity int, username string, password *string, admin bool) int
DeleteShareToken func(childComplexity int, token string) int
DeleteUser func(childComplexity int, id int) int
DetachImageFaces func(childComplexity int, imageFaceIDs []int) int
FavoriteMedia func(childComplexity int, mediaID int, favorite bool) int
InitialSetupWizard func(childComplexity int, username string, password string, rootPath string) int
MoveImageFaces func(childComplexity int, imageFaceIDs []int, destinationFaceGroupID int) int
ProtectShareToken func(childComplexity int, token string, password *string) int
RecognizeUnlabeledFaces func(childComplexity int) int
ResetAlbumCover func(childComplexity int, albumID int) int
ScanAll func(childComplexity int) int
ScanUser func(childComplexity int, userID int) int
SetAlbumCover func(childComplexity int, coverID int) int
SetExpireShareToken func(childComplexity int, token string, expire *time.Time) int
SetFaceGroupLabel func(childComplexity int, faceGroupID int, label *string) int
SetPeriodicScanInterval func(childComplexity int, interval int) int
SetScannerConcurrentWorkers func(childComplexity int, workers int) int
ShareAlbum func(childComplexity int, albumID int, expire *time.Time, password *string) int
ShareMedia func(childComplexity int, mediaID int, expire *time.Time, password *string) int
UpdateUser func(childComplexity int, id int, username *string, password *string, admin *bool) int
UserAddRootPath func(childComplexity int, id int, rootPath string) int
UserRemoveRootAlbum func(childComplexity int, userID int, albumID int) int
}
Notification struct {
Content func(childComplexity int) int
Header func(childComplexity int) int
Key func(childComplexity int) int
Negative func(childComplexity int) int
Positive func(childComplexity int) int
Progress func(childComplexity int) int
Timeout func(childComplexity int) int
Type func(childComplexity int) int
}
Query struct {
Album func(childComplexity int, id int, tokenCredentials *models.ShareTokenCredentials) int
FaceGroup func(childComplexity int, id int) int
MapboxToken func(childComplexity int) int
Media func(childComplexity int, id int, tokenCredentials *models.ShareTokenCredentials) int
MediaList func(childComplexity int, ids []int) int
MyAlbums func(childComplexity int, order *models.Ordering, paginate *models.Pagination, onlyRoot *bool, showEmpty *bool, onlyWithFavorites *bool) int
MyFaceGroups func(childComplexity int, paginate *models.Pagination) int
MyMedia func(childComplexity int, order *models.Ordering, paginate *models.Pagination) int
MyMediaGeoJSON func(childComplexity int) int
MyTimeline func(childComplexity int, paginate *models.Pagination, onlyFavorites *bool, fromDate *time.Time) int
MyUser func(childComplexity int) int
MyUserPreferences func(childComplexity int) int
Search func(childComplexity int, query string, limitMedia *int, limitAlbums *int) int
ShareToken func(childComplexity int, credentials models.ShareTokenCredentials) int
ShareTokenValidatePassword func(childComplexity int, credentials models.ShareTokenCredentials) int
SiteInfo func(childComplexity int) int
User func(childComplexity int, order *models.Ordering, paginate *models.Pagination) int
}
ScannerResult struct {
Finished func(childComplexity int) int
Message func(childComplexity int) int
Progress func(childComplexity int) int
Success func(childComplexity int) int
}
SearchResult struct {
Albums func(childComplexity int) int
Media func(childComplexity int) int
Query func(childComplexity int) int
}
ShareToken struct {
Album func(childComplexity int) int
Expire func(childComplexity int) int
HasPassword func(childComplexity int) int
ID func(childComplexity int) int
Media func(childComplexity int) int
Owner func(childComplexity int) int
Token func(childComplexity int) int
}
SiteInfo struct {
ConcurrentWorkers func(childComplexity int) int
FaceDetectionEnabled func(childComplexity int) int
InitialSetup func(childComplexity int) int
PeriodicScanInterval func(childComplexity int) int
}
Subscription struct {
Notification func(childComplexity int) int
}
TimelineGroup struct {
Album func(childComplexity int) int
Date func(childComplexity int) int
Media func(childComplexity int) int
MediaTotal func(childComplexity int) int
}
User struct {
Admin func(childComplexity int) int
Albums func(childComplexity int) int
ID func(childComplexity int) int
RootAlbums func(childComplexity int) int
Username func(childComplexity int) int
}
UserPreferences struct {
ID func(childComplexity int) int
Language func(childComplexity int) int
}
VideoMetadata struct {
Audio func(childComplexity int) int
Bitrate func(childComplexity int) int
Codec func(childComplexity int) int
ColorProfile func(childComplexity int) int
Duration func(childComplexity int) int
Framerate func(childComplexity int) int
Height func(childComplexity int) int
ID func(childComplexity int) int
Media func(childComplexity int) int
Width func(childComplexity int) int
}
}
type AlbumResolver interface {
Media(ctx context.Context, obj *models.Album, order *models.Ordering, paginate *models.Pagination, onlyFavorites *bool) ([]*models.Media, error)
SubAlbums(ctx context.Context, obj *models.Album, order *models.Ordering, paginate *models.Pagination) ([]*models.Album, error)
Owner(ctx context.Context, obj *models.Album) (*models.User, error)
Thumbnail(ctx context.Context, obj *models.Album) (*models.Media, error)
Path(ctx context.Context, obj *models.Album) ([]*models.Album, error)
Shares(ctx context.Context, obj *models.Album) ([]*models.ShareToken, error)
}
type FaceGroupResolver interface {
ImageFaces(ctx context.Context, obj *models.FaceGroup, paginate *models.Pagination) ([]*models.ImageFace, error)
ImageFaceCount(ctx context.Context, obj *models.FaceGroup) (int, error)
}
type ImageFaceResolver interface {
Media(ctx context.Context, obj *models.ImageFace) (*models.Media, error)
FaceGroup(ctx context.Context, obj *models.ImageFace) (*models.FaceGroup, error)
}
type MediaResolver interface {
Thumbnail(ctx context.Context, obj *models.Media) (*models.MediaURL, error)
HighRes(ctx context.Context, obj *models.Media) (*models.MediaURL, error)
VideoWeb(ctx context.Context, obj *models.Media) (*models.MediaURL, error)
Album(ctx context.Context, obj *models.Media) (*models.Album, error)
Exif(ctx context.Context, obj *models.Media) (*models.MediaEXIF, error)
Favorite(ctx context.Context, obj *models.Media) (bool, error)
Type(ctx context.Context, obj *models.Media) (models.MediaType, error)
Shares(ctx context.Context, obj *models.Media) ([]*models.ShareToken, error)
Downloads(ctx context.Context, obj *models.Media) ([]*models.MediaDownload, error)
Faces(ctx context.Context, obj *models.Media) ([]*models.ImageFace, error)
}
type MutationResolver interface {
ResetAlbumCover(ctx context.Context, albumID int) (*models.Album, error)
SetAlbumCover(ctx context.Context, coverID int) (*models.Album, error)
SetFaceGroupLabel(ctx context.Context, faceGroupID int, label *string) (*models.FaceGroup, error)
CombineFaceGroups(ctx context.Context, destinationFaceGroupID int, sourceFaceGroupIDs []int) (*models.FaceGroup, error)
MoveImageFaces(ctx context.Context, imageFaceIDs []int, destinationFaceGroupID int) (*models.FaceGroup, error)
RecognizeUnlabeledFaces(ctx context.Context) ([]*models.ImageFace, error)
DetachImageFaces(ctx context.Context, imageFaceIDs []int) (*models.FaceGroup, error)
FavoriteMedia(ctx context.Context, mediaID int, favorite bool) (*models.Media, error)
ScanAll(ctx context.Context) (*models.ScannerResult, error)
ScanUser(ctx context.Context, userID int) (*models.ScannerResult, error)
SetPeriodicScanInterval(ctx context.Context, interval int) (int, error)
SetScannerConcurrentWorkers(ctx context.Context, workers int) (int, error)
ShareAlbum(ctx context.Context, albumID int, expire *time.Time, password *string) (*models.ShareToken, error)
ShareMedia(ctx context.Context, mediaID int, expire *time.Time, password *string) (*models.ShareToken, error)
DeleteShareToken(ctx context.Context, token string) (*models.ShareToken, error)
ProtectShareToken(ctx context.Context, token string, password *string) (*models.ShareToken, error)
SetExpireShareToken(ctx context.Context, token string, expire *time.Time) (*models.ShareToken, error)
AuthorizeUser(ctx context.Context, username string, password string) (*models.AuthorizeResult, error)
InitialSetupWizard(ctx context.Context, username string, password string, rootPath string) (*models.AuthorizeResult, error)
UpdateUser(ctx context.Context, id int, username *string, password *string, admin *bool) (*models.User, error)
CreateUser(ctx context.Context, username string, password *string, admin bool) (*models.User, error)
DeleteUser(ctx context.Context, id int) (*models.User, error)
UserAddRootPath(ctx context.Context, id int, rootPath string) (*models.Album, error)
UserRemoveRootAlbum(ctx context.Context, userID int, albumID int) (*models.Album, error)
ChangeUserPreferences(ctx context.Context, language *string) (*models.UserPreferences, error)
}
type QueryResolver interface {
MyAlbums(ctx context.Context, order *models.Ordering, paginate *models.Pagination, onlyRoot *bool, showEmpty *bool, onlyWithFavorites *bool) ([]*models.Album, error)
Album(ctx context.Context, id int, tokenCredentials *models.ShareTokenCredentials) (*models.Album, error)
MyFaceGroups(ctx context.Context, paginate *models.Pagination) ([]*models.FaceGroup, error)
FaceGroup(ctx context.Context, id int) (*models.FaceGroup, error)
MyMedia(ctx context.Context, order *models.Ordering, paginate *models.Pagination) ([]*models.Media, error)
Media(ctx context.Context, id int, tokenCredentials *models.ShareTokenCredentials) (*models.Media, error)
MediaList(ctx context.Context, ids []int) ([]*models.Media, error)
MyMediaGeoJSON(ctx context.Context) (any, error)
MapboxToken(ctx context.Context) (*string, error)
Search(ctx context.Context, query string, limitMedia *int, limitAlbums *int) (*models.SearchResult, error)
ShareToken(ctx context.Context, credentials models.ShareTokenCredentials) (*models.ShareToken, error)
ShareTokenValidatePassword(ctx context.Context, credentials models.ShareTokenCredentials) (bool, error)
SiteInfo(ctx context.Context) (*models.SiteInfo, error)
MyTimeline(ctx context.Context, paginate *models.Pagination, onlyFavorites *bool, fromDate *time.Time) ([]*models.Media, error)
User(ctx context.Context, order *models.Ordering, paginate *models.Pagination) ([]*models.User, error)
MyUser(ctx context.Context) (*models.User, error)
MyUserPreferences(ctx context.Context) (*models.UserPreferences, error)
}
type ShareTokenResolver interface {
HasPassword(ctx context.Context, obj *models.ShareToken) (bool, error)
}
type SiteInfoResolver interface {
FaceDetectionEnabled(ctx context.Context, obj *models.SiteInfo) (bool, error)
}
type SubscriptionResolver interface {
Notification(ctx context.Context) (<-chan *models.Notification, error)
}
type UserResolver interface {
Albums(ctx context.Context, obj *models.User) ([]*models.Album, error)
RootAlbums(ctx context.Context, obj *models.User) ([]*models.Album, error)
}
type executableSchema graphql.ExecutableSchemaState[ResolverRoot, DirectiveRoot, ComplexityRoot]
func (e *executableSchema) Schema() *ast.Schema {
if e.SchemaData != nil {
return e.SchemaData
}
return parsedSchema
}
func (e *executableSchema) Complexity(ctx context.Context, typeName, field string, childComplexity int, rawArgs map[string]any) (int, bool) {
ec := newExecutionContext(nil, e, nil)
_ = ec
switch typeName + "." + field {
case "Album.filePath":
if e.ComplexityRoot.Album.FilePath == nil {
break
}
return e.ComplexityRoot.Album.FilePath(childComplexity), true
case "Album.id":
if e.ComplexityRoot.Album.ID == nil {
break
}
return e.ComplexityRoot.Album.ID(childComplexity), true
case "Album.media":
if e.ComplexityRoot.Album.Media == nil {
break
}
args, err := ec.field_Album_media_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Album.Media(childComplexity, args["order"].(*models.Ordering), args["paginate"].(*models.Pagination), args["onlyFavorites"].(*bool)), true
case "Album.owner":
if e.ComplexityRoot.Album.Owner == nil {
break
}
return e.ComplexityRoot.Album.Owner(childComplexity), true
case "Album.parentAlbum":
if e.ComplexityRoot.Album.ParentAlbum == nil {
break
}
return e.ComplexityRoot.Album.ParentAlbum(childComplexity), true
case "Album.path":
if e.ComplexityRoot.Album.Path == nil {
break
}
return e.ComplexityRoot.Album.Path(childComplexity), true
case "Album.shares":
if e.ComplexityRoot.Album.Shares == nil {
break
}
return e.ComplexityRoot.Album.Shares(childComplexity), true
case "Album.subAlbums":
if e.ComplexityRoot.Album.SubAlbums == nil {
break
}
args, err := ec.field_Album_subAlbums_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Album.SubAlbums(childComplexity, args["order"].(*models.Ordering), args["paginate"].(*models.Pagination)), true
case "Album.thumbnail":
if e.ComplexityRoot.Album.Thumbnail == nil {
break
}
return e.ComplexityRoot.Album.Thumbnail(childComplexity), true
case "Album.title":
if e.ComplexityRoot.Album.Title == nil {
break
}
return e.ComplexityRoot.Album.Title(childComplexity), true
case "AuthorizeResult.status":
if e.ComplexityRoot.AuthorizeResult.Status == nil {
break
}
return e.ComplexityRoot.AuthorizeResult.Status(childComplexity), true
case "AuthorizeResult.success":
if e.ComplexityRoot.AuthorizeResult.Success == nil {
break
}
return e.ComplexityRoot.AuthorizeResult.Success(childComplexity), true
case "AuthorizeResult.token":
if e.ComplexityRoot.AuthorizeResult.Token == nil {
break
}
return e.ComplexityRoot.AuthorizeResult.Token(childComplexity), true
case "Coordinates.latitude":
if e.ComplexityRoot.Coordinates.Latitude == nil {
break
}
return e.ComplexityRoot.Coordinates.Latitude(childComplexity), true
case "Coordinates.longitude":
if e.ComplexityRoot.Coordinates.Longitude == nil {
break
}
return e.ComplexityRoot.Coordinates.Longitude(childComplexity), true
case "FaceGroup.id":
if e.ComplexityRoot.FaceGroup.ID == nil {
break
}
return e.ComplexityRoot.FaceGroup.ID(childComplexity), true
case "FaceGroup.imageFaceCount":
if e.ComplexityRoot.FaceGroup.ImageFaceCount == nil {
break
}
return e.ComplexityRoot.FaceGroup.ImageFaceCount(childComplexity), true
case "FaceGroup.imageFaces":
if e.ComplexityRoot.FaceGroup.ImageFaces == nil {
break
}
args, err := ec.field_FaceGroup_imageFaces_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.FaceGroup.ImageFaces(childComplexity, args["paginate"].(*models.Pagination)), true
case "FaceGroup.label":
if e.ComplexityRoot.FaceGroup.Label == nil {
break
}
return e.ComplexityRoot.FaceGroup.Label(childComplexity), true
case "FaceRectangle.maxX":
if e.ComplexityRoot.FaceRectangle.MaxX == nil {
break
}
return e.ComplexityRoot.FaceRectangle.MaxX(childComplexity), true
case "FaceRectangle.maxY":
if e.ComplexityRoot.FaceRectangle.MaxY == nil {
break
}
return e.ComplexityRoot.FaceRectangle.MaxY(childComplexity), true
case "FaceRectangle.minX":
if e.ComplexityRoot.FaceRectangle.MinX == nil {
break
}
return e.ComplexityRoot.FaceRectangle.MinX(childComplexity), true
case "FaceRectangle.minY":
if e.ComplexityRoot.FaceRectangle.MinY == nil {
break
}
return e.ComplexityRoot.FaceRectangle.MinY(childComplexity), true
case "ImageFace.faceGroup":
if e.ComplexityRoot.ImageFace.FaceGroup == nil {
break
}
return e.ComplexityRoot.ImageFace.FaceGroup(childComplexity), true
case "ImageFace.id":
if e.ComplexityRoot.ImageFace.ID == nil {
break
}
return e.ComplexityRoot.ImageFace.ID(childComplexity), true
case "ImageFace.media":
if e.ComplexityRoot.ImageFace.Media == nil {
break
}
return e.ComplexityRoot.ImageFace.Media(childComplexity), true
case "ImageFace.rectangle":
if e.ComplexityRoot.ImageFace.Rectangle == nil {
break
}
return e.ComplexityRoot.ImageFace.Rectangle(childComplexity), true
case "Media.album":
if e.ComplexityRoot.Media.Album == nil {
break
}
return e.ComplexityRoot.Media.Album(childComplexity), true
case "Media.blurhash":
if e.ComplexityRoot.Media.Blurhash == nil {
break
}
return e.ComplexityRoot.Media.Blurhash(childComplexity), true
case "Media.date":
if e.ComplexityRoot.Media.Date == nil {
break
}
return e.ComplexityRoot.Media.Date(childComplexity), true
case "Media.downloads":
if e.ComplexityRoot.Media.Downloads == nil {
break
}
return e.ComplexityRoot.Media.Downloads(childComplexity), true
case "Media.exif":
if e.ComplexityRoot.Media.Exif == nil {
break
}
return e.ComplexityRoot.Media.Exif(childComplexity), true
case "Media.faces":
if e.ComplexityRoot.Media.Faces == nil {
break
}
return e.ComplexityRoot.Media.Faces(childComplexity), true
case "Media.favorite":
if e.ComplexityRoot.Media.Favorite == nil {
break
}
return e.ComplexityRoot.Media.Favorite(childComplexity), true
case "Media.highRes":
if e.ComplexityRoot.Media.HighRes == nil {
break
}
return e.ComplexityRoot.Media.HighRes(childComplexity), true
case "Media.id":
if e.ComplexityRoot.Media.ID == nil {
break
}
return e.ComplexityRoot.Media.ID(childComplexity), true
case "Media.path":
if e.ComplexityRoot.Media.Path == nil {
break
}
return e.ComplexityRoot.Media.Path(childComplexity), true
case "Media.shares":
if e.ComplexityRoot.Media.Shares == nil {
break
}
return e.ComplexityRoot.Media.Shares(childComplexity), true
case "Media.thumbnail":
if e.ComplexityRoot.Media.Thumbnail == nil {
break
}
return e.ComplexityRoot.Media.Thumbnail(childComplexity), true
case "Media.title":
if e.ComplexityRoot.Media.Title == nil {
break
}
return e.ComplexityRoot.Media.Title(childComplexity), true
case "Media.type":
if e.ComplexityRoot.Media.Type == nil {
break
}
return e.ComplexityRoot.Media.Type(childComplexity), true
case "Media.videoMetadata":
if e.ComplexityRoot.Media.VideoMetadata == nil {
break
}
return e.ComplexityRoot.Media.VideoMetadata(childComplexity), true
case "Media.videoWeb":
if e.ComplexityRoot.Media.VideoWeb == nil {
break
}
return e.ComplexityRoot.Media.VideoWeb(childComplexity), true
case "MediaDownload.mediaUrl":
if e.ComplexityRoot.MediaDownload.MediaURL == nil {
break
}
return e.ComplexityRoot.MediaDownload.MediaURL(childComplexity), true
case "MediaDownload.title":
if e.ComplexityRoot.MediaDownload.Title == nil {
break
}
return e.ComplexityRoot.MediaDownload.Title(childComplexity), true
case "MediaEXIF.aperture":
if e.ComplexityRoot.MediaEXIF.Aperture == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Aperture(childComplexity), true
case "MediaEXIF.camera":
if e.ComplexityRoot.MediaEXIF.Camera == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Camera(childComplexity), true
case "MediaEXIF.coordinates":
if e.ComplexityRoot.MediaEXIF.Coordinates == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Coordinates(childComplexity), true
case "MediaEXIF.dateShot":
if e.ComplexityRoot.MediaEXIF.DateShotWithOffset == nil {
break
}
return e.ComplexityRoot.MediaEXIF.DateShotWithOffset(childComplexity), true
case "MediaEXIF.description":
if e.ComplexityRoot.MediaEXIF.Description == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Description(childComplexity), true
case "MediaEXIF.exposure":
if e.ComplexityRoot.MediaEXIF.Exposure == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Exposure(childComplexity), true
case "MediaEXIF.exposureProgram":
if e.ComplexityRoot.MediaEXIF.ExposureProgram == nil {
break
}
return e.ComplexityRoot.MediaEXIF.ExposureProgram(childComplexity), true
case "MediaEXIF.flash":
if e.ComplexityRoot.MediaEXIF.Flash == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Flash(childComplexity), true
case "MediaEXIF.focalLength":
if e.ComplexityRoot.MediaEXIF.FocalLength == nil {
break
}
return e.ComplexityRoot.MediaEXIF.FocalLength(childComplexity), true
case "MediaEXIF.id":
if e.ComplexityRoot.MediaEXIF.ID == nil {
break
}
return e.ComplexityRoot.MediaEXIF.ID(childComplexity), true
case "MediaEXIF.iso":
if e.ComplexityRoot.MediaEXIF.Iso == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Iso(childComplexity), true
case "MediaEXIF.lens":
if e.ComplexityRoot.MediaEXIF.Lens == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Lens(childComplexity), true
case "MediaEXIF.maker":
if e.ComplexityRoot.MediaEXIF.Maker == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Maker(childComplexity), true
case "MediaEXIF.media":
if e.ComplexityRoot.MediaEXIF.Media == nil {
break
}
return e.ComplexityRoot.MediaEXIF.Media(childComplexity), true
case "MediaURL.fileSize":
if e.ComplexityRoot.MediaURL.FileSize == nil {
break
}
return e.ComplexityRoot.MediaURL.FileSize(childComplexity), true
case "MediaURL.height":
if e.ComplexityRoot.MediaURL.Height == nil {
break
}
return e.ComplexityRoot.MediaURL.Height(childComplexity), true
case "MediaURL.url":
if e.ComplexityRoot.MediaURL.URL == nil {
break
}
return e.ComplexityRoot.MediaURL.URL(childComplexity), true
case "MediaURL.width":
if e.ComplexityRoot.MediaURL.Width == nil {
break
}
return e.ComplexityRoot.MediaURL.Width(childComplexity), true
case "Mutation.authorizeUser":
if e.ComplexityRoot.Mutation.AuthorizeUser == nil {
break
}
args, err := ec.field_Mutation_authorizeUser_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.AuthorizeUser(childComplexity, args["username"].(string), args["password"].(string)), true
case "Mutation.changeUserPreferences":
if e.ComplexityRoot.Mutation.ChangeUserPreferences == nil {
break
}
args, err := ec.field_Mutation_changeUserPreferences_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.ChangeUserPreferences(childComplexity, args["language"].(*string)), true
case "Mutation.combineFaceGroups":
if e.ComplexityRoot.Mutation.CombineFaceGroups == nil {
break
}
args, err := ec.field_Mutation_combineFaceGroups_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.CombineFaceGroups(childComplexity, args["destinationFaceGroupID"].(int), args["sourceFaceGroupIDs"].([]int)), true
case "Mutation.createUser":
if e.ComplexityRoot.Mutation.CreateUser == nil {
break
}
args, err := ec.field_Mutation_createUser_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.CreateUser(childComplexity, args["username"].(string), args["password"].(*string), args["admin"].(bool)), true
case "Mutation.deleteShareToken":
if e.ComplexityRoot.Mutation.DeleteShareToken == nil {
break
}
args, err := ec.field_Mutation_deleteShareToken_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.DeleteShareToken(childComplexity, args["token"].(string)), true
case "Mutation.deleteUser":
if e.ComplexityRoot.Mutation.DeleteUser == nil {
break
}
args, err := ec.field_Mutation_deleteUser_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.DeleteUser(childComplexity, args["id"].(int)), true
case "Mutation.detachImageFaces":
if e.ComplexityRoot.Mutation.DetachImageFaces == nil {
break
}
args, err := ec.field_Mutation_detachImageFaces_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.DetachImageFaces(childComplexity, args["imageFaceIDs"].([]int)), true
case "Mutation.favoriteMedia":
if e.ComplexityRoot.Mutation.FavoriteMedia == nil {
break
}
args, err := ec.field_Mutation_favoriteMedia_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.FavoriteMedia(childComplexity, args["mediaId"].(int), args["favorite"].(bool)), true
case "Mutation.initialSetupWizard":
if e.ComplexityRoot.Mutation.InitialSetupWizard == nil {
break
}
args, err := ec.field_Mutation_initialSetupWizard_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.InitialSetupWizard(childComplexity, args["username"].(string), args["password"].(string), args["rootPath"].(string)), true
case "Mutation.moveImageFaces":
if e.ComplexityRoot.Mutation.MoveImageFaces == nil {
break
}
args, err := ec.field_Mutation_moveImageFaces_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.MoveImageFaces(childComplexity, args["imageFaceIDs"].([]int), args["destinationFaceGroupID"].(int)), true
case "Mutation.protectShareToken":
if e.ComplexityRoot.Mutation.ProtectShareToken == nil {
break
}
args, err := ec.field_Mutation_protectShareToken_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.ProtectShareToken(childComplexity, args["token"].(string), args["password"].(*string)), true
case "Mutation.recognizeUnlabeledFaces":
if e.ComplexityRoot.Mutation.RecognizeUnlabeledFaces == nil {
break
}
return e.ComplexityRoot.Mutation.RecognizeUnlabeledFaces(childComplexity), true
case "Mutation.resetAlbumCover":
if e.ComplexityRoot.Mutation.ResetAlbumCover == nil {
break
}
args, err := ec.field_Mutation_resetAlbumCover_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.ResetAlbumCover(childComplexity, args["albumID"].(int)), true
case "Mutation.scanAll":
if e.ComplexityRoot.Mutation.ScanAll == nil {
break
}
return e.ComplexityRoot.Mutation.ScanAll(childComplexity), true
case "Mutation.scanUser":
if e.ComplexityRoot.Mutation.ScanUser == nil {
break
}
args, err := ec.field_Mutation_scanUser_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.ScanUser(childComplexity, args["userId"].(int)), true
case "Mutation.setAlbumCover":
if e.ComplexityRoot.Mutation.SetAlbumCover == nil {
break
}
args, err := ec.field_Mutation_setAlbumCover_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.SetAlbumCover(childComplexity, args["coverID"].(int)), true
case "Mutation.setExpireShareToken":
if e.ComplexityRoot.Mutation.SetExpireShareToken == nil {
break
}
args, err := ec.field_Mutation_setExpireShareToken_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.SetExpireShareToken(childComplexity, args["token"].(string), args["expire"].(*time.Time)), true
case "Mutation.setFaceGroupLabel":
if e.ComplexityRoot.Mutation.SetFaceGroupLabel == nil {
break
}
args, err := ec.field_Mutation_setFaceGroupLabel_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.SetFaceGroupLabel(childComplexity, args["faceGroupID"].(int), args["label"].(*string)), true
case "Mutation.setPeriodicScanInterval":
if e.ComplexityRoot.Mutation.SetPeriodicScanInterval == nil {
break
}
args, err := ec.field_Mutation_setPeriodicScanInterval_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.SetPeriodicScanInterval(childComplexity, args["interval"].(int)), true
case "Mutation.setScannerConcurrentWorkers":
if e.ComplexityRoot.Mutation.SetScannerConcurrentWorkers == nil {
break
}
args, err := ec.field_Mutation_setScannerConcurrentWorkers_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.SetScannerConcurrentWorkers(childComplexity, args["workers"].(int)), true
case "Mutation.shareAlbum":
if e.ComplexityRoot.Mutation.ShareAlbum == nil {
break
}
args, err := ec.field_Mutation_shareAlbum_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.ShareAlbum(childComplexity, args["albumId"].(int), args["expire"].(*time.Time), args["password"].(*string)), true
case "Mutation.shareMedia":
if e.ComplexityRoot.Mutation.ShareMedia == nil {
break
}
args, err := ec.field_Mutation_shareMedia_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.ShareMedia(childComplexity, args["mediaId"].(int), args["expire"].(*time.Time), args["password"].(*string)), true
case "Mutation.updateUser":
if e.ComplexityRoot.Mutation.UpdateUser == nil {
break
}
args, err := ec.field_Mutation_updateUser_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.UpdateUser(childComplexity, args["id"].(int), args["username"].(*string), args["password"].(*string), args["admin"].(*bool)), true
case "Mutation.userAddRootPath":
if e.ComplexityRoot.Mutation.UserAddRootPath == nil {
break
}
args, err := ec.field_Mutation_userAddRootPath_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.UserAddRootPath(childComplexity, args["id"].(int), args["rootPath"].(string)), true
case "Mutation.userRemoveRootAlbum":
if e.ComplexityRoot.Mutation.UserRemoveRootAlbum == nil {
break
}
args, err := ec.field_Mutation_userRemoveRootAlbum_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Mutation.UserRemoveRootAlbum(childComplexity, args["userId"].(int), args["albumId"].(int)), true
case "Notification.content":
if e.ComplexityRoot.Notification.Content == nil {
break
}
return e.ComplexityRoot.Notification.Content(childComplexity), true
case "Notification.header":
if e.ComplexityRoot.Notification.Header == nil {
break
}
return e.ComplexityRoot.Notification.Header(childComplexity), true
case "Notification.key":
if e.ComplexityRoot.Notification.Key == nil {
break
}
return e.ComplexityRoot.Notification.Key(childComplexity), true
case "Notification.negative":
if e.ComplexityRoot.Notification.Negative == nil {
break
}
return e.ComplexityRoot.Notification.Negative(childComplexity), true
case "Notification.positive":
if e.ComplexityRoot.Notification.Positive == nil {
break
}
return e.ComplexityRoot.Notification.Positive(childComplexity), true
case "Notification.progress":
if e.ComplexityRoot.Notification.Progress == nil {
break
}
return e.ComplexityRoot.Notification.Progress(childComplexity), true
case "Notification.timeout":
if e.ComplexityRoot.Notification.Timeout == nil {
break
}
return e.ComplexityRoot.Notification.Timeout(childComplexity), true
case "Notification.type":
if e.ComplexityRoot.Notification.Type == nil {
break
}
return e.ComplexityRoot.Notification.Type(childComplexity), true
case "Query.album":
if e.ComplexityRoot.Query.Album == nil {
break
}
args, err := ec.field_Query_album_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.Album(childComplexity, args["id"].(int), args["tokenCredentials"].(*models.ShareTokenCredentials)), true
case "Query.faceGroup":
if e.ComplexityRoot.Query.FaceGroup == nil {
break
}
args, err := ec.field_Query_faceGroup_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.FaceGroup(childComplexity, args["id"].(int)), true
case "Query.mapboxToken":
if e.ComplexityRoot.Query.MapboxToken == nil {
break
}
return e.ComplexityRoot.Query.MapboxToken(childComplexity), true
case "Query.media":
if e.ComplexityRoot.Query.Media == nil {
break
}
args, err := ec.field_Query_media_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.Media(childComplexity, args["id"].(int), args["tokenCredentials"].(*models.ShareTokenCredentials)), true
case "Query.mediaList":
if e.ComplexityRoot.Query.MediaList == nil {
break
}
args, err := ec.field_Query_mediaList_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.MediaList(childComplexity, args["ids"].([]int)), true
case "Query.myAlbums":
if e.ComplexityRoot.Query.MyAlbums == nil {
break
}
args, err := ec.field_Query_myAlbums_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.MyAlbums(childComplexity, args["order"].(*models.Ordering), args["paginate"].(*models.Pagination), args["onlyRoot"].(*bool), args["showEmpty"].(*bool), args["onlyWithFavorites"].(*bool)), true
case "Query.myFaceGroups":
if e.ComplexityRoot.Query.MyFaceGroups == nil {
break
}
args, err := ec.field_Query_myFaceGroups_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.MyFaceGroups(childComplexity, args["paginate"].(*models.Pagination)), true
case "Query.myMedia":
if e.ComplexityRoot.Query.MyMedia == nil {
break
}
args, err := ec.field_Query_myMedia_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.MyMedia(childComplexity, args["order"].(*models.Ordering), args["paginate"].(*models.Pagination)), true
case "Query.myMediaGeoJson":
if e.ComplexityRoot.Query.MyMediaGeoJSON == nil {
break
}
return e.ComplexityRoot.Query.MyMediaGeoJSON(childComplexity), true
case "Query.myTimeline":
if e.ComplexityRoot.Query.MyTimeline == nil {
break
}
args, err := ec.field_Query_myTimeline_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.MyTimeline(childComplexity, args["paginate"].(*models.Pagination), args["onlyFavorites"].(*bool), args["fromDate"].(*time.Time)), true
case "Query.myUser":
if e.ComplexityRoot.Query.MyUser == nil {
break
}
return e.ComplexityRoot.Query.MyUser(childComplexity), true
case "Query.myUserPreferences":
if e.ComplexityRoot.Query.MyUserPreferences == nil {
break
}
return e.ComplexityRoot.Query.MyUserPreferences(childComplexity), true
case "Query.search":
if e.ComplexityRoot.Query.Search == nil {
break
}
args, err := ec.field_Query_search_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.Search(childComplexity, args["query"].(string), args["limitMedia"].(*int), args["limitAlbums"].(*int)), true
case "Query.shareToken":
if e.ComplexityRoot.Query.ShareToken == nil {
break
}
args, err := ec.field_Query_shareToken_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.ShareToken(childComplexity, args["credentials"].(models.ShareTokenCredentials)), true
case "Query.shareTokenValidatePassword":
if e.ComplexityRoot.Query.ShareTokenValidatePassword == nil {
break
}
args, err := ec.field_Query_shareTokenValidatePassword_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.ShareTokenValidatePassword(childComplexity, args["credentials"].(models.ShareTokenCredentials)), true
case "Query.siteInfo":
if e.ComplexityRoot.Query.SiteInfo == nil {
break
}
return e.ComplexityRoot.Query.SiteInfo(childComplexity), true
case "Query.user":
if e.ComplexityRoot.Query.User == nil {
break
}
args, err := ec.field_Query_user_args(ctx, rawArgs)
if err != nil {
return 0, false
}
return e.ComplexityRoot.Query.User(childComplexity, args["order"].(*models.Ordering), args["paginate"].(*models.Pagination)), true
case "ScannerResult.finished":
if e.ComplexityRoot.ScannerResult.Finished == nil {
break
}
return e.ComplexityRoot.ScannerResult.Finished(childComplexity), true
case "ScannerResult.message":
if e.ComplexityRoot.ScannerResult.Message == nil {
break
}
return e.ComplexityRoot.ScannerResult.Message(childComplexity), true
case "ScannerResult.progress":
if e.ComplexityRoot.ScannerResult.Progress == nil {
break
}
return e.ComplexityRoot.ScannerResult.Progress(childComplexity), true
case "ScannerResult.success":
if e.ComplexityRoot.ScannerResult.Success == nil {
break
}
return e.ComplexityRoot.ScannerResult.Success(childComplexity), true
case "SearchResult.albums":
if e.ComplexityRoot.SearchResult.Albums == nil {
break
}
return e.ComplexityRoot.SearchResult.Albums(childComplexity), true
case "SearchResult.media":
if e.ComplexityRoot.SearchResult.Media == nil {
break
}
return e.ComplexityRoot.SearchResult.Media(childComplexity), true
case "SearchResult.query":
if e.ComplexityRoot.SearchResult.Query == nil {
break
}
return e.ComplexityRoot.SearchResult.Query(childComplexity), true
case "ShareToken.album":
if e.ComplexityRoot.ShareToken.Album == nil {
break
}
return e.ComplexityRoot.ShareToken.Album(childComplexity), true
case "ShareToken.expire":
if e.ComplexityRoot.ShareToken.Expire == nil {
break
}
return e.ComplexityRoot.ShareToken.Expire(childComplexity), true
case "ShareToken.hasPassword":
if e.ComplexityRoot.ShareToken.HasPassword == nil {
break
}
return e.ComplexityRoot.ShareToken.HasPassword(childComplexity), true
case "ShareToken.id":
if e.ComplexityRoot.ShareToken.ID == nil {
break
}
return e.ComplexityRoot.ShareToken.ID(childComplexity), true
case "ShareToken.media":
if e.ComplexityRoot.ShareToken.Media == nil {
break
}
return e.ComplexityRoot.ShareToken.Media(childComplexity), true
case "ShareToken.owner":
if e.ComplexityRoot.ShareToken.Owner == nil {
break
}
return e.ComplexityRoot.ShareToken.Owner(childComplexity), true
case "ShareToken.token":
if e.ComplexityRoot.ShareToken.Token == nil {
break
}
return e.ComplexityRoot.ShareToken.Token(childComplexity), true
case "SiteInfo.concurrentWorkers":
if e.ComplexityRoot.SiteInfo.ConcurrentWorkers == nil {
break
}
return e.ComplexityRoot.SiteInfo.ConcurrentWorkers(childComplexity), true
case "SiteInfo.faceDetectionEnabled":
if e.ComplexityRoot.SiteInfo.FaceDetectionEnabled == nil {
break
}
return e.ComplexityRoot.SiteInfo.FaceDetectionEnabled(childComplexity), true
case "SiteInfo.initialSetup":
if e.ComplexityRoot.SiteInfo.InitialSetup == nil {
break
}
return e.ComplexityRoot.SiteInfo.InitialSetup(childComplexity), true
case "SiteInfo.periodicScanInterval":
if e.ComplexityRoot.SiteInfo.PeriodicScanInterval == nil {
break
}
return e.ComplexityRoot.SiteInfo.PeriodicScanInterval(childComplexity), true
case "Subscription.notification":
if e.ComplexityRoot.Subscription.Notification == nil {
break
}
return e.ComplexityRoot.Subscription.Notification(childComplexity), true
case "TimelineGroup.album":
if e.ComplexityRoot.TimelineGroup.Album == nil {
break
}
return e.ComplexityRoot.TimelineGroup.Album(childComplexity), true
case "TimelineGroup.date":
if e.ComplexityRoot.TimelineGroup.Date == nil {
break
}
return e.ComplexityRoot.TimelineGroup.Date(childComplexity), true
case "TimelineGroup.media":
if e.ComplexityRoot.TimelineGroup.Media == nil {
break
}
return e.ComplexityRoot.TimelineGroup.Media(childComplexity), true
case "TimelineGroup.mediaTotal":
if e.ComplexityRoot.TimelineGroup.MediaTotal == nil {
break
}
return e.ComplexityRoot.TimelineGroup.MediaTotal(childComplexity), true
case "User.admin":
if e.ComplexityRoot.User.Admin == nil {
break
}
return e.ComplexityRoot.User.Admin(childComplexity), true
case "User.albums":
if e.ComplexityRoot.User.Albums == nil {
break
}
return e.ComplexityRoot.User.Albums(childComplexity), true
case "User.id":
if e.ComplexityRoot.User.ID == nil {
break
}
return e.ComplexityRoot.User.ID(childComplexity), true
case "User.rootAlbums":
if e.ComplexityRoot.User.RootAlbums == nil {
break
}
return e.ComplexityRoot.User.RootAlbums(childComplexity), true
case "User.username":
if e.ComplexityRoot.User.Username == nil {
break
}
return e.ComplexityRoot.User.Username(childComplexity), true
case "UserPreferences.id":
if e.ComplexityRoot.UserPreferences.ID == nil {
break
}
return e.ComplexityRoot.UserPreferences.ID(childComplexity), true
case "UserPreferences.language":
if e.ComplexityRoot.UserPreferences.Language == nil {
break
}
return e.ComplexityRoot.UserPreferences.Language(childComplexity), true
case "VideoMetadata.audio":
if e.ComplexityRoot.VideoMetadata.Audio == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Audio(childComplexity), true
case "VideoMetadata.bitrate":
if e.ComplexityRoot.VideoMetadata.Bitrate == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Bitrate(childComplexity), true
case "VideoMetadata.codec":
if e.ComplexityRoot.VideoMetadata.Codec == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Codec(childComplexity), true
case "VideoMetadata.colorProfile":
if e.ComplexityRoot.VideoMetadata.ColorProfile == nil {
break
}
return e.ComplexityRoot.VideoMetadata.ColorProfile(childComplexity), true
case "VideoMetadata.duration":
if e.ComplexityRoot.VideoMetadata.Duration == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Duration(childComplexity), true
case "VideoMetadata.framerate":
if e.ComplexityRoot.VideoMetadata.Framerate == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Framerate(childComplexity), true
case "VideoMetadata.height":
if e.ComplexityRoot.VideoMetadata.Height == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Height(childComplexity), true
case "VideoMetadata.id":
if e.ComplexityRoot.VideoMetadata.ID == nil {
break
}
return e.ComplexityRoot.VideoMetadata.ID(childComplexity), true
case "VideoMetadata.media":
if e.ComplexityRoot.VideoMetadata.Media == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Media(childComplexity), true
case "VideoMetadata.width":
if e.ComplexityRoot.VideoMetadata.Width == nil {
break
}
return e.ComplexityRoot.VideoMetadata.Width(childComplexity), true
}
return 0, false
}
func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler {
opCtx := graphql.GetOperationContext(ctx)
ec := newExecutionContext(opCtx, e, make(chan graphql.DeferredResult))
inputUnmarshalMap := graphql.BuildUnmarshalerMap(
ec.unmarshalInputOrdering,
ec.unmarshalInputPagination,
ec.unmarshalInputShareTokenCredentials,
)
first := true
switch opCtx.Operation.Operation {
case ast.Query:
return func(ctx context.Context) *graphql.Response {
var response graphql.Response
var data graphql.Marshaler
if first {
first = false
ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap)
data = ec._Query(ctx, opCtx.Operation.SelectionSet)
} else {
if atomic.LoadInt32(&ec.PendingDeferred) > 0 {
result := <-ec.DeferredResults
atomic.AddInt32(&ec.PendingDeferred, -1)
data = result.Result
response.Path = result.Path
response.Label = result.Label
response.Errors = result.Errors
} else {
return nil
}
}
var buf bytes.Buffer
data.MarshalGQL(&buf)
response.Data = buf.Bytes()
if atomic.LoadInt32(&ec.Deferred) > 0 {
hasNext := atomic.LoadInt32(&ec.PendingDeferred) > 0
response.HasNext = &hasNext
}
return &response
}
case ast.Mutation:
return func(ctx context.Context) *graphql.Response {
if !first {
return nil
}
first = false
ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap)
data := ec._Mutation(ctx, opCtx.Operation.SelectionSet)
var buf bytes.Buffer
data.MarshalGQL(&buf)
return &graphql.Response{
Data: buf.Bytes(),
}
}
case ast.Subscription:
next := ec._Subscription(ctx, opCtx.Operation.SelectionSet)
var buf bytes.Buffer
return func(ctx context.Context) *graphql.Response {
buf.Reset()
data := next(ctx)
if data == nil {
return nil
}
data.MarshalGQL(&buf)
return &graphql.Response{
Data: buf.Bytes(),
}
}
default:
return graphql.OneShot(graphql.ErrorResponse(ctx, "unsupported GraphQL operation"))
}
}
type executionContext struct {
*graphql.ExecutionContextState[ResolverRoot, DirectiveRoot, ComplexityRoot]
}
func newExecutionContext(
opCtx *graphql.OperationContext,
execSchema *executableSchema,
deferredResults chan graphql.DeferredResult,
) *executionContext {
return &executionContext{
ExecutionContextState: graphql.NewExecutionContextState[ResolverRoot, DirectiveRoot, ComplexityRoot](
opCtx,
(*graphql.ExecutableSchemaState[ResolverRoot, DirectiveRoot, ComplexityRoot])(execSchema),
parsedSchema,
deferredResults,
),
}
}
//go:embed "resolvers/album.graphql" "resolvers/faces.graphql" "resolvers/media.graphql" "resolvers/media_geo_json.graphql" "resolvers/notification.graphql" "resolvers/root.graphql" "resolvers/scanner.graphql" "resolvers/search.graphql" "resolvers/share_token.graphql" "resolvers/site_info.graphql" "resolvers/timeline.graphql" "resolvers/user.graphql"
var sourcesFS embed.FS
func sourceData(filename string) string {
data, err := sourcesFS.ReadFile(filename)
if err != nil {
panic(fmt.Sprintf("codegen problem: %s not available", filename))
}
return string(data)
}
var sources = []*ast.Source{
{Name: "resolvers/album.graphql", Input: sourceData("resolvers/album.graphql"), BuiltIn: false},
{Name: "resolvers/faces.graphql", Input: sourceData("resolvers/faces.graphql"), BuiltIn: false},
{Name: "resolvers/media.graphql", Input: sourceData("resolvers/media.graphql"), BuiltIn: false},
{Name: "resolvers/media_geo_json.graphql", Input: sourceData("resolvers/media_geo_json.graphql"), BuiltIn: false},
{Name: "resolvers/notification.graphql", Input: sourceData("resolvers/notification.graphql"), BuiltIn: false},
{Name: "resolvers/root.graphql", Input: sourceData("resolvers/root.graphql"), BuiltIn: false},
{Name: "resolvers/scanner.graphql", Input: sourceData("resolvers/scanner.graphql"), BuiltIn: false},
{Name: "resolvers/search.graphql", Input: sourceData("resolvers/search.graphql"), BuiltIn: false},
{Name: "resolvers/share_token.graphql", Input: sourceData("resolvers/share_token.graphql"), BuiltIn: false},
{Name: "resolvers/site_info.graphql", Input: sourceData("resolvers/site_info.graphql"), BuiltIn: false},
{Name: "resolvers/timeline.graphql", Input: sourceData("resolvers/timeline.graphql"), BuiltIn: false},
{Name: "resolvers/user.graphql", Input: sourceData("resolvers/user.graphql"), BuiltIn: false},
}
var parsedSchema = gqlparser.MustLoadSchema(sources...)
// childFields_* functions provide shared child field context lookups.
// Each function is generated once per unique object type, deduplicating the
// switch statements that were previously inlined in every fieldContext_* function.
func (ec *executionContext) childFields_Album(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_Album_id(ctx, field)
case "title":
return ec.fieldContext_Album_title(ctx, field)
case "media":
return ec.fieldContext_Album_media(ctx, field)
case "subAlbums":
return ec.fieldContext_Album_subAlbums(ctx, field)
case "parentAlbum":
return ec.fieldContext_Album_parentAlbum(ctx, field)
case "owner":
return ec.fieldContext_Album_owner(ctx, field)
case "filePath":
return ec.fieldContext_Album_filePath(ctx, field)
case "thumbnail":
return ec.fieldContext_Album_thumbnail(ctx, field)
case "path":
return ec.fieldContext_Album_path(ctx, field)
case "shares":
return ec.fieldContext_Album_shares(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type Album", field.Name)
}
func (ec *executionContext) childFields_AuthorizeResult(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "success":
return ec.fieldContext_AuthorizeResult_success(ctx, field)
case "status":
return ec.fieldContext_AuthorizeResult_status(ctx, field)
case "token":
return ec.fieldContext_AuthorizeResult_token(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type AuthorizeResult", field.Name)
}
func (ec *executionContext) childFields_Coordinates(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "latitude":
return ec.fieldContext_Coordinates_latitude(ctx, field)
case "longitude":
return ec.fieldContext_Coordinates_longitude(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type Coordinates", field.Name)
}
func (ec *executionContext) childFields_FaceGroup(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_FaceGroup_id(ctx, field)
case "label":
return ec.fieldContext_FaceGroup_label(ctx, field)
case "imageFaces":
return ec.fieldContext_FaceGroup_imageFaces(ctx, field)
case "imageFaceCount":
return ec.fieldContext_FaceGroup_imageFaceCount(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type FaceGroup", field.Name)
}
func (ec *executionContext) childFields_FaceRectangle(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "minX":
return ec.fieldContext_FaceRectangle_minX(ctx, field)
case "maxX":
return ec.fieldContext_FaceRectangle_maxX(ctx, field)
case "minY":
return ec.fieldContext_FaceRectangle_minY(ctx, field)
case "maxY":
return ec.fieldContext_FaceRectangle_maxY(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type FaceRectangle", field.Name)
}
func (ec *executionContext) childFields_ImageFace(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_ImageFace_id(ctx, field)
case "media":
return ec.fieldContext_ImageFace_media(ctx, field)
case "rectangle":
return ec.fieldContext_ImageFace_rectangle(ctx, field)
case "faceGroup":
return ec.fieldContext_ImageFace_faceGroup(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type ImageFace", field.Name)
}
func (ec *executionContext) childFields_Media(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_Media_id(ctx, field)
case "title":
return ec.fieldContext_Media_title(ctx, field)
case "path":
return ec.fieldContext_Media_path(ctx, field)
case "thumbnail":
return ec.fieldContext_Media_thumbnail(ctx, field)
case "highRes":
return ec.fieldContext_Media_highRes(ctx, field)
case "videoWeb":
return ec.fieldContext_Media_videoWeb(ctx, field)
case "album":
return ec.fieldContext_Media_album(ctx, field)
case "exif":
return ec.fieldContext_Media_exif(ctx, field)
case "videoMetadata":
return ec.fieldContext_Media_videoMetadata(ctx, field)
case "favorite":
return ec.fieldContext_Media_favorite(ctx, field)
case "type":
return ec.fieldContext_Media_type(ctx, field)
case "date":
return ec.fieldContext_Media_date(ctx, field)
case "blurhash":
return ec.fieldContext_Media_blurhash(ctx, field)
case "shares":
return ec.fieldContext_Media_shares(ctx, field)
case "downloads":
return ec.fieldContext_Media_downloads(ctx, field)
case "faces":
return ec.fieldContext_Media_faces(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type Media", field.Name)
}
func (ec *executionContext) childFields_MediaDownload(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "title":
return ec.fieldContext_MediaDownload_title(ctx, field)
case "mediaUrl":
return ec.fieldContext_MediaDownload_mediaUrl(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type MediaDownload", field.Name)
}
func (ec *executionContext) childFields_MediaEXIF(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_MediaEXIF_id(ctx, field)
case "media":
return ec.fieldContext_MediaEXIF_media(ctx, field)
case "description":
return ec.fieldContext_MediaEXIF_description(ctx, field)
case "camera":
return ec.fieldContext_MediaEXIF_camera(ctx, field)
case "maker":
return ec.fieldContext_MediaEXIF_maker(ctx, field)
case "lens":
return ec.fieldContext_MediaEXIF_lens(ctx, field)
case "dateShot":
return ec.fieldContext_MediaEXIF_dateShot(ctx, field)
case "exposure":
return ec.fieldContext_MediaEXIF_exposure(ctx, field)
case "aperture":
return ec.fieldContext_MediaEXIF_aperture(ctx, field)
case "iso":
return ec.fieldContext_MediaEXIF_iso(ctx, field)
case "focalLength":
return ec.fieldContext_MediaEXIF_focalLength(ctx, field)
case "flash":
return ec.fieldContext_MediaEXIF_flash(ctx, field)
case "exposureProgram":
return ec.fieldContext_MediaEXIF_exposureProgram(ctx, field)
case "coordinates":
return ec.fieldContext_MediaEXIF_coordinates(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type MediaEXIF", field.Name)
}
func (ec *executionContext) childFields_MediaURL(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "url":
return ec.fieldContext_MediaURL_url(ctx, field)
case "width":
return ec.fieldContext_MediaURL_width(ctx, field)
case "height":
return ec.fieldContext_MediaURL_height(ctx, field)
case "fileSize":
return ec.fieldContext_MediaURL_fileSize(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type MediaURL", field.Name)
}
func (ec *executionContext) childFields_Notification(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "key":
return ec.fieldContext_Notification_key(ctx, field)
case "type":
return ec.fieldContext_Notification_type(ctx, field)
case "header":
return ec.fieldContext_Notification_header(ctx, field)
case "content":
return ec.fieldContext_Notification_content(ctx, field)
case "progress":
return ec.fieldContext_Notification_progress(ctx, field)
case "positive":
return ec.fieldContext_Notification_positive(ctx, field)
case "negative":
return ec.fieldContext_Notification_negative(ctx, field)
case "timeout":
return ec.fieldContext_Notification_timeout(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type Notification", field.Name)
}
func (ec *executionContext) childFields_ScannerResult(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "finished":
return ec.fieldContext_ScannerResult_finished(ctx, field)
case "success":
return ec.fieldContext_ScannerResult_success(ctx, field)
case "progress":
return ec.fieldContext_ScannerResult_progress(ctx, field)
case "message":
return ec.fieldContext_ScannerResult_message(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type ScannerResult", field.Name)
}
func (ec *executionContext) childFields_SearchResult(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "query":
return ec.fieldContext_SearchResult_query(ctx, field)
case "albums":
return ec.fieldContext_SearchResult_albums(ctx, field)
case "media":
return ec.fieldContext_SearchResult_media(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type SearchResult", field.Name)
}
func (ec *executionContext) childFields_ShareToken(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_ShareToken_id(ctx, field)
case "token":
return ec.fieldContext_ShareToken_token(ctx, field)
case "owner":
return ec.fieldContext_ShareToken_owner(ctx, field)
case "expire":
return ec.fieldContext_ShareToken_expire(ctx, field)
case "hasPassword":
return ec.fieldContext_ShareToken_hasPassword(ctx, field)
case "album":
return ec.fieldContext_ShareToken_album(ctx, field)
case "media":
return ec.fieldContext_ShareToken_media(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type ShareToken", field.Name)
}
func (ec *executionContext) childFields_SiteInfo(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "initialSetup":
return ec.fieldContext_SiteInfo_initialSetup(ctx, field)
case "faceDetectionEnabled":
return ec.fieldContext_SiteInfo_faceDetectionEnabled(ctx, field)
case "periodicScanInterval":
return ec.fieldContext_SiteInfo_periodicScanInterval(ctx, field)
case "concurrentWorkers":
return ec.fieldContext_SiteInfo_concurrentWorkers(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type SiteInfo", field.Name)
}
func (ec *executionContext) childFields_User(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_User_id(ctx, field)
case "username":
return ec.fieldContext_User_username(ctx, field)
case "albums":
return ec.fieldContext_User_albums(ctx, field)
case "rootAlbums":
return ec.fieldContext_User_rootAlbums(ctx, field)
case "admin":
return ec.fieldContext_User_admin(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type User", field.Name)
}
func (ec *executionContext) childFields_UserPreferences(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_UserPreferences_id(ctx, field)
case "language":
return ec.fieldContext_UserPreferences_language(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type UserPreferences", field.Name)
}
func (ec *executionContext) childFields_VideoMetadata(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "id":
return ec.fieldContext_VideoMetadata_id(ctx, field)
case "media":
return ec.fieldContext_VideoMetadata_media(ctx, field)
case "width":
return ec.fieldContext_VideoMetadata_width(ctx, field)
case "height":
return ec.fieldContext_VideoMetadata_height(ctx, field)
case "duration":
return ec.fieldContext_VideoMetadata_duration(ctx, field)
case "codec":
return ec.fieldContext_VideoMetadata_codec(ctx, field)
case "framerate":
return ec.fieldContext_VideoMetadata_framerate(ctx, field)
case "bitrate":
return ec.fieldContext_VideoMetadata_bitrate(ctx, field)
case "colorProfile":
return ec.fieldContext_VideoMetadata_colorProfile(ctx, field)
case "audio":
return ec.fieldContext_VideoMetadata_audio(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type VideoMetadata", field.Name)
}
func (ec *executionContext) childFields___Directive(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "name":
return ec.fieldContext___Directive_name(ctx, field)
case "description":
return ec.fieldContext___Directive_description(ctx, field)
case "isRepeatable":
return ec.fieldContext___Directive_isRepeatable(ctx, field)
case "locations":
return ec.fieldContext___Directive_locations(ctx, field)
case "args":
return ec.fieldContext___Directive_args(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type __Directive", field.Name)
}
func (ec *executionContext) childFields___EnumValue(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "name":
return ec.fieldContext___EnumValue_name(ctx, field)
case "description":
return ec.fieldContext___EnumValue_description(ctx, field)
case "isDeprecated":
return ec.fieldContext___EnumValue_isDeprecated(ctx, field)
case "deprecationReason":
return ec.fieldContext___EnumValue_deprecationReason(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type __EnumValue", field.Name)
}
func (ec *executionContext) childFields___Field(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "name":
return ec.fieldContext___Field_name(ctx, field)
case "description":
return ec.fieldContext___Field_description(ctx, field)
case "args":
return ec.fieldContext___Field_args(ctx, field)
case "type":
return ec.fieldContext___Field_type(ctx, field)
case "isDeprecated":
return ec.fieldContext___Field_isDeprecated(ctx, field)
case "deprecationReason":
return ec.fieldContext___Field_deprecationReason(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type __Field", field.Name)
}
func (ec *executionContext) childFields___InputValue(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "name":
return ec.fieldContext___InputValue_name(ctx, field)
case "description":
return ec.fieldContext___InputValue_description(ctx, field)
case "type":
return ec.fieldContext___InputValue_type(ctx, field)
case "defaultValue":
return ec.fieldContext___InputValue_defaultValue(ctx, field)
case "isDeprecated":
return ec.fieldContext___InputValue_isDeprecated(ctx, field)
case "deprecationReason":
return ec.fieldContext___InputValue_deprecationReason(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name)
}
func (ec *executionContext) childFields___Schema(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "description":
return ec.fieldContext___Schema_description(ctx, field)
case "types":
return ec.fieldContext___Schema_types(ctx, field)
case "queryType":
return ec.fieldContext___Schema_queryType(ctx, field)
case "mutationType":
return ec.fieldContext___Schema_mutationType(ctx, field)
case "subscriptionType":
return ec.fieldContext___Schema_subscriptionType(ctx, field)
case "directives":
return ec.fieldContext___Schema_directives(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type __Schema", field.Name)
}
func (ec *executionContext) childFields___Type(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
switch field.Name {
case "kind":
return ec.fieldContext___Type_kind(ctx, field)
case "name":
return ec.fieldContext___Type_name(ctx, field)
case "description":
return ec.fieldContext___Type_description(ctx, field)
case "specifiedByURL":
return ec.fieldContext___Type_specifiedByURL(ctx, field)
case "fields":
return ec.fieldContext___Type_fields(ctx, field)
case "interfaces":
return ec.fieldContext___Type_interfaces(ctx, field)
case "possibleTypes":
return ec.fieldContext___Type_possibleTypes(ctx, field)
case "enumValues":
return ec.fieldContext___Type_enumValues(ctx, field)
case "inputFields":
return ec.fieldContext___Type_inputFields(ctx, field)
case "ofType":
return ec.fieldContext___Type_ofType(ctx, field)
case "isOneOf":
return ec.fieldContext___Type_isOneOf(ctx, field)
}
return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name)
}
// endregion ************************** generated!.gotpl **************************
// region ***************************** args.gotpl *****************************
func (ec *executionContext) field_Album_media_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "order",
func(ctx context.Context, v any) (*models.Ordering, error) {
return ec.unmarshalOOrdering2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrdering(ctx, v)
})
if err != nil {
return nil, err
}
args["order"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "onlyFavorites",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["onlyFavorites"] = arg2
return args, nil
}
func (ec *executionContext) field_Album_subAlbums_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "order",
func(ctx context.Context, v any) (*models.Ordering, error) {
return ec.unmarshalOOrdering2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrdering(ctx, v)
})
if err != nil {
return nil, err
}
args["order"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg1
return args, nil
}
func (ec *executionContext) field_FaceGroup_imageFaces_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_authorizeUser_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "username",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["username"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "password",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["password"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_changeUserPreferences_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "language",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["language"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_combineFaceGroups_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "destinationFaceGroupID",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["destinationFaceGroupID"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "sourceFaceGroupIDs",
func(ctx context.Context, v any) ([]int, error) {
return ec.unmarshalNID2ᚕintᚄ(ctx, v)
})
if err != nil {
return nil, err
}
args["sourceFaceGroupIDs"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_createUser_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "username",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["username"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "password",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["password"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "admin",
func(ctx context.Context, v any) (bool, error) {
return ec.unmarshalNBoolean2bool(ctx, v)
})
if err != nil {
return nil, err
}
args["admin"] = arg2
return args, nil
}
func (ec *executionContext) field_Mutation_deleteShareToken_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "token",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["token"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_deleteUser_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "id",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["id"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_detachImageFaces_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "imageFaceIDs",
func(ctx context.Context, v any) ([]int, error) {
return ec.unmarshalNID2ᚕintᚄ(ctx, v)
})
if err != nil {
return nil, err
}
args["imageFaceIDs"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_favoriteMedia_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "mediaId",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["mediaId"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "favorite",
func(ctx context.Context, v any) (bool, error) {
return ec.unmarshalNBoolean2bool(ctx, v)
})
if err != nil {
return nil, err
}
args["favorite"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_initialSetupWizard_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "username",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["username"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "password",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["password"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "rootPath",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["rootPath"] = arg2
return args, nil
}
func (ec *executionContext) field_Mutation_moveImageFaces_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "imageFaceIDs",
func(ctx context.Context, v any) ([]int, error) {
return ec.unmarshalNID2ᚕintᚄ(ctx, v)
})
if err != nil {
return nil, err
}
args["imageFaceIDs"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "destinationFaceGroupID",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["destinationFaceGroupID"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_protectShareToken_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "token",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["token"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "password",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["password"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_resetAlbumCover_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "albumID",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["albumID"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_scanUser_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "userId",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["userId"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_setAlbumCover_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "coverID",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["coverID"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_setExpireShareToken_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "token",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["token"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "expire",
func(ctx context.Context, v any) (*time.Time, error) {
return ec.unmarshalOTime2ᚖtimeᚐTime(ctx, v)
})
if err != nil {
return nil, err
}
args["expire"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_setFaceGroupLabel_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "faceGroupID",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["faceGroupID"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "label",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["label"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_setPeriodicScanInterval_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "interval",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNInt2int(ctx, v)
})
if err != nil {
return nil, err
}
args["interval"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_setScannerConcurrentWorkers_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "workers",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNInt2int(ctx, v)
})
if err != nil {
return nil, err
}
args["workers"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_shareAlbum_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "albumId",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["albumId"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "expire",
func(ctx context.Context, v any) (*time.Time, error) {
return ec.unmarshalOTime2ᚖtimeᚐTime(ctx, v)
})
if err != nil {
return nil, err
}
args["expire"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "password",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["password"] = arg2
return args, nil
}
func (ec *executionContext) field_Mutation_shareMedia_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "mediaId",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["mediaId"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "expire",
func(ctx context.Context, v any) (*time.Time, error) {
return ec.unmarshalOTime2ᚖtimeᚐTime(ctx, v)
})
if err != nil {
return nil, err
}
args["expire"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "password",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["password"] = arg2
return args, nil
}
func (ec *executionContext) field_Mutation_updateUser_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "id",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["id"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "username",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["username"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "password",
func(ctx context.Context, v any) (*string, error) {
return ec.unmarshalOString2ᚖstring(ctx, v)
})
if err != nil {
return nil, err
}
args["password"] = arg2
arg3, err := graphql.ProcessArgField(ctx, rawArgs, "admin",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["admin"] = arg3
return args, nil
}
func (ec *executionContext) field_Mutation_userAddRootPath_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "id",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["id"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "rootPath",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["rootPath"] = arg1
return args, nil
}
func (ec *executionContext) field_Mutation_userRemoveRootAlbum_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "userId",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["userId"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "albumId",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["albumId"] = arg1
return args, nil
}
func (ec *executionContext) field_Query___type_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "name",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["name"] = arg0
return args, nil
}
func (ec *executionContext) field_Query_album_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "id",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["id"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "tokenCredentials",
func(ctx context.Context, v any) (*models.ShareTokenCredentials, error) {
return ec.unmarshalOShareTokenCredentials2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenCredentials(ctx, v)
})
if err != nil {
return nil, err
}
args["tokenCredentials"] = arg1
return args, nil
}
func (ec *executionContext) field_Query_faceGroup_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "id",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["id"] = arg0
return args, nil
}
func (ec *executionContext) field_Query_mediaList_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "ids",
func(ctx context.Context, v any) ([]int, error) {
return ec.unmarshalNID2ᚕintᚄ(ctx, v)
})
if err != nil {
return nil, err
}
args["ids"] = arg0
return args, nil
}
func (ec *executionContext) field_Query_media_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "id",
func(ctx context.Context, v any) (int, error) {
return ec.unmarshalNID2int(ctx, v)
})
if err != nil {
return nil, err
}
args["id"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "tokenCredentials",
func(ctx context.Context, v any) (*models.ShareTokenCredentials, error) {
return ec.unmarshalOShareTokenCredentials2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenCredentials(ctx, v)
})
if err != nil {
return nil, err
}
args["tokenCredentials"] = arg1
return args, nil
}
func (ec *executionContext) field_Query_myAlbums_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "order",
func(ctx context.Context, v any) (*models.Ordering, error) {
return ec.unmarshalOOrdering2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrdering(ctx, v)
})
if err != nil {
return nil, err
}
args["order"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "onlyRoot",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["onlyRoot"] = arg2
arg3, err := graphql.ProcessArgField(ctx, rawArgs, "showEmpty",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["showEmpty"] = arg3
arg4, err := graphql.ProcessArgField(ctx, rawArgs, "onlyWithFavorites",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["onlyWithFavorites"] = arg4
return args, nil
}
func (ec *executionContext) field_Query_myFaceGroups_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg0
return args, nil
}
func (ec *executionContext) field_Query_myMedia_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "order",
func(ctx context.Context, v any) (*models.Ordering, error) {
return ec.unmarshalOOrdering2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrdering(ctx, v)
})
if err != nil {
return nil, err
}
args["order"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg1
return args, nil
}
func (ec *executionContext) field_Query_myTimeline_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "onlyFavorites",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["onlyFavorites"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "fromDate",
func(ctx context.Context, v any) (*time.Time, error) {
return ec.unmarshalOTime2ᚖtimeᚐTime(ctx, v)
})
if err != nil {
return nil, err
}
args["fromDate"] = arg2
return args, nil
}
func (ec *executionContext) field_Query_search_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "query",
func(ctx context.Context, v any) (string, error) {
return ec.unmarshalNString2string(ctx, v)
})
if err != nil {
return nil, err
}
args["query"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "limitMedia",
func(ctx context.Context, v any) (*int, error) {
return ec.unmarshalOInt2ᚖint(ctx, v)
})
if err != nil {
return nil, err
}
args["limitMedia"] = arg1
arg2, err := graphql.ProcessArgField(ctx, rawArgs, "limitAlbums",
func(ctx context.Context, v any) (*int, error) {
return ec.unmarshalOInt2ᚖint(ctx, v)
})
if err != nil {
return nil, err
}
args["limitAlbums"] = arg2
return args, nil
}
func (ec *executionContext) field_Query_shareTokenValidatePassword_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "credentials",
func(ctx context.Context, v any) (models.ShareTokenCredentials, error) {
return ec.unmarshalNShareTokenCredentials2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenCredentials(ctx, v)
})
if err != nil {
return nil, err
}
args["credentials"] = arg0
return args, nil
}
func (ec *executionContext) field_Query_shareToken_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "credentials",
func(ctx context.Context, v any) (models.ShareTokenCredentials, error) {
return ec.unmarshalNShareTokenCredentials2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenCredentials(ctx, v)
})
if err != nil {
return nil, err
}
args["credentials"] = arg0
return args, nil
}
func (ec *executionContext) field_Query_user_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "order",
func(ctx context.Context, v any) (*models.Ordering, error) {
return ec.unmarshalOOrdering2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrdering(ctx, v)
})
if err != nil {
return nil, err
}
args["order"] = arg0
arg1, err := graphql.ProcessArgField(ctx, rawArgs, "paginate",
func(ctx context.Context, v any) (*models.Pagination, error) {
return ec.unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx, v)
})
if err != nil {
return nil, err
}
args["paginate"] = arg1
return args, nil
}
func (ec *executionContext) field___Directive_args_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "includeDeprecated",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["includeDeprecated"] = arg0
return args, nil
}
func (ec *executionContext) field___Field_args_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "includeDeprecated",
func(ctx context.Context, v any) (*bool, error) {
return ec.unmarshalOBoolean2ᚖbool(ctx, v)
})
if err != nil {
return nil, err
}
args["includeDeprecated"] = arg0
return args, nil
}
func (ec *executionContext) field___Type_enumValues_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "includeDeprecated",
func(ctx context.Context, v any) (bool, error) {
return ec.unmarshalOBoolean2bool(ctx, v)
})
if err != nil {
return nil, err
}
args["includeDeprecated"] = arg0
return args, nil
}
func (ec *executionContext) field___Type_fields_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) {
var err error
args := map[string]any{}
arg0, err := graphql.ProcessArgField(ctx, rawArgs, "includeDeprecated",
func(ctx context.Context, v any) (bool, error) {
return ec.unmarshalOBoolean2bool(ctx, v)
})
if err != nil {
return nil, err
}
args["includeDeprecated"] = arg0
return args, nil
}
// endregion ***************************** args.gotpl *****************************
// region ************************** directives.gotpl **************************
// endregion ************************** directives.gotpl **************************
// region **************************** field.gotpl *****************************
func (ec *executionContext) _Album_id(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Album", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _Album_title(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_title(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Title, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_title(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Album", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Album_media(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_media(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Album().Media(ctx, obj, fc.Args["order"].(*models.Ordering), fc.Args["paginate"].(*models.Pagination), fc.Args["onlyFavorites"].(*bool))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_media(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Album",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Album_media_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Album_subAlbums(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_subAlbums(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Album().SubAlbums(ctx, obj, fc.Args["order"].(*models.Ordering), fc.Args["paginate"].(*models.Pagination))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbumᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_subAlbums(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Album",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Album_subAlbums_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Album_parentAlbum(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_parentAlbum(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ParentAlbum, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalOAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Album_parentAlbum(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Album",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Album_owner(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_owner(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Album().Owner(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.User) graphql.Marshaler {
return ec.marshalNUser2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_owner(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Album",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_User(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Album_filePath(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_filePath(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.FilePath(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_filePath(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Album", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Album_thumbnail(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_thumbnail(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Album().Thumbnail(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Media) graphql.Marshaler {
return ec.marshalOMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Album_thumbnail(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Album",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Album_path(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_path(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Album().Path(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbumᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_path(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Album",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Album_shares(ctx context.Context, field graphql.CollectedField, obj *models.Album) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Album_shares(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Album().Shares(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Album_shares(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Album",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _AuthorizeResult_success(ctx context.Context, field graphql.CollectedField, obj *models.AuthorizeResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_AuthorizeResult_success(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Success, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_AuthorizeResult_success(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("AuthorizeResult", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _AuthorizeResult_status(ctx context.Context, field graphql.CollectedField, obj *models.AuthorizeResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_AuthorizeResult_status(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Status, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_AuthorizeResult_status(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("AuthorizeResult", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _AuthorizeResult_token(ctx context.Context, field graphql.CollectedField, obj *models.AuthorizeResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_AuthorizeResult_token(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Token, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_AuthorizeResult_token(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("AuthorizeResult", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Coordinates_latitude(ctx context.Context, field graphql.CollectedField, obj *models.Coordinates) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Coordinates_latitude(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Latitude, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v float64) graphql.Marshaler {
return ec.marshalNFloat2float64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Coordinates_latitude(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Coordinates", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _Coordinates_longitude(ctx context.Context, field graphql.CollectedField, obj *models.Coordinates) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Coordinates_longitude(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Longitude, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v float64) graphql.Marshaler {
return ec.marshalNFloat2float64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Coordinates_longitude(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Coordinates", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _FaceGroup_id(ctx context.Context, field graphql.CollectedField, obj *models.FaceGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceGroup_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_FaceGroup_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("FaceGroup", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _FaceGroup_label(ctx context.Context, field graphql.CollectedField, obj *models.FaceGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceGroup_label(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Label, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_FaceGroup_label(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("FaceGroup", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _FaceGroup_imageFaces(ctx context.Context, field graphql.CollectedField, obj *models.FaceGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceGroup_imageFaces(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.FaceGroup().ImageFaces(ctx, obj, fc.Args["paginate"].(*models.Pagination))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.ImageFace) graphql.Marshaler {
return ec.marshalNImageFace2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐImageFaceᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_FaceGroup_imageFaces(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "FaceGroup",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ImageFace(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_FaceGroup_imageFaces_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _FaceGroup_imageFaceCount(ctx context.Context, field graphql.CollectedField, obj *models.FaceGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceGroup_imageFaceCount(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.FaceGroup().ImageFaceCount(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_FaceGroup_imageFaceCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("FaceGroup", field, true, true, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _FaceRectangle_minX(ctx context.Context, field graphql.CollectedField, obj *models.FaceRectangle) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceRectangle_minX(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.MinX, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v float64) graphql.Marshaler {
return ec.marshalNFloat2float64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_FaceRectangle_minX(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("FaceRectangle", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _FaceRectangle_maxX(ctx context.Context, field graphql.CollectedField, obj *models.FaceRectangle) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceRectangle_maxX(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.MaxX, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v float64) graphql.Marshaler {
return ec.marshalNFloat2float64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_FaceRectangle_maxX(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("FaceRectangle", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _FaceRectangle_minY(ctx context.Context, field graphql.CollectedField, obj *models.FaceRectangle) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceRectangle_minY(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.MinY, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v float64) graphql.Marshaler {
return ec.marshalNFloat2float64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_FaceRectangle_minY(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("FaceRectangle", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _FaceRectangle_maxY(ctx context.Context, field graphql.CollectedField, obj *models.FaceRectangle) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_FaceRectangle_maxY(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.MaxY, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v float64) graphql.Marshaler {
return ec.marshalNFloat2float64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_FaceRectangle_maxY(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("FaceRectangle", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _ImageFace_id(ctx context.Context, field graphql.CollectedField, obj *models.ImageFace) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ImageFace_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ImageFace_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ImageFace", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _ImageFace_media(ctx context.Context, field graphql.CollectedField, obj *models.ImageFace) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ImageFace_media(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.ImageFace().Media(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ImageFace_media(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "ImageFace",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _ImageFace_rectangle(ctx context.Context, field graphql.CollectedField, obj *models.ImageFace) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ImageFace_rectangle(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Rectangle, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v models.FaceRectangle) graphql.Marshaler {
return ec.marshalNFaceRectangle2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceRectangle(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ImageFace_rectangle(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "ImageFace",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceRectangle(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _ImageFace_faceGroup(ctx context.Context, field graphql.CollectedField, obj *models.ImageFace) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ImageFace_faceGroup(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.ImageFace().FaceGroup(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.FaceGroup) graphql.Marshaler {
return ec.marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ImageFace_faceGroup(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "ImageFace",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceGroup(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_id(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Media", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _Media_title(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_title(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Title, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_title(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Media", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Media_path(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_path(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Path, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_path(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Media", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Media_thumbnail(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_thumbnail(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Thumbnail(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.MediaURL) graphql.Marshaler {
return ec.marshalOMediaURL2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaURL(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Media_thumbnail(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_MediaURL(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_highRes(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_highRes(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().HighRes(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.MediaURL) graphql.Marshaler {
return ec.marshalOMediaURL2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaURL(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Media_highRes(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_MediaURL(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_videoWeb(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_videoWeb(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().VideoWeb(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.MediaURL) graphql.Marshaler {
return ec.marshalOMediaURL2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaURL(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Media_videoWeb(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_MediaURL(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_album(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_album(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Album(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_album(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_exif(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_exif(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Exif(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.MediaEXIF) graphql.Marshaler {
return ec.marshalOMediaEXIF2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaEXIF(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Media_exif(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_MediaEXIF(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_videoMetadata(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_videoMetadata(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.VideoMetadata, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.VideoMetadata) graphql.Marshaler {
return ec.marshalOVideoMetadata2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐVideoMetadata(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Media_videoMetadata(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_VideoMetadata(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_favorite(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_favorite(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Favorite(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_favorite(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Media", field, true, true, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _Media_type(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_type(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Type(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v models.MediaType) graphql.Marshaler {
return ec.marshalNMediaType2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaType(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Media", field, true, true, errors.New("field of type MediaType does not have child fields"))
}
func (ec *executionContext) _Media_date(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_date(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Date(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v time.Time) graphql.Marshaler {
return ec.marshalNTime2timeᚐTime(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_date(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Media", field, true, false, errors.New("field of type Time does not have child fields"))
}
func (ec *executionContext) _Media_blurhash(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_blurhash(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Blurhash, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Media_blurhash(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Media", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Media_shares(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_shares(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Shares(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_shares(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_downloads(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_downloads(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Downloads(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.MediaDownload) graphql.Marshaler {
return ec.marshalNMediaDownload2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaDownloadᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_downloads(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_MediaDownload(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Media_faces(ctx context.Context, field graphql.CollectedField, obj *models.Media) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Media_faces(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Media().Faces(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.ImageFace) graphql.Marshaler {
return ec.marshalNImageFace2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐImageFaceᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Media_faces(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Media",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ImageFace(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _MediaDownload_title(ctx context.Context, field graphql.CollectedField, obj *models.MediaDownload) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaDownload_title(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Title, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaDownload_title(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaDownload", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _MediaDownload_mediaUrl(ctx context.Context, field graphql.CollectedField, obj *models.MediaDownload) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaDownload_mediaUrl(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.MediaURL, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.MediaURL) graphql.Marshaler {
return ec.marshalNMediaURL2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaURL(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaDownload_mediaUrl(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "MediaDownload",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_MediaURL(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _MediaEXIF_id(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_media(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_media(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Media(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_media(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "MediaEXIF",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _MediaEXIF_description(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_description(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Description, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_camera(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_camera(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Camera, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_camera(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_maker(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_maker(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Maker, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_maker(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_lens(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_lens(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Lens, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_lens(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_dateShot(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_dateShot(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.DateShotWithOffset(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_dateShot(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_exposure(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_exposure(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Exposure, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *float64) graphql.Marshaler {
return ec.marshalOFloat2ᚖfloat64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_exposure(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_aperture(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_aperture(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Aperture, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *float64) graphql.Marshaler {
return ec.marshalOFloat2ᚖfloat64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_aperture(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_iso(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_iso(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Iso, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *int64) graphql.Marshaler {
return ec.marshalOInt2ᚖint64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_iso(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_focalLength(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_focalLength(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.FocalLength, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *float64) graphql.Marshaler {
return ec.marshalOFloat2ᚖfloat64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_focalLength(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_flash(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_flash(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Flash, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *int64) graphql.Marshaler {
return ec.marshalOInt2ᚖint64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_flash(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_exposureProgram(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_exposureProgram(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ExposureProgram, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *int64) graphql.Marshaler {
return ec.marshalOInt2ᚖint64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_exposureProgram(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaEXIF", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _MediaEXIF_coordinates(ctx context.Context, field graphql.CollectedField, obj *models.MediaEXIF) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaEXIF_coordinates(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Coordinates(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Coordinates) graphql.Marshaler {
return ec.marshalOCoordinates2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐCoordinates(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_MediaEXIF_coordinates(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "MediaEXIF",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Coordinates(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _MediaURL_url(ctx context.Context, field graphql.CollectedField, obj *models.MediaURL) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaURL_url(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.URL(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaURL_url(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaURL", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _MediaURL_width(ctx context.Context, field graphql.CollectedField, obj *models.MediaURL) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaURL_width(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Width, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaURL_width(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaURL", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _MediaURL_height(ctx context.Context, field graphql.CollectedField, obj *models.MediaURL) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaURL_height(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Height, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaURL_height(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaURL", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _MediaURL_fileSize(ctx context.Context, field graphql.CollectedField, obj *models.MediaURL) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_MediaURL_fileSize(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.FileSize, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int64) graphql.Marshaler {
return ec.marshalNInt2int64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_MediaURL_fileSize(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("MediaURL", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _Mutation_resetAlbumCover(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_resetAlbumCover(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().ResetAlbumCover(ctx, fc.Args["albumID"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.Album
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_resetAlbumCover(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_resetAlbumCover_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_setAlbumCover(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_setAlbumCover(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().SetAlbumCover(ctx, fc.Args["coverID"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.Album
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_setAlbumCover(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_setAlbumCover_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_setFaceGroupLabel(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_setFaceGroupLabel(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().SetFaceGroupLabel(ctx, fc.Args["faceGroupID"].(int), fc.Args["label"].(*string))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.FaceGroup
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.FaceGroup) graphql.Marshaler {
return ec.marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_setFaceGroupLabel(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceGroup(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_setFaceGroupLabel_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_combineFaceGroups(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_combineFaceGroups(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().CombineFaceGroups(ctx, fc.Args["destinationFaceGroupID"].(int), fc.Args["sourceFaceGroupIDs"].([]int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.FaceGroup
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.FaceGroup) graphql.Marshaler {
return ec.marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_combineFaceGroups(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceGroup(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_combineFaceGroups_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_moveImageFaces(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_moveImageFaces(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().MoveImageFaces(ctx, fc.Args["imageFaceIDs"].([]int), fc.Args["destinationFaceGroupID"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.FaceGroup
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.FaceGroup) graphql.Marshaler {
return ec.marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_moveImageFaces(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceGroup(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_moveImageFaces_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_recognizeUnlabeledFaces(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_recognizeUnlabeledFaces(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Mutation().RecognizeUnlabeledFaces(ctx)
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal []*models.ImageFace
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.ImageFace) graphql.Marshaler {
return ec.marshalNImageFace2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐImageFaceᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_recognizeUnlabeledFaces(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ImageFace(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Mutation_detachImageFaces(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_detachImageFaces(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().DetachImageFaces(ctx, fc.Args["imageFaceIDs"].([]int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.FaceGroup
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.FaceGroup) graphql.Marshaler {
return ec.marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_detachImageFaces(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceGroup(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_detachImageFaces_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_favoriteMedia(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_favoriteMedia(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().FavoriteMedia(ctx, fc.Args["mediaId"].(int), fc.Args["favorite"].(bool))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.Media
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_favoriteMedia(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_favoriteMedia_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_scanAll(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_scanAll(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Mutation().ScanAll(ctx)
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal *models.ScannerResult
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.ScannerResult) graphql.Marshaler {
return ec.marshalNScannerResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐScannerResult(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_scanAll(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ScannerResult(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Mutation_scanUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_scanUser(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().ScanUser(ctx, fc.Args["userId"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal *models.ScannerResult
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.ScannerResult) graphql.Marshaler {
return ec.marshalNScannerResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐScannerResult(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_scanUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ScannerResult(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_scanUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_setPeriodicScanInterval(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_setPeriodicScanInterval(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().SetPeriodicScanInterval(ctx, fc.Args["interval"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal int
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_setPeriodicScanInterval(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return nil, errors.New("field of type Int does not have child fields")
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_setPeriodicScanInterval_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_setScannerConcurrentWorkers(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_setScannerConcurrentWorkers(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().SetScannerConcurrentWorkers(ctx, fc.Args["workers"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal int
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_setScannerConcurrentWorkers(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return nil, errors.New("field of type Int does not have child fields")
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_setScannerConcurrentWorkers_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_shareAlbum(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_shareAlbum(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().ShareAlbum(ctx, fc.Args["albumId"].(int), fc.Args["expire"].(*time.Time), fc.Args["password"].(*string))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.ShareToken
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_shareAlbum(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_shareAlbum_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_shareMedia(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_shareMedia(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().ShareMedia(ctx, fc.Args["mediaId"].(int), fc.Args["expire"].(*time.Time), fc.Args["password"].(*string))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.ShareToken
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_shareMedia(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_shareMedia_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_deleteShareToken(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_deleteShareToken(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().DeleteShareToken(ctx, fc.Args["token"].(string))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.ShareToken
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_deleteShareToken(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_deleteShareToken_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_protectShareToken(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_protectShareToken(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().ProtectShareToken(ctx, fc.Args["token"].(string), fc.Args["password"].(*string))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.ShareToken
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_protectShareToken(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_protectShareToken_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_setExpireShareToken(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_setExpireShareToken(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().SetExpireShareToken(ctx, fc.Args["token"].(string), fc.Args["expire"].(*time.Time))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.ShareToken
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_setExpireShareToken(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_setExpireShareToken_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_authorizeUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_authorizeUser(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().AuthorizeUser(ctx, fc.Args["username"].(string), fc.Args["password"].(string))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.AuthorizeResult) graphql.Marshaler {
return ec.marshalNAuthorizeResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAuthorizeResult(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_authorizeUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_AuthorizeResult(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_authorizeUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_initialSetupWizard(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_initialSetupWizard(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().InitialSetupWizard(ctx, fc.Args["username"].(string), fc.Args["password"].(string), fc.Args["rootPath"].(string))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.AuthorizeResult) graphql.Marshaler {
return ec.marshalOAuthorizeResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAuthorizeResult(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Mutation_initialSetupWizard(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_AuthorizeResult(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_initialSetupWizard_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_updateUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_updateUser(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().UpdateUser(ctx, fc.Args["id"].(int), fc.Args["username"].(*string), fc.Args["password"].(*string), fc.Args["admin"].(*bool))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal *models.User
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.User) graphql.Marshaler {
return ec.marshalNUser2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_updateUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_User(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_updateUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_createUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_createUser(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().CreateUser(ctx, fc.Args["username"].(string), fc.Args["password"].(*string), fc.Args["admin"].(bool))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal *models.User
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.User) graphql.Marshaler {
return ec.marshalNUser2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_createUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_User(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_createUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_deleteUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_deleteUser(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().DeleteUser(ctx, fc.Args["id"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal *models.User
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.User) graphql.Marshaler {
return ec.marshalNUser2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_deleteUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_User(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_deleteUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_userAddRootPath(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_userAddRootPath(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().UserAddRootPath(ctx, fc.Args["id"].(int), fc.Args["rootPath"].(string))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal *models.Album
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalOAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Mutation_userAddRootPath(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_userAddRootPath_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_userRemoveRootAlbum(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_userRemoveRootAlbum(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().UserRemoveRootAlbum(ctx, fc.Args["userId"].(int), fc.Args["albumId"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal *models.Album
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalOAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Mutation_userRemoveRootAlbum(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_userRemoveRootAlbum_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Mutation_changeUserPreferences(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Mutation_changeUserPreferences(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Mutation().ChangeUserPreferences(ctx, fc.Args["language"].(*string))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.UserPreferences
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.UserPreferences) graphql.Marshaler {
return ec.marshalNUserPreferences2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUserPreferences(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Mutation_changeUserPreferences(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Mutation",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_UserPreferences(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Mutation_changeUserPreferences_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Notification_key(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_key(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Key, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Notification_key(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Notification_type(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_type(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Type, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v models.NotificationType) graphql.Marshaler {
return ec.marshalNNotificationType2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐNotificationType(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Notification_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type NotificationType does not have child fields"))
}
func (ec *executionContext) _Notification_header(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_header(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Header, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Notification_header(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Notification_content(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_content(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Content, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Notification_content(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Notification_progress(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_progress(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Progress, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *float64) graphql.Marshaler {
return ec.marshalOFloat2ᚖfloat64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Notification_progress(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _Notification_positive(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_positive(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Positive, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Notification_positive(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _Notification_negative(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_negative(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Negative, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Notification_negative(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _Notification_timeout(ctx context.Context, field graphql.CollectedField, obj *models.Notification) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Notification_timeout(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Timeout, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *int) graphql.Marshaler {
return ec.marshalOInt2ᚖint(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Notification_timeout(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Notification", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _Query_myAlbums(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_myAlbums(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().MyAlbums(ctx, fc.Args["order"].(*models.Ordering), fc.Args["paginate"].(*models.Pagination), fc.Args["onlyRoot"].(*bool), fc.Args["showEmpty"].(*bool), fc.Args["onlyWithFavorites"].(*bool))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal []*models.Album
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbumᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_myAlbums(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_myAlbums_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_album(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_album(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().Album(ctx, fc.Args["id"].(int), fc.Args["tokenCredentials"].(*models.ShareTokenCredentials))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_album(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_album_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_myFaceGroups(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_myFaceGroups(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().MyFaceGroups(ctx, fc.Args["paginate"].(*models.Pagination))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal []*models.FaceGroup
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.FaceGroup) graphql.Marshaler {
return ec.marshalNFaceGroup2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroupᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_myFaceGroups(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceGroup(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_myFaceGroups_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_faceGroup(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_faceGroup(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().FaceGroup(ctx, fc.Args["id"].(int))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.FaceGroup
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.FaceGroup) graphql.Marshaler {
return ec.marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_faceGroup(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_FaceGroup(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_faceGroup_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_myMedia(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_myMedia(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().MyMedia(ctx, fc.Args["order"].(*models.Ordering), fc.Args["paginate"].(*models.Pagination))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal []*models.Media
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_myMedia(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_myMedia_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_media(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_media(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().Media(ctx, fc.Args["id"].(int), fc.Args["tokenCredentials"].(*models.ShareTokenCredentials))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_media(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_media_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_mediaList(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_mediaList(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().MediaList(ctx, fc.Args["ids"].([]int))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_mediaList(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_mediaList_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_myMediaGeoJson(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_myMediaGeoJson(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Query().MyMediaGeoJSON(ctx)
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal any
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v any) graphql.Marshaler {
return ec.marshalNAny2interface(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_myMediaGeoJson(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Query", field, true, true, errors.New("field of type Any does not have child fields"))
}
func (ec *executionContext) _Query_mapboxToken(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_mapboxToken(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Query().MapboxToken(ctx)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Query_mapboxToken(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("Query", field, true, true, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _Query_search(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_search(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().Search(ctx, fc.Args["query"].(string), fc.Args["limitMedia"].(*int), fc.Args["limitAlbums"].(*int))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.SearchResult) graphql.Marshaler {
return ec.marshalNSearchResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐSearchResult(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_search(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_SearchResult(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_search_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_shareToken(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_shareToken(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().ShareToken(ctx, fc.Args["credentials"].(models.ShareTokenCredentials))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.ShareToken) graphql.Marshaler {
return ec.marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_shareToken(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_ShareToken(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_shareToken_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_shareTokenValidatePassword(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_shareTokenValidatePassword(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().ShareTokenValidatePassword(ctx, fc.Args["credentials"].(models.ShareTokenCredentials))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_shareTokenValidatePassword(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return nil, errors.New("field of type Boolean does not have child fields")
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_shareTokenValidatePassword_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_siteInfo(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_siteInfo(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Query().SiteInfo(ctx)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.SiteInfo) graphql.Marshaler {
return ec.marshalNSiteInfo2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐSiteInfo(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_siteInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_SiteInfo(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Query_myTimeline(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_myTimeline(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().MyTimeline(ctx, fc.Args["paginate"].(*models.Pagination), fc.Args["onlyFavorites"].(*bool), fc.Args["fromDate"].(*time.Time))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal []*models.Media
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_myTimeline(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_myTimeline_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_user(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_user(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.Resolvers.Query().User(ctx, fc.Args["order"].(*models.Ordering), fc.Args["paginate"].(*models.Pagination))
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal []*models.User
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.User) graphql.Marshaler {
return ec.marshalNUser2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUserᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_user(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_User(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query_user_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query_myUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_myUser(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Query().MyUser(ctx)
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.User
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.User) graphql.Marshaler {
return ec.marshalNUser2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_myUser(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_User(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Query_myUserPreferences(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query_myUserPreferences(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Query().MyUserPreferences(ctx)
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAuthorized == nil {
var zeroVal *models.UserPreferences
return zeroVal, errors.New("directive isAuthorized is not implemented")
}
return ec.Directives.IsAuthorized(ctx, nil, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v *models.UserPreferences) graphql.Marshaler {
return ec.marshalNUserPreferences2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUserPreferences(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Query_myUserPreferences(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_UserPreferences(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query___type(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return ec.IntrospectType(fc.Args["name"].(string))
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Query___type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Query___type_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Query___schema(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.IntrospectSchema()
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Schema) graphql.Marshaler {
return ec.marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_Query___schema(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Query",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Schema(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _ScannerResult_finished(ctx context.Context, field graphql.CollectedField, obj *models.ScannerResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ScannerResult_finished(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Finished, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ScannerResult_finished(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ScannerResult", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _ScannerResult_success(ctx context.Context, field graphql.CollectedField, obj *models.ScannerResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ScannerResult_success(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Success, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ScannerResult_success(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ScannerResult", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _ScannerResult_progress(ctx context.Context, field graphql.CollectedField, obj *models.ScannerResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ScannerResult_progress(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Progress, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *float64) graphql.Marshaler {
return ec.marshalOFloat2ᚖfloat64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_ScannerResult_progress(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ScannerResult", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _ScannerResult_message(ctx context.Context, field graphql.CollectedField, obj *models.ScannerResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ScannerResult_message(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Message, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_ScannerResult_message(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ScannerResult", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _SearchResult_query(ctx context.Context, field graphql.CollectedField, obj *models.SearchResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_SearchResult_query(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Query, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_SearchResult_query(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("SearchResult", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _SearchResult_albums(ctx context.Context, field graphql.CollectedField, obj *models.SearchResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_SearchResult_albums(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Albums, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbumᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_SearchResult_albums(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "SearchResult",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _SearchResult_media(ctx context.Context, field graphql.CollectedField, obj *models.SearchResult) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_SearchResult_media(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Media, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_SearchResult_media(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "SearchResult",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _ShareToken_id(ctx context.Context, field graphql.CollectedField, obj *models.ShareToken) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ShareToken_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ShareToken_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ShareToken", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _ShareToken_token(ctx context.Context, field graphql.CollectedField, obj *models.ShareToken) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ShareToken_token(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Token(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ShareToken_token(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ShareToken", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _ShareToken_owner(ctx context.Context, field graphql.CollectedField, obj *models.ShareToken) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ShareToken_owner(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Owner, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v models.User) graphql.Marshaler {
return ec.marshalNUser2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ShareToken_owner(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "ShareToken",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_User(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _ShareToken_expire(ctx context.Context, field graphql.CollectedField, obj *models.ShareToken) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ShareToken_expire(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Expire, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *time.Time) graphql.Marshaler {
return ec.marshalOTime2ᚖtimeᚐTime(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_ShareToken_expire(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ShareToken", field, false, false, errors.New("field of type Time does not have child fields"))
}
func (ec *executionContext) _ShareToken_hasPassword(ctx context.Context, field graphql.CollectedField, obj *models.ShareToken) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ShareToken_hasPassword(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.ShareToken().HasPassword(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_ShareToken_hasPassword(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("ShareToken", field, true, true, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _ShareToken_album(ctx context.Context, field graphql.CollectedField, obj *models.ShareToken) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ShareToken_album(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Album, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalOAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_ShareToken_album(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "ShareToken",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _ShareToken_media(ctx context.Context, field graphql.CollectedField, obj *models.ShareToken) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_ShareToken_media(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Media, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Media) graphql.Marshaler {
return ec.marshalOMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_ShareToken_media(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "ShareToken",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _SiteInfo_initialSetup(ctx context.Context, field graphql.CollectedField, obj *models.SiteInfo) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_SiteInfo_initialSetup(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.InitialSetup, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_SiteInfo_initialSetup(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("SiteInfo", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _SiteInfo_faceDetectionEnabled(ctx context.Context, field graphql.CollectedField, obj *models.SiteInfo) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_SiteInfo_faceDetectionEnabled(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.SiteInfo().FaceDetectionEnabled(ctx, obj)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_SiteInfo_faceDetectionEnabled(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("SiteInfo", field, true, true, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _SiteInfo_periodicScanInterval(ctx context.Context, field graphql.CollectedField, obj *models.SiteInfo) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_SiteInfo_periodicScanInterval(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.PeriodicScanInterval, nil
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal int
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, obj, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_SiteInfo_periodicScanInterval(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("SiteInfo", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _SiteInfo_concurrentWorkers(ctx context.Context, field graphql.CollectedField, obj *models.SiteInfo) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_SiteInfo_concurrentWorkers(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ConcurrentWorkers, nil
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal int
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, obj, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_SiteInfo_concurrentWorkers(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("SiteInfo", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _Subscription_notification(ctx context.Context, field graphql.CollectedField) (ret func(ctx context.Context) graphql.Marshaler) {
return graphql.ResolveFieldStream(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_Subscription_notification(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.Subscription().Notification(ctx)
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Notification) graphql.Marshaler {
return ec.marshalNNotification2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐNotification(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_Subscription_notification(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "Subscription",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Notification(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _TimelineGroup_album(ctx context.Context, field graphql.CollectedField, obj *models.TimelineGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_TimelineGroup_album(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Album, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_TimelineGroup_album(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "TimelineGroup",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _TimelineGroup_media(ctx context.Context, field graphql.CollectedField, obj *models.TimelineGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_TimelineGroup_media(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Media, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []*models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_TimelineGroup_media(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "TimelineGroup",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _TimelineGroup_mediaTotal(ctx context.Context, field graphql.CollectedField, obj *models.TimelineGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_TimelineGroup_mediaTotal(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.MediaTotal, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_TimelineGroup_mediaTotal(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("TimelineGroup", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _TimelineGroup_date(ctx context.Context, field graphql.CollectedField, obj *models.TimelineGroup) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_TimelineGroup_date(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Date, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v time.Time) graphql.Marshaler {
return ec.marshalNTime2timeᚐTime(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_TimelineGroup_date(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("TimelineGroup", field, false, false, errors.New("field of type Time does not have child fields"))
}
func (ec *executionContext) _User_id(ctx context.Context, field graphql.CollectedField, obj *models.User) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_User_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_User_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("User", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _User_username(ctx context.Context, field graphql.CollectedField, obj *models.User) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_User_username(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Username, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_User_username(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("User", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _User_albums(ctx context.Context, field graphql.CollectedField, obj *models.User) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_User_albums(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.User().Albums(ctx, obj)
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal []*models.Album
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, obj, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbumᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_User_albums(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "User",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _User_rootAlbums(ctx context.Context, field graphql.CollectedField, obj *models.User) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_User_rootAlbums(ctx, field)
},
func(ctx context.Context) (any, error) {
return ec.Resolvers.User().RootAlbums(ctx, obj)
},
func(ctx context.Context, next graphql.Resolver) graphql.Resolver {
directive0 := next
directive1 := func(ctx context.Context) (any, error) {
if ec.Directives.IsAdmin == nil {
var zeroVal []*models.Album
return zeroVal, errors.New("directive isAdmin is not implemented")
}
return ec.Directives.IsAdmin(ctx, obj, directive0)
}
next = directive1
return next
},
func(ctx context.Context, selections ast.SelectionSet, v []*models.Album) graphql.Marshaler {
return ec.marshalNAlbum2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbumᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_User_rootAlbums(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "User",
Field: field,
IsMethod: true,
IsResolver: true,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Album(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _User_admin(ctx context.Context, field graphql.CollectedField, obj *models.User) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_User_admin(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Admin, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_User_admin(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("User", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) _UserPreferences_id(ctx context.Context, field graphql.CollectedField, obj *models.UserPreferences) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_UserPreferences_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_UserPreferences_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("UserPreferences", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _UserPreferences_language(ctx context.Context, field graphql.CollectedField, obj *models.UserPreferences) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_UserPreferences_language(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Language, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.LanguageTranslation) graphql.Marshaler {
return ec.marshalOLanguageTranslation2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐLanguageTranslation(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_UserPreferences_language(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("UserPreferences", field, false, false, errors.New("field of type LanguageTranslation does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_id(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_id(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ID, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNID2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type ID does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_media(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_media(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Media(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *models.Media) graphql.Marshaler {
return ec.marshalNMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_media(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "VideoMetadata",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields_Media(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) _VideoMetadata_width(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_width(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Width, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_width(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_height(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_height(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Height, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v int) graphql.Marshaler {
return ec.marshalNInt2int(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_height(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type Int does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_duration(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_duration(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Duration, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v float64) graphql.Marshaler {
return ec.marshalNFloat2float64(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_duration(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_codec(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_codec(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Codec, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_codec(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_framerate(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_framerate(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Framerate, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *float64) graphql.Marshaler {
return ec.marshalOFloat2ᚖfloat64(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_framerate(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type Float does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_bitrate(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_bitrate(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Bitrate, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_bitrate(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_colorProfile(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_colorProfile(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.ColorProfile, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_colorProfile(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) _VideoMetadata_audio(ctx context.Context, field graphql.CollectedField, obj *models.VideoMetadata) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext_VideoMetadata_audio(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Audio, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext_VideoMetadata_audio(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("VideoMetadata", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Directive_name(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Name, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Directive_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Directive", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Directive_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Directive_description(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Description(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Directive_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Directive", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Directive_isRepeatable(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.IsRepeatable, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Directive_isRepeatable(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Directive", field, false, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) ___Directive_locations(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Directive_locations(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Locations, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []string) graphql.Marshaler {
return ec.marshalN__DirectiveLocation2ᚕstringᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Directive_locations(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Directive", field, false, false, errors.New("field of type __DirectiveLocation does not have child fields"))
}
func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Directive_args(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Args, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Directive_args(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Directive",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___InputValue(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field___Directive_args_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___EnumValue_name(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Name, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___EnumValue_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__EnumValue", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___EnumValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___EnumValue_description(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Description(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___EnumValue_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__EnumValue", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___EnumValue_isDeprecated(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.IsDeprecated(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___EnumValue_isDeprecated(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__EnumValue", field, true, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___EnumValue_deprecationReason(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.DeprecationReason(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___EnumValue_deprecationReason(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__EnumValue", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Field_name(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Name, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Field_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Field", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Field_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Field_description(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Description(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Field_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Field", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Field_args(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Args, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Field_args(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Field",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___InputValue(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field___Field_args_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Field_type(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Type, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Field_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Field",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Field_isDeprecated(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.IsDeprecated(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Field_isDeprecated(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Field", field, true, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Field_deprecationReason(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.DeprecationReason(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Field_deprecationReason(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Field", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___InputValue_name(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Name, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalNString2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___InputValue_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__InputValue", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___InputValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___InputValue_description(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Description(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___InputValue_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__InputValue", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___InputValue_type(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Type, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___InputValue_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__InputValue",
Field: field,
IsMethod: false,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___InputValue_defaultValue(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.DefaultValue, nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___InputValue_defaultValue(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__InputValue", field, false, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___InputValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___InputValue_isDeprecated(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.IsDeprecated(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalNBoolean2bool(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___InputValue_isDeprecated(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__InputValue", field, true, false, errors.New("field of type Boolean does not have child fields"))
}
func (ec *executionContext) ___InputValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___InputValue_deprecationReason(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.DeprecationReason(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___InputValue_deprecationReason(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__InputValue", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Schema_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Schema_description(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Description(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Schema_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Schema", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Schema_types(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Types(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
return ec.marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Schema_types(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Schema",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Schema_queryType(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.QueryType(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Schema_queryType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Schema",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Schema_mutationType(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.MutationType(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Schema_mutationType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Schema",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Schema_subscriptionType(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.SubscriptionType(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Schema_subscriptionType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Schema",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Schema_directives(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Directives(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.Directive) graphql.Marshaler {
return ec.marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Schema_directives(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Schema",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Directive(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_kind(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Kind(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v string) graphql.Marshaler {
return ec.marshalN__TypeKind2string(ctx, selections, v)
},
true,
true,
)
}
func (ec *executionContext) fieldContext___Type_kind(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Type", field, true, false, errors.New("field of type __TypeKind does not have child fields"))
}
func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_name(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Name(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Type", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_description(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Description(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Type", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Type_specifiedByURL(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_specifiedByURL(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.SpecifiedByURL(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *string) graphql.Marshaler {
return ec.marshalOString2ᚖstring(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_specifiedByURL(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Type", field, true, false, errors.New("field of type String does not have child fields"))
}
func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_fields(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return obj.Fields(fc.Args["includeDeprecated"].(bool)), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.Field) graphql.Marshaler {
return ec.marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_fields(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Type",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Field(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field___Type_fields_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_interfaces(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.Interfaces(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_interfaces(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Type",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_possibleTypes(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.PossibleTypes(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_possibleTypes(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Type",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_enumValues(ctx, field)
},
func(ctx context.Context) (any, error) {
fc := graphql.GetFieldContext(ctx)
return obj.EnumValues(fc.Args["includeDeprecated"].(bool)), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler {
return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_enumValues(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Type",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___EnumValue(ctx, field)
},
}
defer func() {
if r := recover(); r != nil {
err = ec.Recover(ctx, r)
ec.Error(ctx, err)
}
}()
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field___Type_enumValues_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
return fc, err
}
return fc, nil
}
func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_inputFields(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.InputFields(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
return ec.marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_inputFields(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Type",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___InputValue(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_ofType(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.OfType(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_ofType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
fc = &graphql.FieldContext{
Object: "__Type",
Field: field,
IsMethod: true,
IsResolver: false,
Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.childFields___Type(ctx, field)
},
}
return fc, nil
}
func (ec *executionContext) ___Type_isOneOf(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
return graphql.ResolveField(
ctx,
ec.OperationContext,
field,
func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) {
return ec.fieldContext___Type_isOneOf(ctx, field)
},
func(ctx context.Context) (any, error) {
return obj.IsOneOf(), nil
},
nil,
func(ctx context.Context, selections ast.SelectionSet, v bool) graphql.Marshaler {
return ec.marshalOBoolean2bool(ctx, selections, v)
},
true,
false,
)
}
func (ec *executionContext) fieldContext___Type_isOneOf(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
return graphql.NewScalarFieldContext("__Type", field, true, false, errors.New("field of type Boolean does not have child fields"))
}
// endregion **************************** field.gotpl *****************************
// region **************************** input.gotpl *****************************
func (ec *executionContext) unmarshalInputOrdering(ctx context.Context, obj any) (models.Ordering, error) {
var it models.Ordering
if obj == nil {
return it, nil
}
asMap := map[string]any{}
for k, v := range obj.(map[string]any) {
asMap[k] = v
}
fieldsInOrder := [...]string{"order_by", "order_direction"}
for _, k := range fieldsInOrder {
v, ok := asMap[k]
if !ok {
continue
}
switch k {
case "order_by":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("order_by"))
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
it.OrderBy = data
case "order_direction":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("order_direction"))
data, err := ec.unmarshalOOrderDirection2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrderDirection(ctx, v)
if err != nil {
return it, err
}
it.OrderDirection = data
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputPagination(ctx context.Context, obj any) (models.Pagination, error) {
var it models.Pagination
if obj == nil {
return it, nil
}
asMap := map[string]any{}
for k, v := range obj.(map[string]any) {
asMap[k] = v
}
fieldsInOrder := [...]string{"limit", "offset"}
for _, k := range fieldsInOrder {
v, ok := asMap[k]
if !ok {
continue
}
switch k {
case "limit":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("limit"))
data, err := ec.unmarshalOInt2ᚖint(ctx, v)
if err != nil {
return it, err
}
it.Limit = data
case "offset":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("offset"))
data, err := ec.unmarshalOInt2ᚖint(ctx, v)
if err != nil {
return it, err
}
it.Offset = data
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputShareTokenCredentials(ctx context.Context, obj any) (models.ShareTokenCredentials, error) {
var it models.ShareTokenCredentials
if obj == nil {
return it, nil
}
asMap := map[string]any{}
for k, v := range obj.(map[string]any) {
asMap[k] = v
}
fieldsInOrder := [...]string{"token", "password"}
for _, k := range fieldsInOrder {
v, ok := asMap[k]
if !ok {
continue
}
switch k {
case "token":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("token"))
data, err := ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
it.Token = data
case "password":
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("password"))
data, err := ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
it.Password = data
}
}
return it, nil
}
// endregion **************************** input.gotpl *****************************
// region ************************** interface.gotpl ***************************
// endregion ************************** interface.gotpl ***************************
// region **************************** object.gotpl ****************************
var albumImplementors = []string{"Album"}
func (ec *executionContext) _Album(ctx context.Context, sel ast.SelectionSet, obj *models.Album) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, albumImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Album")
case "id":
out.Values[i] = ec._Album_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "title":
out.Values[i] = ec._Album_title(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "media":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Album_media(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "subAlbums":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Album_subAlbums(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "parentAlbum":
out.Values[i] = ec._Album_parentAlbum(ctx, field, obj)
case "owner":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Album_owner(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "filePath":
out.Values[i] = ec._Album_filePath(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "thumbnail":
field := field
innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Album_thumbnail(ctx, field, obj)
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "path":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Album_path(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "shares":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Album_shares(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var authorizeResultImplementors = []string{"AuthorizeResult"}
func (ec *executionContext) _AuthorizeResult(ctx context.Context, sel ast.SelectionSet, obj *models.AuthorizeResult) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, authorizeResultImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("AuthorizeResult")
case "success":
out.Values[i] = ec._AuthorizeResult_success(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "status":
out.Values[i] = ec._AuthorizeResult_status(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "token":
out.Values[i] = ec._AuthorizeResult_token(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var coordinatesImplementors = []string{"Coordinates"}
func (ec *executionContext) _Coordinates(ctx context.Context, sel ast.SelectionSet, obj *models.Coordinates) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, coordinatesImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Coordinates")
case "latitude":
out.Values[i] = ec._Coordinates_latitude(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "longitude":
out.Values[i] = ec._Coordinates_longitude(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var faceGroupImplementors = []string{"FaceGroup"}
func (ec *executionContext) _FaceGroup(ctx context.Context, sel ast.SelectionSet, obj *models.FaceGroup) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, faceGroupImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("FaceGroup")
case "id":
out.Values[i] = ec._FaceGroup_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "label":
out.Values[i] = ec._FaceGroup_label(ctx, field, obj)
case "imageFaces":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._FaceGroup_imageFaces(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "imageFaceCount":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._FaceGroup_imageFaceCount(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var faceRectangleImplementors = []string{"FaceRectangle"}
func (ec *executionContext) _FaceRectangle(ctx context.Context, sel ast.SelectionSet, obj *models.FaceRectangle) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, faceRectangleImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("FaceRectangle")
case "minX":
out.Values[i] = ec._FaceRectangle_minX(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "maxX":
out.Values[i] = ec._FaceRectangle_maxX(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "minY":
out.Values[i] = ec._FaceRectangle_minY(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "maxY":
out.Values[i] = ec._FaceRectangle_maxY(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var imageFaceImplementors = []string{"ImageFace"}
func (ec *executionContext) _ImageFace(ctx context.Context, sel ast.SelectionSet, obj *models.ImageFace) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, imageFaceImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("ImageFace")
case "id":
out.Values[i] = ec._ImageFace_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "media":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._ImageFace_media(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "rectangle":
out.Values[i] = ec._ImageFace_rectangle(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "faceGroup":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._ImageFace_faceGroup(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var mediaImplementors = []string{"Media"}
func (ec *executionContext) _Media(ctx context.Context, sel ast.SelectionSet, obj *models.Media) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, mediaImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Media")
case "id":
out.Values[i] = ec._Media_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "title":
out.Values[i] = ec._Media_title(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "path":
out.Values[i] = ec._Media_path(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "thumbnail":
field := field
innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_thumbnail(ctx, field, obj)
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "highRes":
field := field
innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_highRes(ctx, field, obj)
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "videoWeb":
field := field
innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_videoWeb(ctx, field, obj)
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "album":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_album(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "exif":
field := field
innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_exif(ctx, field, obj)
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "videoMetadata":
out.Values[i] = ec._Media_videoMetadata(ctx, field, obj)
case "favorite":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_favorite(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "type":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_type(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "date":
out.Values[i] = ec._Media_date(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "blurhash":
out.Values[i] = ec._Media_blurhash(ctx, field, obj)
case "shares":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_shares(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "downloads":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_downloads(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "faces":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Media_faces(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var mediaDownloadImplementors = []string{"MediaDownload"}
func (ec *executionContext) _MediaDownload(ctx context.Context, sel ast.SelectionSet, obj *models.MediaDownload) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, mediaDownloadImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("MediaDownload")
case "title":
out.Values[i] = ec._MediaDownload_title(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "mediaUrl":
out.Values[i] = ec._MediaDownload_mediaUrl(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var mediaEXIFImplementors = []string{"MediaEXIF"}
func (ec *executionContext) _MediaEXIF(ctx context.Context, sel ast.SelectionSet, obj *models.MediaEXIF) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, mediaEXIFImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("MediaEXIF")
case "id":
out.Values[i] = ec._MediaEXIF_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "media":
out.Values[i] = ec._MediaEXIF_media(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "description":
out.Values[i] = ec._MediaEXIF_description(ctx, field, obj)
case "camera":
out.Values[i] = ec._MediaEXIF_camera(ctx, field, obj)
case "maker":
out.Values[i] = ec._MediaEXIF_maker(ctx, field, obj)
case "lens":
out.Values[i] = ec._MediaEXIF_lens(ctx, field, obj)
case "dateShot":
out.Values[i] = ec._MediaEXIF_dateShot(ctx, field, obj)
case "exposure":
out.Values[i] = ec._MediaEXIF_exposure(ctx, field, obj)
case "aperture":
out.Values[i] = ec._MediaEXIF_aperture(ctx, field, obj)
case "iso":
out.Values[i] = ec._MediaEXIF_iso(ctx, field, obj)
case "focalLength":
out.Values[i] = ec._MediaEXIF_focalLength(ctx, field, obj)
case "flash":
out.Values[i] = ec._MediaEXIF_flash(ctx, field, obj)
case "exposureProgram":
out.Values[i] = ec._MediaEXIF_exposureProgram(ctx, field, obj)
case "coordinates":
out.Values[i] = ec._MediaEXIF_coordinates(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var mediaURLImplementors = []string{"MediaURL"}
func (ec *executionContext) _MediaURL(ctx context.Context, sel ast.SelectionSet, obj *models.MediaURL) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, mediaURLImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("MediaURL")
case "url":
out.Values[i] = ec._MediaURL_url(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "width":
out.Values[i] = ec._MediaURL_width(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "height":
out.Values[i] = ec._MediaURL_height(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "fileSize":
out.Values[i] = ec._MediaURL_fileSize(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var mutationImplementors = []string{"Mutation"}
func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, mutationImplementors)
ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{
Object: "Mutation",
})
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{
Object: field.Name,
Field: field,
})
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Mutation")
case "resetAlbumCover":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_resetAlbumCover(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "setAlbumCover":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_setAlbumCover(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "setFaceGroupLabel":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_setFaceGroupLabel(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "combineFaceGroups":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_combineFaceGroups(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "moveImageFaces":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_moveImageFaces(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "recognizeUnlabeledFaces":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_recognizeUnlabeledFaces(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "detachImageFaces":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_detachImageFaces(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "favoriteMedia":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_favoriteMedia(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "scanAll":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_scanAll(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "scanUser":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_scanUser(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "setPeriodicScanInterval":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_setPeriodicScanInterval(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "setScannerConcurrentWorkers":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_setScannerConcurrentWorkers(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "shareAlbum":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_shareAlbum(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "shareMedia":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_shareMedia(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "deleteShareToken":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_deleteShareToken(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "protectShareToken":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_protectShareToken(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "setExpireShareToken":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_setExpireShareToken(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "authorizeUser":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_authorizeUser(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "initialSetupWizard":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_initialSetupWizard(ctx, field)
})
case "updateUser":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_updateUser(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "createUser":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_createUser(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "deleteUser":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_deleteUser(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "userAddRootPath":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_userAddRootPath(ctx, field)
})
case "userRemoveRootAlbum":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_userRemoveRootAlbum(ctx, field)
})
case "changeUserPreferences":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Mutation_changeUserPreferences(ctx, field)
})
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var notificationImplementors = []string{"Notification"}
func (ec *executionContext) _Notification(ctx context.Context, sel ast.SelectionSet, obj *models.Notification) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, notificationImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Notification")
case "key":
out.Values[i] = ec._Notification_key(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "type":
out.Values[i] = ec._Notification_type(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "header":
out.Values[i] = ec._Notification_header(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "content":
out.Values[i] = ec._Notification_content(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "progress":
out.Values[i] = ec._Notification_progress(ctx, field, obj)
case "positive":
out.Values[i] = ec._Notification_positive(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "negative":
out.Values[i] = ec._Notification_negative(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "timeout":
out.Values[i] = ec._Notification_timeout(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var queryImplementors = []string{"Query"}
func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, queryImplementors)
ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{
Object: "Query",
})
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{
Object: field.Name,
Field: field,
})
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Query")
case "myAlbums":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_myAlbums(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "album":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_album(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "myFaceGroups":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_myFaceGroups(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "faceGroup":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_faceGroup(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "myMedia":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_myMedia(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "media":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_media(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "mediaList":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_mediaList(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "myMediaGeoJson":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_myMediaGeoJson(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "mapboxToken":
field := field
innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_mapboxToken(ctx, field)
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "search":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_search(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "shareToken":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_shareToken(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "shareTokenValidatePassword":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_shareTokenValidatePassword(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "siteInfo":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_siteInfo(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "myTimeline":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_myTimeline(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "user":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_user(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "myUser":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_myUser(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "myUserPreferences":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_myUserPreferences(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
rrm := func(ctx context.Context) graphql.Marshaler {
return ec.OperationContext.RootResolverMiddleware(ctx,
func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) })
case "__type":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Query___type(ctx, field)
})
case "__schema":
out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) {
return ec._Query___schema(ctx, field)
})
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var scannerResultImplementors = []string{"ScannerResult"}
func (ec *executionContext) _ScannerResult(ctx context.Context, sel ast.SelectionSet, obj *models.ScannerResult) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, scannerResultImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("ScannerResult")
case "finished":
out.Values[i] = ec._ScannerResult_finished(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "success":
out.Values[i] = ec._ScannerResult_success(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "progress":
out.Values[i] = ec._ScannerResult_progress(ctx, field, obj)
case "message":
out.Values[i] = ec._ScannerResult_message(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var searchResultImplementors = []string{"SearchResult"}
func (ec *executionContext) _SearchResult(ctx context.Context, sel ast.SelectionSet, obj *models.SearchResult) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, searchResultImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("SearchResult")
case "query":
out.Values[i] = ec._SearchResult_query(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "albums":
out.Values[i] = ec._SearchResult_albums(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "media":
out.Values[i] = ec._SearchResult_media(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var shareTokenImplementors = []string{"ShareToken"}
func (ec *executionContext) _ShareToken(ctx context.Context, sel ast.SelectionSet, obj *models.ShareToken) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, shareTokenImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("ShareToken")
case "id":
out.Values[i] = ec._ShareToken_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "token":
out.Values[i] = ec._ShareToken_token(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "owner":
out.Values[i] = ec._ShareToken_owner(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "expire":
out.Values[i] = ec._ShareToken_expire(ctx, field, obj)
case "hasPassword":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._ShareToken_hasPassword(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "album":
out.Values[i] = ec._ShareToken_album(ctx, field, obj)
case "media":
out.Values[i] = ec._ShareToken_media(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var siteInfoImplementors = []string{"SiteInfo"}
func (ec *executionContext) _SiteInfo(ctx context.Context, sel ast.SelectionSet, obj *models.SiteInfo) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, siteInfoImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("SiteInfo")
case "initialSetup":
out.Values[i] = ec._SiteInfo_initialSetup(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "faceDetectionEnabled":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._SiteInfo_faceDetectionEnabled(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "periodicScanInterval":
out.Values[i] = ec._SiteInfo_periodicScanInterval(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "concurrentWorkers":
out.Values[i] = ec._SiteInfo_concurrentWorkers(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var subscriptionImplementors = []string{"Subscription"}
func (ec *executionContext) _Subscription(ctx context.Context, sel ast.SelectionSet) func(ctx context.Context) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, subscriptionImplementors)
ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{
Object: "Subscription",
})
if len(fields) != 1 {
graphql.AddErrorf(ctx, "must subscribe to exactly one stream")
return nil
}
switch fields[0].Name {
case "notification":
return ec._Subscription_notification(ctx, fields[0])
default:
panic("unknown field " + strconv.Quote(fields[0].Name))
}
}
var timelineGroupImplementors = []string{"TimelineGroup"}
func (ec *executionContext) _TimelineGroup(ctx context.Context, sel ast.SelectionSet, obj *models.TimelineGroup) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, timelineGroupImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("TimelineGroup")
case "album":
out.Values[i] = ec._TimelineGroup_album(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "media":
out.Values[i] = ec._TimelineGroup_media(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "mediaTotal":
out.Values[i] = ec._TimelineGroup_mediaTotal(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "date":
out.Values[i] = ec._TimelineGroup_date(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var userImplementors = []string{"User"}
func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj *models.User) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, userImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("User")
case "id":
out.Values[i] = ec._User_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "username":
out.Values[i] = ec._User_username(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
case "albums":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._User_albums(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "rootAlbums":
field := field
innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._User_rootAlbums(ctx, field, obj)
if res == graphql.Null {
atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
if field.Deferrable != nil {
dfs, ok := deferred[field.Deferrable.Label]
di := 0
if ok {
dfs.AddField(field)
di = len(dfs.Values) - 1
} else {
dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
deferred[field.Deferrable.Label] = dfs
}
dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
return innerFunc(ctx, dfs)
})
// don't run the out.Concurrently() call below
out.Values[i] = graphql.Null
continue
}
out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "admin":
out.Values[i] = ec._User_admin(ctx, field, obj)
if out.Values[i] == graphql.Null {
atomic.AddUint32(&out.Invalids, 1)
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var userPreferencesImplementors = []string{"UserPreferences"}
func (ec *executionContext) _UserPreferences(ctx context.Context, sel ast.SelectionSet, obj *models.UserPreferences) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, userPreferencesImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("UserPreferences")
case "id":
out.Values[i] = ec._UserPreferences_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "language":
out.Values[i] = ec._UserPreferences_language(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var videoMetadataImplementors = []string{"VideoMetadata"}
func (ec *executionContext) _VideoMetadata(ctx context.Context, sel ast.SelectionSet, obj *models.VideoMetadata) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, videoMetadataImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("VideoMetadata")
case "id":
out.Values[i] = ec._VideoMetadata_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "media":
out.Values[i] = ec._VideoMetadata_media(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "width":
out.Values[i] = ec._VideoMetadata_width(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "height":
out.Values[i] = ec._VideoMetadata_height(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "duration":
out.Values[i] = ec._VideoMetadata_duration(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "codec":
out.Values[i] = ec._VideoMetadata_codec(ctx, field, obj)
case "framerate":
out.Values[i] = ec._VideoMetadata_framerate(ctx, field, obj)
case "bitrate":
out.Values[i] = ec._VideoMetadata_bitrate(ctx, field, obj)
case "colorProfile":
out.Values[i] = ec._VideoMetadata_colorProfile(ctx, field, obj)
case "audio":
out.Values[i] = ec._VideoMetadata_audio(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var __DirectiveImplementors = []string{"__Directive"}
func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionSet, obj *introspection.Directive) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __DirectiveImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Directive")
case "name":
out.Values[i] = ec.___Directive_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "description":
out.Values[i] = ec.___Directive_description(ctx, field, obj)
case "isRepeatable":
out.Values[i] = ec.___Directive_isRepeatable(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "locations":
out.Values[i] = ec.___Directive_locations(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "args":
out.Values[i] = ec.___Directive_args(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var __EnumValueImplementors = []string{"__EnumValue"}
func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.EnumValue) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __EnumValueImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__EnumValue")
case "name":
out.Values[i] = ec.___EnumValue_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "description":
out.Values[i] = ec.___EnumValue_description(ctx, field, obj)
case "isDeprecated":
out.Values[i] = ec.___EnumValue_isDeprecated(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "deprecationReason":
out.Values[i] = ec.___EnumValue_deprecationReason(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var __FieldImplementors = []string{"__Field"}
func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, obj *introspection.Field) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __FieldImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Field")
case "name":
out.Values[i] = ec.___Field_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "description":
out.Values[i] = ec.___Field_description(ctx, field, obj)
case "args":
out.Values[i] = ec.___Field_args(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "type":
out.Values[i] = ec.___Field_type(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "isDeprecated":
out.Values[i] = ec.___Field_isDeprecated(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "deprecationReason":
out.Values[i] = ec.___Field_deprecationReason(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var __InputValueImplementors = []string{"__InputValue"}
func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.InputValue) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __InputValueImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__InputValue")
case "name":
out.Values[i] = ec.___InputValue_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "description":
out.Values[i] = ec.___InputValue_description(ctx, field, obj)
case "type":
out.Values[i] = ec.___InputValue_type(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "defaultValue":
out.Values[i] = ec.___InputValue_defaultValue(ctx, field, obj)
case "isDeprecated":
out.Values[i] = ec.___InputValue_isDeprecated(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "deprecationReason":
out.Values[i] = ec.___InputValue_deprecationReason(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var __SchemaImplementors = []string{"__Schema"}
func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet, obj *introspection.Schema) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __SchemaImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Schema")
case "description":
out.Values[i] = ec.___Schema_description(ctx, field, obj)
case "types":
out.Values[i] = ec.___Schema_types(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "queryType":
out.Values[i] = ec.___Schema_queryType(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "mutationType":
out.Values[i] = ec.___Schema_mutationType(ctx, field, obj)
case "subscriptionType":
out.Values[i] = ec.___Schema_subscriptionType(ctx, field, obj)
case "directives":
out.Values[i] = ec.___Schema_directives(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
var __TypeImplementors = []string{"__Type"}
func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, obj *introspection.Type) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __TypeImplementors)
out := graphql.NewFieldSet(fields)
deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Type")
case "kind":
out.Values[i] = ec.___Type_kind(ctx, field, obj)
if out.Values[i] == graphql.Null {
out.Invalids++
}
case "name":
out.Values[i] = ec.___Type_name(ctx, field, obj)
case "description":
out.Values[i] = ec.___Type_description(ctx, field, obj)
case "specifiedByURL":
out.Values[i] = ec.___Type_specifiedByURL(ctx, field, obj)
case "fields":
out.Values[i] = ec.___Type_fields(ctx, field, obj)
case "interfaces":
out.Values[i] = ec.___Type_interfaces(ctx, field, obj)
case "possibleTypes":
out.Values[i] = ec.___Type_possibleTypes(ctx, field, obj)
case "enumValues":
out.Values[i] = ec.___Type_enumValues(ctx, field, obj)
case "inputFields":
out.Values[i] = ec.___Type_inputFields(ctx, field, obj)
case "ofType":
out.Values[i] = ec.___Type_ofType(ctx, field, obj)
case "isOneOf":
out.Values[i] = ec.___Type_isOneOf(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch(ctx)
if out.Invalids > 0 {
return graphql.Null
}
atomic.AddInt32(&ec.Deferred, int32(min(len(deferred), math.MaxInt32)))
for label, dfs := range deferred {
ec.ProcessDeferredGroup(graphql.DeferredGroup{
Label: label,
Path: graphql.GetPath(ctx),
FieldSet: dfs,
Context: ctx,
})
}
return out
}
// endregion **************************** object.gotpl ****************************
// region ***************************** type.gotpl *****************************
func (ec *executionContext) marshalNAlbum2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx context.Context, sel ast.SelectionSet, v models.Album) graphql.Marshaler {
return ec._Album(ctx, sel, &v)
}
func (ec *executionContext) marshalNAlbum2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbumᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.Album) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalNAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx context.Context, sel ast.SelectionSet, v *models.Album) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._Album(ctx, sel, v)
}
func (ec *executionContext) unmarshalNAny2interface(ctx context.Context, v any) (any, error) {
res, err := graphql.UnmarshalAny(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNAny2interface(ctx context.Context, sel ast.SelectionSet, v any) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
_ = sel
res := graphql.MarshalAny(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) marshalNAuthorizeResult2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAuthorizeResult(ctx context.Context, sel ast.SelectionSet, v models.AuthorizeResult) graphql.Marshaler {
return ec._AuthorizeResult(ctx, sel, &v)
}
func (ec *executionContext) marshalNAuthorizeResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAuthorizeResult(ctx context.Context, sel ast.SelectionSet, v *models.AuthorizeResult) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._AuthorizeResult(ctx, sel, v)
}
func (ec *executionContext) unmarshalNBoolean2bool(ctx context.Context, v any) (bool, error) {
res, err := graphql.UnmarshalBoolean(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler {
_ = sel
res := graphql.MarshalBoolean(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) marshalNFaceGroup2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx context.Context, sel ast.SelectionSet, v models.FaceGroup) graphql.Marshaler {
return ec._FaceGroup(ctx, sel, &v)
}
func (ec *executionContext) marshalNFaceGroup2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroupᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.FaceGroup) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNFaceGroup2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceGroup(ctx context.Context, sel ast.SelectionSet, v *models.FaceGroup) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._FaceGroup(ctx, sel, v)
}
func (ec *executionContext) marshalNFaceRectangle2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐFaceRectangle(ctx context.Context, sel ast.SelectionSet, v models.FaceRectangle) graphql.Marshaler {
return ec._FaceRectangle(ctx, sel, &v)
}
func (ec *executionContext) unmarshalNFloat2float64(ctx context.Context, v any) (float64, error) {
res, err := graphql.UnmarshalFloatContext(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNFloat2float64(ctx context.Context, sel ast.SelectionSet, v float64) graphql.Marshaler {
_ = sel
res := graphql.MarshalFloatContext(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return graphql.WrapContextMarshaler(ctx, res)
}
func (ec *executionContext) unmarshalNID2int(ctx context.Context, v any) (int, error) {
res, err := graphql.UnmarshalIntID(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNID2int(ctx context.Context, sel ast.SelectionSet, v int) graphql.Marshaler {
_ = sel
res := graphql.MarshalIntID(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) unmarshalNID2ᚕintᚄ(ctx context.Context, v any) ([]int, error) {
var vSlice []any
vSlice = graphql.CoerceList(v)
var err error
res := make([]int, len(vSlice))
for i := range vSlice {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i))
res[i], err = ec.unmarshalNID2int(ctx, vSlice[i])
if err != nil {
return nil, err
}
}
return res, nil
}
func (ec *executionContext) marshalNID2ᚕintᚄ(ctx context.Context, sel ast.SelectionSet, v []int) graphql.Marshaler {
ret := make(graphql.Array, len(v))
for i := range v {
ret[i] = ec.marshalNID2int(ctx, sel, v[i])
}
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNImageFace2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐImageFaceᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.ImageFace) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalNImageFace2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐImageFace(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNImageFace2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐImageFace(ctx context.Context, sel ast.SelectionSet, v *models.ImageFace) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._ImageFace(ctx, sel, v)
}
func (ec *executionContext) unmarshalNInt2int(ctx context.Context, v any) (int, error) {
res, err := graphql.UnmarshalInt(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNInt2int(ctx context.Context, sel ast.SelectionSet, v int) graphql.Marshaler {
_ = sel
res := graphql.MarshalInt(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) unmarshalNInt2int64(ctx context.Context, v any) (int64, error) {
res, err := graphql.UnmarshalInt64(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNInt2int64(ctx context.Context, sel ast.SelectionSet, v int64) graphql.Marshaler {
_ = sel
res := graphql.MarshalInt64(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) marshalNMedia2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx context.Context, sel ast.SelectionSet, v models.Media) graphql.Marshaler {
return ec._Media(ctx, sel, &v)
}
func (ec *executionContext) marshalNMedia2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.Media) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalNMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx context.Context, sel ast.SelectionSet, v *models.Media) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._Media(ctx, sel, v)
}
func (ec *executionContext) marshalNMediaDownload2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaDownloadᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.MediaDownload) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalNMediaDownload2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaDownload(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNMediaDownload2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaDownload(ctx context.Context, sel ast.SelectionSet, v *models.MediaDownload) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._MediaDownload(ctx, sel, v)
}
func (ec *executionContext) unmarshalNMediaType2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaType(ctx context.Context, v any) (models.MediaType, error) {
tmp, err := graphql.UnmarshalString(v)
res := models.MediaType(tmp)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNMediaType2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaType(ctx context.Context, sel ast.SelectionSet, v models.MediaType) graphql.Marshaler {
_ = sel
res := graphql.MarshalString(string(v))
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) marshalNMediaURL2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaURL(ctx context.Context, sel ast.SelectionSet, v *models.MediaURL) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._MediaURL(ctx, sel, v)
}
func (ec *executionContext) marshalNNotification2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐNotification(ctx context.Context, sel ast.SelectionSet, v models.Notification) graphql.Marshaler {
return ec._Notification(ctx, sel, &v)
}
func (ec *executionContext) marshalNNotification2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐNotification(ctx context.Context, sel ast.SelectionSet, v *models.Notification) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._Notification(ctx, sel, v)
}
func (ec *executionContext) unmarshalNNotificationType2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐNotificationType(ctx context.Context, v any) (models.NotificationType, error) {
var res models.NotificationType
err := res.UnmarshalGQL(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNNotificationType2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐNotificationType(ctx context.Context, sel ast.SelectionSet, v models.NotificationType) graphql.Marshaler {
return v
}
func (ec *executionContext) marshalNScannerResult2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐScannerResult(ctx context.Context, sel ast.SelectionSet, v models.ScannerResult) graphql.Marshaler {
return ec._ScannerResult(ctx, sel, &v)
}
func (ec *executionContext) marshalNScannerResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐScannerResult(ctx context.Context, sel ast.SelectionSet, v *models.ScannerResult) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._ScannerResult(ctx, sel, v)
}
func (ec *executionContext) marshalNSearchResult2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐSearchResult(ctx context.Context, sel ast.SelectionSet, v models.SearchResult) graphql.Marshaler {
return ec._SearchResult(ctx, sel, &v)
}
func (ec *executionContext) marshalNSearchResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐSearchResult(ctx context.Context, sel ast.SelectionSet, v *models.SearchResult) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._SearchResult(ctx, sel, v)
}
func (ec *executionContext) marshalNShareToken2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx context.Context, sel ast.SelectionSet, v models.ShareToken) graphql.Marshaler {
return ec._ShareToken(ctx, sel, &v)
}
func (ec *executionContext) marshalNShareToken2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.ShareToken) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNShareToken2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareToken(ctx context.Context, sel ast.SelectionSet, v *models.ShareToken) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._ShareToken(ctx, sel, v)
}
func (ec *executionContext) unmarshalNShareTokenCredentials2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenCredentials(ctx context.Context, v any) (models.ShareTokenCredentials, error) {
res, err := ec.unmarshalInputShareTokenCredentials(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNSiteInfo2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐSiteInfo(ctx context.Context, sel ast.SelectionSet, v models.SiteInfo) graphql.Marshaler {
return ec._SiteInfo(ctx, sel, &v)
}
func (ec *executionContext) marshalNSiteInfo2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐSiteInfo(ctx context.Context, sel ast.SelectionSet, v *models.SiteInfo) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._SiteInfo(ctx, sel, v)
}
func (ec *executionContext) unmarshalNString2string(ctx context.Context, v any) (string, error) {
res, err := graphql.UnmarshalString(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
_ = sel
res := graphql.MarshalString(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) unmarshalNTime2timeᚐTime(ctx context.Context, v any) (time.Time, error) {
res, err := graphql.UnmarshalTime(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNTime2timeᚐTime(ctx context.Context, sel ast.SelectionSet, v time.Time) graphql.Marshaler {
_ = sel
res := graphql.MarshalTime(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) marshalNUser2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx context.Context, sel ast.SelectionSet, v models.User) graphql.Marshaler {
return ec._User(ctx, sel, &v)
}
func (ec *executionContext) marshalNUser2ᚕᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUserᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.User) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalNUser2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalNUser2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUser(ctx context.Context, sel ast.SelectionSet, v *models.User) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._User(ctx, sel, v)
}
func (ec *executionContext) marshalNUserPreferences2githubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUserPreferences(ctx context.Context, sel ast.SelectionSet, v models.UserPreferences) graphql.Marshaler {
return ec._UserPreferences(ctx, sel, &v)
}
func (ec *executionContext) marshalNUserPreferences2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐUserPreferences(ctx context.Context, sel ast.SelectionSet, v *models.UserPreferences) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec._UserPreferences(ctx, sel, v)
}
func (ec *executionContext) marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v introspection.Directive) graphql.Marshaler {
return ec.___Directive(ctx, sel, &v)
}
func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Directive) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) unmarshalN__DirectiveLocation2string(ctx context.Context, v any) (string, error) {
res, err := graphql.UnmarshalString(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
_ = sel
res := graphql.MarshalString(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, v any) ([]string, error) {
var vSlice []any
vSlice = graphql.CoerceList(v)
var err error
res := make([]string, len(vSlice))
for i := range vSlice {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i))
res[i], err = ec.unmarshalN__DirectiveLocation2string(ctx, vSlice[i])
if err != nil {
return nil, err
}
}
return res, nil
}
func (ec *executionContext) marshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__DirectiveLocation2string(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v introspection.EnumValue) graphql.Marshaler {
return ec.___EnumValue(ctx, sel, &v)
}
func (ec *executionContext) marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v introspection.Field) graphql.Marshaler {
return ec.___Field(ctx, sel, &v)
}
func (ec *executionContext) marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v introspection.InputValue) graphql.Marshaler {
return ec.___InputValue(ctx, sel, &v)
}
func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler {
return ec.___Type(ctx, sel, &v)
}
func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
return graphql.Null
}
return ec.___Type(ctx, sel, v)
}
func (ec *executionContext) unmarshalN__TypeKind2string(ctx context.Context, v any) (string, error) {
res, err := graphql.UnmarshalString(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
_ = sel
res := graphql.MarshalString(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
graphql.AddErrorf(ctx, "the requested element is null which the schema does not allow")
}
}
return res
}
func (ec *executionContext) marshalOAlbum2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAlbum(ctx context.Context, sel ast.SelectionSet, v *models.Album) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec._Album(ctx, sel, v)
}
func (ec *executionContext) marshalOAuthorizeResult2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐAuthorizeResult(ctx context.Context, sel ast.SelectionSet, v *models.AuthorizeResult) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec._AuthorizeResult(ctx, sel, v)
}
func (ec *executionContext) unmarshalOBoolean2bool(ctx context.Context, v any) (bool, error) {
res, err := graphql.UnmarshalBoolean(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler {
_ = sel
_ = ctx
res := graphql.MarshalBoolean(v)
return res
}
func (ec *executionContext) unmarshalOBoolean2ᚖbool(ctx context.Context, v any) (*bool, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalBoolean(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast.SelectionSet, v *bool) graphql.Marshaler {
if v == nil {
return graphql.Null
}
_ = sel
_ = ctx
res := graphql.MarshalBoolean(*v)
return res
}
func (ec *executionContext) marshalOCoordinates2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐCoordinates(ctx context.Context, sel ast.SelectionSet, v *models.Coordinates) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec._Coordinates(ctx, sel, v)
}
func (ec *executionContext) unmarshalOFloat2ᚖfloat64(ctx context.Context, v any) (*float64, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalFloatContext(ctx, v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOFloat2ᚖfloat64(ctx context.Context, sel ast.SelectionSet, v *float64) graphql.Marshaler {
if v == nil {
return graphql.Null
}
_ = sel
res := graphql.MarshalFloatContext(*v)
return graphql.WrapContextMarshaler(ctx, res)
}
func (ec *executionContext) unmarshalOInt2ᚖint(ctx context.Context, v any) (*int, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalInt(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOInt2ᚖint(ctx context.Context, sel ast.SelectionSet, v *int) graphql.Marshaler {
if v == nil {
return graphql.Null
}
_ = sel
_ = ctx
res := graphql.MarshalInt(*v)
return res
}
func (ec *executionContext) unmarshalOInt2ᚖint64(ctx context.Context, v any) (*int64, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalInt64(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOInt2ᚖint64(ctx context.Context, sel ast.SelectionSet, v *int64) graphql.Marshaler {
if v == nil {
return graphql.Null
}
_ = sel
_ = ctx
res := graphql.MarshalInt64(*v)
return res
}
func (ec *executionContext) unmarshalOLanguageTranslation2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐLanguageTranslation(ctx context.Context, v any) (*models.LanguageTranslation, error) {
if v == nil {
return nil, nil
}
var res = new(models.LanguageTranslation)
err := res.UnmarshalGQL(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOLanguageTranslation2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐLanguageTranslation(ctx context.Context, sel ast.SelectionSet, v *models.LanguageTranslation) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return v
}
func (ec *executionContext) marshalOMedia2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMedia(ctx context.Context, sel ast.SelectionSet, v *models.Media) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec._Media(ctx, sel, v)
}
func (ec *executionContext) marshalOMediaEXIF2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaEXIF(ctx context.Context, sel ast.SelectionSet, v *models.MediaEXIF) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec._MediaEXIF(ctx, sel, v)
}
func (ec *executionContext) marshalOMediaURL2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐMediaURL(ctx context.Context, sel ast.SelectionSet, v *models.MediaURL) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec._MediaURL(ctx, sel, v)
}
func (ec *executionContext) unmarshalOOrderDirection2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrderDirection(ctx context.Context, v any) (*models.OrderDirection, error) {
if v == nil {
return nil, nil
}
var res = new(models.OrderDirection)
err := res.UnmarshalGQL(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOOrderDirection2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrderDirection(ctx context.Context, sel ast.SelectionSet, v *models.OrderDirection) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return v
}
func (ec *executionContext) unmarshalOOrdering2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐOrdering(ctx context.Context, v any) (*models.Ordering, error) {
if v == nil {
return nil, nil
}
res, err := ec.unmarshalInputOrdering(ctx, v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalOPagination2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐPagination(ctx context.Context, v any) (*models.Pagination, error) {
if v == nil {
return nil, nil
}
res, err := ec.unmarshalInputPagination(ctx, v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalOShareTokenCredentials2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐShareTokenCredentials(ctx context.Context, v any) (*models.ShareTokenCredentials, error) {
if v == nil {
return nil, nil
}
res, err := ec.unmarshalInputShareTokenCredentials(ctx, v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalOString2ᚖstring(ctx context.Context, v any) (*string, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalString(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOString2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler {
if v == nil {
return graphql.Null
}
_ = sel
_ = ctx
res := graphql.MarshalString(*v)
return res
}
func (ec *executionContext) unmarshalOTime2ᚖtimeᚐTime(ctx context.Context, v any) (*time.Time, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalTime(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOTime2ᚖtimeᚐTime(ctx context.Context, sel ast.SelectionSet, v *time.Time) graphql.Marshaler {
if v == nil {
return graphql.Null
}
_ = sel
_ = ctx
res := graphql.MarshalTime(*v)
return res
}
func (ec *executionContext) marshalOVideoMetadata2ᚖgithubᚗcomᚋphotoviewᚋphotoviewᚋapiᚋgraphqlᚋmodelsᚐVideoMetadata(ctx context.Context, sel ast.SelectionSet, v *models.VideoMetadata) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec._VideoMetadata(ctx, sel, v)
}
func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Field) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v *introspection.Schema) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec.___Schema(ctx, sel, v)
}
func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := graphql.MarshalSliceConcurrently(ctx, len(v), 0, false, func(ctx context.Context, i int) graphql.Marshaler {
fc := graphql.GetFieldContext(ctx)
fc.Result = &v[i]
return ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
})
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec.___Type(ctx, sel, v)
}
// endregion ***************************** type.gotpl *****************************