dasmaps

package
v0.0.0-...-fd40de8 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2024 License: MIT Imports: 12 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetDASMaps

func GetDASMaps(entry interface{}) []mongo.DASRecord

GetDASMaps returns das maps for given entry

func GetFloat

func GetFloat(dmap mongo.DASRecord, key string) float64

GetFloat provides value from DAS map for a given key

func GetInt

func GetInt(dmap mongo.DASRecord, key string) int

GetInt provides value from DAS map for a given key

func GetNotation

func GetNotation(nmap mongo.DASRecord) (string, string, string)

GetNotation provides values from notation map

func GetString

func GetString(dmap mongo.DASRecord, key string) string

GetString provides value from DAS map for a given key

func MapInList

func MapInList(a mongo.DASRecord, list []mongo.DASRecord) bool

MapInList helper functions check if given map exists in given list

Types

type DASKeysMap

type DASKeysMap struct {
	Key           string
	Description   string
	Examples      []string
	Relationships []string
}

DASKeysMap keesp track of das keys and their attributes

type DASMaps

type DASMaps struct {
	// contains filtered or unexported fields
}

DASMaps structure holds all information about DAS records

func (*DASMaps) AssignServices

func (m *DASMaps) AssignServices(services []string)

AssignServices assigns given services to dasmaps

func (*DASMaps) ChangeUrl

func (m *DASMaps) ChangeUrl(old, pat string)

ChangeUrl changes url of dasmaps from old to new pattern

func (*DASMaps) DASKeys

func (m *DASMaps) DASKeys() []string

DASKeys provides list of DAS keys

func (*DASMaps) DASKeysMaps

func (m *DASMaps) DASKeysMaps() []DASKeysMap

DASKeysMaps provides presentation map of DAS maps

func (*DASMaps) DBSInstance

func (m *DASMaps) DBSInstance() string

helper function to get DBS instance from DBS maps

func (*DASMaps) FindApiRecord

func (m *DASMaps) FindApiRecord(system, urn string) mongo.DASRecord

FindApiRecord finds DAS API record

func (*DASMaps) FindNotations

func (m *DASMaps) FindNotations(system string) []mongo.DASRecord

FindNotations provides notation maps for given system

func (*DASMaps) FindPresentation

func (m *DASMaps) FindPresentation(daskey string) []mongo.DASRecord

FindPresentation returns presentations for given das key

func (*DASMaps) FindServices

func (m *DASMaps) FindServices(dasquery dasql.DASQuery) []mongo.DASRecord

FindServices look-up DAS services for given set fields and spec pair, return DAS maps associated with found services

func (*DASMaps) GetUrl

func (m *DASMaps) GetUrl(s string) string

GetUrl provides url from das maps for a given service name

func (*DASMaps) LoadMaps

func (m *DASMaps) LoadMaps(dbname, dbcoll string)

LoadMaps loads DAS maps from given database collection

func (*DASMaps) LoadMapsFromFile

func (m *DASMaps) LoadMapsFromFile()

LoadMapsFromFile loads DAS maps from github or local file

func (*DASMaps) Maps

func (m *DASMaps) Maps() []mongo.DASRecord

Maps provides access to DAS records

func (*DASMaps) NotationMaps

func (m *DASMaps) NotationMaps() []mongo.DASRecord

NotationMaps provides notation maps

func (*DASMaps) PresentationMap

func (m *DASMaps) PresentationMap() mongo.DASRecord

PresentationMap provides presentation map of DAS maps

func (*DASMaps) ReadMapFile

func (m *DASMaps) ReadMapFile(fname string)

ReadMapFile reads given map file

func (*DASMaps) Services

func (m *DASMaps) Services() []string

Services provides list of services

func (*DASMaps) SystemApis

func (m *DASMaps) SystemApis() map[string][]string

SystemApis provides map of DAS system and their apis

Jump to

Keyboard shortcuts

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