data

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

Types

type BankAccount

type BankAccount struct {
	BankAccountNumber *int             `json:"bank_account_number,omitempty" dynamodbav:"bank_account_number,omitempty"`
	AccountType       *BankAccountType `json:"account_type,omitempty" dynamodbav:"account_type,omitempty"`
}

type BankAccountType

type BankAccountType int
const (
	SAVINGS BankAccountType = iota
	CURRENT
)

type BankAccount_ExpressionBuilder

type BankAccount_ExpressionBuilder struct {
	BankAccountNumber dynexpr.DynamoAttribute[*int]
	AccountType       dynexpr.DynamoAttribute[*BankAccountType]
}

func (*BankAccount_ExpressionBuilder) BuildTree

type BankDetails

type BankDetails struct {
	Accounts *[]*BankAccount `json:"accounts,omitempty" dynamodbav:"accounts,numberset,omitempty,omitemptyelem"` // This will be a set in DDB
}

type BankDetails_ExpressionBuilder

type BankDetails_ExpressionBuilder struct {
	Accounts dynexpr.DynamoListAttribute[*BankAccount_ExpressionBuilder]
}

func (*BankDetails_ExpressionBuilder) BuildTree

type Child

type Child struct {
	Name *string    `json:"name,omitempty" dynamodbav:"name,omitempty"`
	DOB  *time.Time `json:"dob,omitempty" dynamodbav:"dob,omitempty"`
}

type Child_ExpressionBuilder

type Child_ExpressionBuilder struct {
	Name dynexpr.DynamoAttribute[*string]
	DOB  dynexpr.DynamoAttribute[*time.Time]
}

func (*Child_ExpressionBuilder) BuildTree

type FamilyDetail

type FamilyDetail struct {
	Children  *[]*Child `json:"children,omitempty" dynamodbav:"children,omitempty,omitemptyelem"` // This will be a list
	IsMarried *bool     `json:"is_married,omitempty" dynamodbav:"is_married,omitempty"`
}

type FamilyDetail_ExpressionBuilder

type FamilyDetail_ExpressionBuilder struct {
	Children  dynexpr.DynamoListAttribute[*Child_ExpressionBuilder]
	IsMarried dynexpr.DynamoAttribute[*bool]
}

func (*FamilyDetail_ExpressionBuilder) BuildTree

type Person

type Person struct {
	PK            *string       `json:"pk,omitempty" dynamodbav:"pk,omitempty" dynexpr:"partitionKey"`
	SK            *string       `json:"sk,omitempty" dynamodbav:"sk,omitempty" dynexpr:"sortKey"`
	Name          *string       `json:"name,omitempty" dynamodbav:"name,omitempty"`
	BankDetails   *BankDetails  `json:"bank_details,omitempty" dynamodbav:"bank_details,omitempty"`
	FamilyDetails *FamilyDetail `json:"family_details,omitempty" dynamodbav:"family_details,omitempty"`
	PhoneNos      *[]*string    `json:"phone_nos,omitempty" dynamodbav:"phone_nos,omitempty,omitemptyelem"` // This will be a list
}

dynexpr:generate

Jump to

Keyboard shortcuts

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