Documentation ¶
Index ¶
Constants ¶
View Source
const ( NsContent = "https://content.deichman.no/ontology/" NsKatalog = "http://data.deichman.no/ontology#" NsTjenester = "https://tjenester.deichman.no/ontology/" GraphTjenester = "https://tjenester.deichman.no" GraphKatalog = "https://katalog.deichman.no" GraphContent = "https://content.deichman.no" )
Variables ¶
View Source
var ( // katalog CompositionType = newResourceType("CompositionType", GraphKatalog, NsKatalog) Corporation = newResourceType("Corporation", GraphKatalog, NsKatalog) Event = newResourceType("Event", GraphKatalog, NsKatalog) Genre = newResourceType("Genre", GraphKatalog, NsKatalog) Instrument = newResourceType("Instrument", GraphKatalog, NsKatalog) Person = newResourceType("Person", GraphKatalog, NsKatalog) Place = newResourceType("Place", GraphKatalog, NsKatalog) Publication = newResourceType("Publication", GraphKatalog, NsKatalog) Serial = newResourceType("Serial", GraphKatalog, NsKatalog) Subject = newResourceType("Subject", GraphKatalog, NsKatalog) Work = newResourceType("Work", GraphKatalog, NsKatalog) WorkSeries = newResourceType("WorkSeries", GraphKatalog, NsKatalog) // tjenester Branch = newResourceType("Branch", GraphTjenester, NsTjenester) Campaign = newResourceType("Campaign", GraphTjenester, NsTjenester) Editor = newResourceType("Editor", GraphContent, NsKatalog) Floor = newResourceType("Floor", GraphTjenester, NsTjenester) LibraryEventInstance = newResourceType("LibraryEventInstance", GraphTjenester, NsTjenester) Page = newResourceType("Page", GraphTjenester, NsTjenester) Room = newResourceType("Room", GraphTjenester, NsTjenester) Service = newResourceType("Service", GraphTjenester, NsTjenester) AudioVideo = newResourceType("AudioVideo", GraphTjenester, NsTjenester) // content Like = newResourceType("Like", GraphContent, NsContent) Recommendation = newResourceType("Recommendation", GraphContent, NsContent) PublicationList = newResourceType("PublicationList", GraphContent, NsContent) )
View Source
var AllResourceTypes = []ResourceType{ AudioVideo, Page, Branch, Campaign, CompositionType, Corporation, Event, Editor, Floor, Genre, Instrument, LibraryEventInstance, Like, Person, Place, Publication, PublicationList, Recommendation, Room, Serial, Service, Subject, Work, WorkSeries, }
Functions ¶
func GetTypeAndIdFromURI ¶
assumes URIs on the form http://data.deichman.no/type/id (which holds for authorities that are not authorized values)
Types ¶
type ProcessingReq ¶
type ProcessingReq struct { URI string Type ResourceType Fields log.Fields }
func NewProcessingReq ¶
func NewProcessingReq(uri string, fields log.Fields) (ProcessingReq, error)
type ResourceType ¶
type ResourceType struct { Name string // used in type IRIs, i.e. 'CompositionType' InstanceName string // used in instance IRIS, i.e. 'compositionType' Graph string // which graph the type is located in Ns string // which namespace the type is located in, i.e. 'http://data.deichman.no/ontology#' }
func FromType ¶
func FromType(typeName string) (ResourceType, error)
func (ResourceType) TypeUri ¶
func (r ResourceType) TypeUri() string
Click to show internal directories.
Click to hide internal directories.