couchdb

package module
v0.0.0-...-8f6edbe Latest Latest
Warning

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

Go to latest
Published: May 30, 2023 License: Apache-2.0 Imports: 6 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client - Implements a couchDB client

type Connector

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

Connector - Implements a CouchDB connector

func NewConnector

func NewConnector(addr string, dbName string) (rc *Connector, err error)

NewConnector - Creates and initialize a CouchDB connector to a database

func (*Connector) AddDoc

func (dbCon *Connector) AddDoc(docName string, doc []byte) (string, error)

addDoc - Add scenario to DB

func (*Connector) DeleteAllDocs

func (dbCon *Connector) DeleteAllDocs() error

deleteAllDocs - Remove all documents from DB

func (*Connector) DeleteDoc

func (dbCon *Connector) DeleteDoc(docName string) error

deleteDoc - Remove a document from DB

func (*Connector) GetDoc

func (dbCon *Connector) GetDoc(returnNilOnNotFound bool, docName string) (doc []byte, err error)

getDocument - Get document from DB

func (*Connector) GetDocList

func (dbCon *Connector) GetDocList() (docNameList []string, docList [][]byte, err error)

getDocList - Get document list from DB

func (*Connector) UpdateDoc

func (dbCon *Connector) UpdateDoc(docName string, doc []byte) (string, error)

updateDoc - Update a document in DB

Jump to

Keyboard shortcuts

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