dtable

package
v0.0.0-...-d6b3ade Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetKeysAndAttributes

func GetKeysAndAttributes(pk, sk string, keys []Key) []map[string]*dynamodb.AttributeValue

Types

type BatchGetItemInput

type BatchGetItemInput struct {
	KeysAndAttributes      *dynamodb.KeysAndAttributes
	ReturnConsumedCapacity *string
}

type BatchGetItemOutput

type BatchGetItemOutput struct {
	ConsumedCapacity []*dynamodb.ConsumedCapacity
	Responses        []map[string]*dynamodb.AttributeValue
	UnprocessedKeys  map[string]*dynamodb.KeysAndAttributes
}

type Key

type Key struct {
	PK string
	SK string
}

type Table

type Table struct {
	Name string
	// contains filtered or unexported fields
}

func New

func New(conn *dynamodb.DynamoDB, name string, log logrus.FieldLogger) *Table

func (*Table) BatchGetItem

func (t *Table) BatchGetItem(ctx aws.Context, in *BatchGetItemInput) (*BatchGetItemOutput, error)

func (*Table) Conn

func (t *Table) Conn() *dynamodb.DynamoDB

func (*Table) DeleteItem

func (*Table) GetItem

func (t *Table) GetItem(ctx aws.Context, in *dynamodb.GetItemInput) (*dynamodb.GetItemOutput, error)

func (*Table) PutItem

func (t *Table) PutItem(ctx aws.Context, in *dynamodb.PutItemInput) (*dynamodb.PutItemOutput, error)

func (*Table) Query

func (t *Table) Query(ctx aws.Context, in *dynamodb.QueryInput) (*dynamodb.QueryOutput, error)

func (*Table) UpdateItem

Jump to

Keyboard shortcuts

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