model

package
v2.0.12 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2026 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Relator = map[string]string{}/* 303 elements not displayed */

Functions

This section is empty.

Types

type Book

type Book struct {
	Metadata  Metadata
	Container Container
	ZipReader *zip.Reader
}

func (*Book) Open

func (book *Book) Open(fileName string) (io.ReadCloser, error)

func (*Book) ReadXML

func (book *Book) ReadXML(fileName string, targetStruct interface{}) error

type Container

type Container struct {
	Rootfile Rootfile `xml:"rootfiles>rootfile"`
}

type Creator

type Creator struct {
	Name     string
	Language string
	FileAs   string
	Role     string
	RawRole  string
}

type DefaultAttributes

type DefaultAttributes struct {
	Text     string
	Language string
}

type Identifier

type Identifier struct {
	Id     string
	Scheme string
}

type Metadata

type Metadata struct {
	MainId       Identifier
	Titles       *[]Title
	Identifiers  *[]Identifier
	Languages    *[]string
	Creators     *[]Creator
	Contributors *[]Creator
	Publishers   *[]DefaultAttributes
	Subjects     *[]DefaultAttributes
	Descriptions *[]DefaultAttributes
	Dates        *[]string
}

type Package

type Package struct {
	Version          string `xml:"version,attr"`
	UniqueIdentifier string `xml:"unique-identifier,attr"`
	ID               string `xml:"id,attr,omitempty"`
	Prefix           string `xml:"prefix,attr,omitempty"`
	Lang             string `xml:"lang,attr,omitempty"`
	Dir              string `xml:"dir,attr,omitempty"`
}

type Rootfile

type Rootfile struct {
	Path string `xml:"full-path,attr"`
	Type string `xml:"media-type,attr"`
}

type Title

type Title struct {
	Title    string
	Language string
	Type     string
	FileAs   string
}

Jump to

Keyboard shortcuts

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