db

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2020 License: Apache-2.0 Imports: 6 Imported by: 2 modules, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BulkResponse

type BulkResponse struct {
	Response []map[string]interface{} `json:"response"`
}

BulkResponse provides a basic template for anything that returns an array of objects, and is designed to be easy to unmarshall

type MetadataConnection

type MetadataConnection struct {
	Tokens resources.APITokenStorage
	DAO    resources.ArrayDatabase
}

MetadataConnection provides a unified class to access metadata information through any source

func (*MetadataConnection) DeleteArrayTags

func (h *MetadataConnection) DeleteArrayTags(query resources.ArrayQuery, tags []string) (BulkResponse, error)

DeleteArrayTags deletes the given tags from all arrays matching the given query

func (*MetadataConnection) DeleteArrays

func (h *MetadataConnection) DeleteArrays(query resources.ArrayQuery) (int, error)

DeleteArrays deletes all arrays that match the given query, and returns the count of arrays deleted

func (*MetadataConnection) GetArrayStatuses

func (h *MetadataConnection) GetArrayStatuses(query resources.ArrayQuery) (BulkResponse, error)

GetArrayStatuses fetches all the array statuses that match the given query

func (*MetadataConnection) GetArrayTags

func (h *MetadataConnection) GetArrayTags(query resources.ArrayQuery) (BulkResponse, error)

GetArrayTags fetches all the array tags that match the given query

func (*MetadataConnection) GetArrays

func (h *MetadataConnection) GetArrays(query resources.ArrayQuery) (BulkResponse, error)

GetArrays fetches all the arrays that match the given query

func (*MetadataConnection) PatchArrayTags

func (h *MetadataConnection) PatchArrayTags(query resources.ArrayQuery, m []map[string]string) (BulkResponse, error)

PatchArrayTags updates the tags of all arrays matching the given query

func (*MetadataConnection) PatchArrays

func (h *MetadataConnection) PatchArrays(query resources.ArrayQuery, m map[string]interface{}) (BulkResponse, error)

PatchArrays updates all arrays matching the given query

func (*MetadataConnection) PostArray

func (h *MetadataConnection) PostArray(m map[string]interface{}) (map[string]interface{}, error)

PostArray registers a new array to the given database

Jump to

Keyboard shortcuts

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