amslutil

package
v0.1.280 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2019 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Overview

Package amslutil provides helpers for accessing AMSL API.

For visibility decision we need:

* ISIL, SID, collection (name or id) * ISIL and list of serial numbers

AMSL is in transition from v1 (OW) to v2 (FO). Below v1 only.

MU -> tcid MU -> isil HF[isil] -> LinkToFile (KBART), or DokumentURI

MU

{
  "sourceID": "14",
  "megaCollection": "RISM",
  "productISIL": null,
  "technicalCollectionID": "sid-14-col-rism",
  "ISIL": "DE-D117",
  "shardLabel": "UBL-main"
}

MUC

{
  "sourceID": "26",
  "megaCollection": "DOAB Directory of Open Access Books",
  "productISIL": "ZDB-119-KEO",
  "technicalCollectionID": "sid-26-col-doab",
  "ISIL": "DE-14;DE-15;DE-15-FID;DE-540;DE-Ch1;DE-D117;DE-L242",
  "shardLabel": "UBL-main"
}

HF

{
  "ISIL": "DE-15-FID",
  "DokumentLabel": "FID_ISSN_Filter",
  "DokumentURI": "http://amsl.technology/discovery/metadata-usage/Dokument/FID_ISSN_Filter",
  "LinkToFile": "https://live.amsl.technology/OntoWiki/files/get?setResource=http://amsl.technology/discovery/metadata-usage/Dokument/FID_ISSN_Filter"
}

HFC

{
  "sourceID": "17",
  "megaCollection": "Oxford Journals Digital Archive 1849-2010",
  "productISIL": "ZDB-1-OJD",
  "technicalCollectionID": null,
  "ISIL": "DE-105",
  "shardLabel": "UBL-main"
}

CF

{
  "technicalCollectionID": "zdb-39-joa",
  "megaCollection": "JSTOR Film and Performing Arts",
  "contentFileLabel": "JSTOR Film and Performing Arts KBART",
  "contentFileURI": "http://amsl.technology/discovery/Dokument/JSTOR_Film_and_Performing_Arts_KBART",
  "linkToContentFile": null
}

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Amsl

type Amsl struct {
	Server string
}

Amsl endpoint.

func (*Amsl) ContentFiles

func (amsl *Amsl) ContentFiles() ([]ContentFile, error)

ContentFile endpoint.

func (*Amsl) HoldingsFileConcat

func (amsl *Amsl) HoldingsFileConcat() ([]HoldingsFileConcat, error)

HoldingsFileConcat endpoint.

func (*Amsl) HoldingsFiles

func (amsl *Amsl) HoldingsFiles() ([]HoldingsFile, error)

HoldingsFile endpoint.

func (*Amsl) MetadataUsage

func (amsl *Amsl) MetadataUsage() ([]MetadataUsage, error)

MetadataUsage endpoint.

func (*Amsl) MetadataUsageConcat

func (amsl *Amsl) MetadataUsageConcat() ([]MetadataUsage, error)

MetadataUsageConcat endpoint.

func (amsl *Amsl) ResourceDownloadLink(uri string) string

ResourceDownloadLink turns a resource URI into a download link. The URI is not escaped.

type ContentFile

type ContentFile struct {
	ContentFileLabel      string `json:"contentFileLabel"`
	ContentFileURI        string `json:"contentFileURI"`
	LinkToContentFile     string `json:"linkToContentFile"`
	MegaCollection        string `json:"megaCollection"`
	TechnicalCollectionID string `json:"technicalCollectionID"`
}

ContentFile is a single entry in the contentfile endpoint.

type HoldingsFile

type HoldingsFile struct {
	DokumentLabel string
	DokumentURI   string
	ISIL          string
	LinkToFile    string
}

HoldingsFile is a single entry in the holdingsfiles endpoint.

type HoldingsFileConcat

type HoldingsFileConcat struct {
	ISIL                  string
	MegaCollection        string `json:"megaCollection"`
	ProductISIL           string `json:"productISIL"`
	ShardLabel            string `json:"shardLabel"`
	SourceID              string `json:"sourceID"`
	TechnicalCollectionID string `json:"technicalCollectionID"`
}

HoldingsFileConcat is a single entry in the holdings_file_concat (testing) endpoint.

type MetadataUsage

type MetadataUsage struct {
	ISIL                  string
	MegaCollection        string `json:"megaCollection"`
	ProductISIL           string `json:"productISIL"`
	ShardLabel            string `json:"shardLabel"`
	SourceID              string `json:"sourceID"`
	TechnicalCollectionID string `json:"technicalCollectionID"`
}

MetadataUsage is a single entry from the MetadataUsage endpoint.

Jump to

Keyboard shortcuts

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