Documentation ¶
Overview ¶
Package kbart implements support for KBART (Knowledge Bases And Related Tools working group, http://www.uksg.org/kbart/) holding files (http://www.uksg.org/kbart/s5/guidelines/data_format).
> This is a generic format that minimizes the effort involved in receiving and loading the data, and reduces the likelihood of errors being introduced during exchange. Tab-delimited formats are preferable to comma-separated formats, as commas appear regularly within the distributed data and, though they can be "commented out", doing so leaves a greater opportunity for error than the use of a tab-delimited format. Tab-delimited formats can be easily exported from all commonly used spreadsheet programs.
Index ¶
- type Holdings
- func (h *Holdings) Filter(f func(licensing.Entry) bool) (result []licensing.Entry)
- func (h *Holdings) ReadFrom(r io.Reader) (int64, error)
- func (h *Holdings) SerialNumberMap() map[string][]licensing.Entry
- func (h *Holdings) TitleMap() map[string][]licensing.Entry
- func (h *Holdings) WisoDatabaseMap() map[string][]licensing.Entry
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Holdings ¶
Holdings contains a list of entries about licenced or available content. In addition to access to all entries, this type exposes a couple of helper methods.
func (*Holdings) Filter ¶
Filter finds entries with certain characteristics. This will be slow for KBART files with thousands of entries.
func (*Holdings) ReadFrom ¶
ReadFrom create holdings struct from a reader. Expects tab separated content with a single header row.
func (*Holdings) SerialNumberMap ¶
SerialNumberMap creates a map from ISSN to associated licensing entries. This is here for performance mostly, so we can access relevant licensing entry by ISSN. XXX: Do not replicate entries, just index into them.