stabi

package
v0.7.3-alpha Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2016 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Overview

Package stabi contains all the implementations for the pictures of Staats- und Universitaets Bibliothek Hamburg It links the XML representation to the data structures.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetPicture

func GetPicture(fpath string, pdb data.PersonDBer) (*data.Picture, error)

GetPicture maps the data of the mods xml to the data.Picture and returns a pointer to the created pic

func NewDataPicture

func NewDataPicture(m *mods.Mets, pdb data.PersonDBer) *data.Picture

NewDataPicture is an adapter from mods structure to picture

Types

type Data

type Data struct {
	Folder      string
	DataFileExt string
	Pictures    []data.Picture
	PersonDB    data.PersonDBer
}

func NewData

func NewData(p string, pdb data.PersonDBer) *Data

NewData creates a pointer to a Data element with a given path

func (*Data) List

func (d *Data) List() (*[]data.Picture, error)

List creates a list of pictures with the original data given by the stabi

func (*Data) LoadPictures

func (d *Data) LoadPictures()

LoadPictures loads the pictures from data folder. For loading the pictures the data.LoadType function is used.

func (*Data) Save

func (d *Data) Save(root string) error

Save stores the list into the root folder

func (*Data) SaveTiffAsJpg

func (d *Data) SaveTiffAsJpg(root string) error

SaveTiffAsJpg takes the tiff pictures and saves them inside the data folder as jpg

Jump to

Keyboard shortcuts

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