piwigo

package
v0.0.0-...-f8104de Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2023 License: GPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ImageStateUptodate  = 0
	ImageStateDifferent = 1
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Category

type Category struct {
	Id       int
	ParentId int
	Name     string
	Key      string
}

type CategoryApi

type CategoryApi interface {
	GetAllCategories() (map[string]*Category, error)
	CreateCategory(parentId int, name string) (int, error)
}

type ImageApi

type ImageApi interface {
	ImageCheckFile(piwigoId int, md5sum string) (int, error)
	ImagesExistOnPiwigo(md5sums []string) (map[string]int, error)
	UploadImage(piwigoId int, filePath string, md5sum string, category int) (int, error)
	DeleteImages(imageIds []int) error
}

type ServerContext

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

func (*ServerContext) CreateCategory

func (context *ServerContext) CreateCategory(parentId int, name string) (int, error)

func (*ServerContext) DeleteImages

func (context *ServerContext) DeleteImages(imageIds []int) error

func (*ServerContext) GetAllCategories

func (context *ServerContext) GetAllCategories() (map[string]*Category, error)

func (*ServerContext) ImageCheckFile

func (context *ServerContext) ImageCheckFile(piwigoId int, md5sum string) (int, error)

func (*ServerContext) ImagesExistOnPiwigo

func (context *ServerContext) ImagesExistOnPiwigo(md5sums []string) (map[string]int, error)

func (*ServerContext) Initialize

func (context *ServerContext) Initialize(baseUrl string, username string, password string) error

func (*ServerContext) Login

func (context *ServerContext) Login() error

func (*ServerContext) Logout

func (context *ServerContext) Logout() error

func (*ServerContext) UploadImage

func (context *ServerContext) UploadImage(piwigoId int, filePath string, md5sum string, category int) (int, error)

Jump to

Keyboard shortcuts

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