api

package
v0.6.6-4-v0.9.12-4 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2020 License: Apache-2.0 Imports: 13 Imported by: ? modules, 0 packages

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 API

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

API layer, implements common CRUD operations TODO: Call it DAL? (data access layer)

func New

func New(logger logger.Logger, config *frames.Config) (*API, error)

New returns a new API layer struct

func (*API) Create

func (api *API) Create(request *frames.CreateRequest) error

Create will create a new table

func (*API) Delete

func (api *API) Delete(request *frames.DeleteRequest) error

Delete deletes a table or part of it

func (*API) Exec

func (api *API) Exec(request *frames.ExecRequest) (frames.Frame, error)

Exec executes a command on the backend

func (*API) Read

func (api *API) Read(request *frames.ReadRequest, out chan frames.Frame) error

Read reads from database, emitting results to wf

func (*API) Write

func (api *API) Write(request *frames.WriteRequest, in chan frames.Frame) (int, int, error)

Write write data to backend, returns num_frames, num_rows, error

Jump to

Keyboard shortcuts

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