persist

package
v0.0.0-...-60f4909 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2019 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const InsertEventStatement = `INSERT INTO events (id, eventtype, aggregateid, aggregatetype, eventdata, channel) VALUES ($1, $2, $3, $4, $5, $6)`
View Source
const InsertItemStatement = `` /* 134-byte string literal not displayed */

TODO Ignoring duplication error for now, check before inserting if exists or values changes?

View Source
const InsertPriceNowStatement = `` /* 147-byte string literal not displayed */
View Source
const InsertPriceStatement = `` /* 136-byte string literal not displayed */

Variables

This section is empty.

Functions

func RegisterEventStoreServer

func RegisterEventStoreServer(s *grpc.Server, srv EventStoreServer)

func RegisterItemStoreServer

func RegisterItemStoreServer(s *grpc.Server, srv ItemStoreServer)

Types

type Event

type Event struct {
	EventId              string   `protobuf:"bytes,1,opt,name=event_id,json=eventId,proto3" json:"event_id,omitempty"`
	EventType            string   `protobuf:"bytes,2,opt,name=event_type,json=eventType,proto3" json:"event_type,omitempty"`
	AggregateId          string   `protobuf:"bytes,3,opt,name=aggregate_id,json=aggregateId,proto3" json:"aggregate_id,omitempty"`
	AggregateType        string   `protobuf:"bytes,4,opt,name=aggregate_type,json=aggregateType,proto3" json:"aggregate_type,omitempty"`
	EventData            string   `protobuf:"bytes,5,opt,name=event_data,json=eventData,proto3" json:"event_data,omitempty"`
	Channel              string   `protobuf:"bytes,6,opt,name=channel,proto3" json:"channel,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Event) Descriptor

func (*Event) Descriptor() ([]byte, []int)

func (*Event) GetAggregateId

func (m *Event) GetAggregateId() string

func (*Event) GetAggregateType

func (m *Event) GetAggregateType() string

func (*Event) GetChannel

func (m *Event) GetChannel() string

func (*Event) GetEventData

func (m *Event) GetEventData() string

func (*Event) GetEventId

func (m *Event) GetEventId() string

func (*Event) GetEventType

func (m *Event) GetEventType() string

func (*Event) ProtoMessage

func (*Event) ProtoMessage()

func (*Event) Reset

func (m *Event) Reset()

func (*Event) String

func (m *Event) String() string

func (*Event) XXX_DiscardUnknown

func (m *Event) XXX_DiscardUnknown()

func (*Event) XXX_Marshal

func (m *Event) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Event) XXX_Merge

func (m *Event) XXX_Merge(src proto.Message)

func (*Event) XXX_Size

func (m *Event) XXX_Size() int

func (*Event) XXX_Unmarshal

func (m *Event) XXX_Unmarshal(b []byte) error

type EventFilter

type EventFilter struct {
	EventId              string   `protobuf:"bytes,1,opt,name=event_id,json=eventId,proto3" json:"event_id,omitempty"`
	AggregateId          string   `protobuf:"bytes,2,opt,name=aggregate_id,json=aggregateId,proto3" json:"aggregate_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*EventFilter) Descriptor

func (*EventFilter) Descriptor() ([]byte, []int)

func (*EventFilter) GetAggregateId

func (m *EventFilter) GetAggregateId() string

func (*EventFilter) GetEventId

func (m *EventFilter) GetEventId() string

func (*EventFilter) ProtoMessage

func (*EventFilter) ProtoMessage()

func (*EventFilter) Reset

func (m *EventFilter) Reset()

func (*EventFilter) String

func (m *EventFilter) String() string

func (*EventFilter) XXX_DiscardUnknown

func (m *EventFilter) XXX_DiscardUnknown()

func (*EventFilter) XXX_Marshal

func (m *EventFilter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EventFilter) XXX_Merge

func (m *EventFilter) XXX_Merge(src proto.Message)

func (*EventFilter) XXX_Size

func (m *EventFilter) XXX_Size() int

func (*EventFilter) XXX_Unmarshal

func (m *EventFilter) XXX_Unmarshal(b []byte) error

type EventResponse

type EventResponse struct {
	Events               []*Event `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*EventResponse) Descriptor

func (*EventResponse) Descriptor() ([]byte, []int)

func (*EventResponse) GetEvents

func (m *EventResponse) GetEvents() []*Event

func (*EventResponse) ProtoMessage

func (*EventResponse) ProtoMessage()

func (*EventResponse) Reset

func (m *EventResponse) Reset()

func (*EventResponse) String

func (m *EventResponse) String() string

func (*EventResponse) XXX_DiscardUnknown

func (m *EventResponse) XXX_DiscardUnknown()

func (*EventResponse) XXX_Marshal

func (m *EventResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EventResponse) XXX_Merge

func (m *EventResponse) XXX_Merge(src proto.Message)

func (*EventResponse) XXX_Size

func (m *EventResponse) XXX_Size() int

func (*EventResponse) XXX_Unmarshal

func (m *EventResponse) XXX_Unmarshal(b []byte) error

type EventStoreClient

type EventStoreClient interface {
	// Get all events for the given aggregate and event
	GetEvents(ctx context.Context, in *EventFilter, opts ...grpc.CallOption) (*EventResponse, error)
	// Create a new event to the event store
	CreateEvent(ctx context.Context, in *Event, opts ...grpc.CallOption) (*Response, error)
}

EventStoreClient is the client API for EventStore service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewEventStoreClient

func NewEventStoreClient(cc *grpc.ClientConn) EventStoreClient

type EventStoreServer

type EventStoreServer interface {
	// Get all events for the given aggregate and event
	GetEvents(context.Context, *EventFilter) (*EventResponse, error)
	// Create a new event to the event store
	CreateEvent(context.Context, *Event) (*Response, error)
}

EventStoreServer is the server API for EventStore service.

type IEventDatabase

type IEventDatabase interface {
	// CreateItem saves a given Item, ID already assigned.
	CreateEvent(b *Event) (err error)
}

type IItemDatabase

type IItemDatabase interface {
	// ListItems returns a list of items
	ListItems() ([]*Item, error)

	// GetItem retrieves a book by its ID.
	GetItem(id int) (*Item, error)

	// CreateItem saves a given Item, ID already assigned.
	CreateItem(b *Item) (id int64, err error)

	// DeleteItem removes a given Item by its ID.
	DeleteItem(id int64) error

	// UpdateItem updates the entry for a given book.
	UpdateItem(b *Item) error
}

type IPriceDatabase

type IPriceDatabase interface {
	// ListPrices returns a list of Prices
	ListPrices() ([]*Prices, error)

	//TODO description
	GetDistinctPriceHistoryIds() ([]int, error)

	// AddPrice saves a given Price, ID already assigned.
	AddPrice(b *Prices) (id int64, err error)

	//TODO description
	DropPriceTable() (err error)
}

type IdbMysql

type IdbMysql interface {
	// Close closes the database, freeing up any available resources.
	Close() error
}

type Item

type Item struct {
	ID                   uint32   `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"`
	Name                 string   `protobuf:"bytes,2,opt,name=Name,proto3" json:"Name,omitempty"`
	Icon                 string   `protobuf:"bytes,3,opt,name=Icon,proto3" json:"Icon,omitempty"`
	Description          string   `protobuf:"bytes,4,opt,name=Description,proto3" json:"Description,omitempty"`
	Type                 string   `protobuf:"bytes,5,opt,name=Type,proto3" json:"Type,omitempty"`
	Rarity               string   `protobuf:"bytes,6,opt,name=Rarity,proto3" json:"Rarity,omitempty"`
	Level                uint32   `protobuf:"varint,7,opt,name=Level,proto3" json:"Level,omitempty"`
	VendorValue          uint32   `protobuf:"varint,8,opt,name=VendorValue,proto3" json:"VendorValue,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Item) Descriptor

func (*Item) Descriptor() ([]byte, []int)

func (*Item) GetDescription

func (m *Item) GetDescription() string

func (*Item) GetID

func (m *Item) GetID() uint32

func (*Item) GetIcon

func (m *Item) GetIcon() string

func (*Item) GetLevel

func (m *Item) GetLevel() uint32

func (*Item) GetName

func (m *Item) GetName() string

func (*Item) GetRarity

func (m *Item) GetRarity() string

func (*Item) GetType

func (m *Item) GetType() string

func (*Item) GetVendorValue

func (m *Item) GetVendorValue() uint32

func (*Item) ProtoMessage

func (*Item) ProtoMessage()

func (*Item) Reset

func (m *Item) Reset()

func (*Item) String

func (m *Item) String() string

func (*Item) XXX_DiscardUnknown

func (m *Item) XXX_DiscardUnknown()

func (*Item) XXX_Marshal

func (m *Item) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Item) XXX_Merge

func (m *Item) XXX_Merge(src proto.Message)

func (*Item) XXX_Size

func (m *Item) XXX_Size() int

func (*Item) XXX_Unmarshal

func (m *Item) XXX_Unmarshal(b []byte) error

type ItemBatch

type ItemBatch struct {
	BatchUUID            string   `protobuf:"bytes,1,opt,name=batchUUID,proto3" json:"batchUUID,omitempty"`
	ItemData             []byte   `protobuf:"bytes,2,opt,name=itemData,proto3" json:"itemData,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ItemBatch) Descriptor

func (*ItemBatch) Descriptor() ([]byte, []int)

func (*ItemBatch) GetBatchUUID

func (m *ItemBatch) GetBatchUUID() string

func (*ItemBatch) GetItemData

func (m *ItemBatch) GetItemData() []byte

func (*ItemBatch) ProtoMessage

func (*ItemBatch) ProtoMessage()

func (*ItemBatch) Reset

func (m *ItemBatch) Reset()

func (*ItemBatch) String

func (m *ItemBatch) String() string

func (*ItemBatch) XXX_DiscardUnknown

func (m *ItemBatch) XXX_DiscardUnknown()

func (*ItemBatch) XXX_Marshal

func (m *ItemBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ItemBatch) XXX_Merge

func (m *ItemBatch) XXX_Merge(src proto.Message)

func (*ItemBatch) XXX_Size

func (m *ItemBatch) XXX_Size() int

func (*ItemBatch) XXX_Unmarshal

func (m *ItemBatch) XXX_Unmarshal(b []byte) error

type ItemIdsRequest

type ItemIdsRequest struct {
	BatchUUID            string   `protobuf:"bytes,1,opt,name=batchUUID,proto3" json:"batchUUID,omitempty"`
	ItemIds              []uint32 `protobuf:"varint,2,rep,packed,name=itemIds,proto3" json:"itemIds,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ItemIdsRequest) Descriptor

func (*ItemIdsRequest) Descriptor() ([]byte, []int)

func (*ItemIdsRequest) GetBatchUUID

func (m *ItemIdsRequest) GetBatchUUID() string

func (*ItemIdsRequest) GetItemIds

func (m *ItemIdsRequest) GetItemIds() []uint32

func (*ItemIdsRequest) ProtoMessage

func (*ItemIdsRequest) ProtoMessage()

func (*ItemIdsRequest) Reset

func (m *ItemIdsRequest) Reset()

func (*ItemIdsRequest) String

func (m *ItemIdsRequest) String() string

func (*ItemIdsRequest) XXX_DiscardUnknown

func (m *ItemIdsRequest) XXX_DiscardUnknown()

func (*ItemIdsRequest) XXX_Marshal

func (m *ItemIdsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ItemIdsRequest) XXX_Merge

func (m *ItemIdsRequest) XXX_Merge(src proto.Message)

func (*ItemIdsRequest) XXX_Size

func (m *ItemIdsRequest) XXX_Size() int

func (*ItemIdsRequest) XXX_Unmarshal

func (m *ItemIdsRequest) XXX_Unmarshal(b []byte) error

type ItemResponse

type ItemResponse struct {
	ItemId               uint32   `protobuf:"varint,1,opt,name=item_id,json=itemId,proto3" json:"item_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ItemResponse) Descriptor

func (*ItemResponse) Descriptor() ([]byte, []int)

func (*ItemResponse) GetItemId

func (m *ItemResponse) GetItemId() uint32

func (*ItemResponse) ProtoMessage

func (*ItemResponse) ProtoMessage()

func (*ItemResponse) Reset

func (m *ItemResponse) Reset()

func (*ItemResponse) String

func (m *ItemResponse) String() string

func (*ItemResponse) XXX_DiscardUnknown

func (m *ItemResponse) XXX_DiscardUnknown()

func (*ItemResponse) XXX_Marshal

func (m *ItemResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ItemResponse) XXX_Merge

func (m *ItemResponse) XXX_Merge(src proto.Message)

func (*ItemResponse) XXX_Size

func (m *ItemResponse) XXX_Size() int

func (*ItemResponse) XXX_Unmarshal

func (m *ItemResponse) XXX_Unmarshal(b []byte) error

type ItemStoreClient

type ItemStoreClient interface {
	// Get all events for the given aggregate and event
	GetItems(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*ItemResponse, error)
}

ItemStoreClient is the client API for ItemStore service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewItemStoreClient

func NewItemStoreClient(cc *grpc.ClientConn) ItemStoreClient

type ItemStoreServer

type ItemStoreServer interface {
	// Get all events for the given aggregate and event
	GetItems(context.Context, *empty.Empty) (*ItemResponse, error)
}

ItemStoreServer is the server API for ItemStore service.

type Listings

type Listings struct {
	Id                   int32             `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Buys                 []*Listings_BUYS  `protobuf:"bytes,2,rep,name=buys,proto3" json:"buys,omitempty"`
	Sells                []*Listings_SELLS `protobuf:"bytes,3,rep,name=sells,proto3" json:"sells,omitempty"`
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*Listings) Descriptor

func (*Listings) Descriptor() ([]byte, []int)

func (*Listings) GetBuys

func (m *Listings) GetBuys() []*Listings_BUYS

func (*Listings) GetId

func (m *Listings) GetId() int32

func (*Listings) GetSells

func (m *Listings) GetSells() []*Listings_SELLS

func (*Listings) ProtoMessage

func (*Listings) ProtoMessage()

func (*Listings) Reset

func (m *Listings) Reset()

func (*Listings) String

func (m *Listings) String() string

func (*Listings) XXX_DiscardUnknown

func (m *Listings) XXX_DiscardUnknown()

func (*Listings) XXX_Marshal

func (m *Listings) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Listings) XXX_Merge

func (m *Listings) XXX_Merge(src proto.Message)

func (*Listings) XXX_Size

func (m *Listings) XXX_Size() int

func (*Listings) XXX_Unmarshal

func (m *Listings) XXX_Unmarshal(b []byte) error

type Listings_BUYS

type Listings_BUYS struct {
	Listings             int32    `protobuf:"varint,1,opt,name=listings,proto3" json:"listings,omitempty"`
	UnitPrice            int32    `protobuf:"varint,2,opt,name=unit_price,json=unitPrice,proto3" json:"unit_price,omitempty"`
	Quantity             int32    `protobuf:"varint,3,opt,name=quantity,proto3" json:"quantity,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Listings_BUYS) Descriptor

func (*Listings_BUYS) Descriptor() ([]byte, []int)

func (*Listings_BUYS) GetListings

func (m *Listings_BUYS) GetListings() int32

func (*Listings_BUYS) GetQuantity

func (m *Listings_BUYS) GetQuantity() int32

func (*Listings_BUYS) GetUnitPrice

func (m *Listings_BUYS) GetUnitPrice() int32

func (*Listings_BUYS) ProtoMessage

func (*Listings_BUYS) ProtoMessage()

func (*Listings_BUYS) Reset

func (m *Listings_BUYS) Reset()

func (*Listings_BUYS) String

func (m *Listings_BUYS) String() string

func (*Listings_BUYS) XXX_DiscardUnknown

func (m *Listings_BUYS) XXX_DiscardUnknown()

func (*Listings_BUYS) XXX_Marshal

func (m *Listings_BUYS) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Listings_BUYS) XXX_Merge

func (m *Listings_BUYS) XXX_Merge(src proto.Message)

func (*Listings_BUYS) XXX_Size

func (m *Listings_BUYS) XXX_Size() int

func (*Listings_BUYS) XXX_Unmarshal

func (m *Listings_BUYS) XXX_Unmarshal(b []byte) error

type Listings_SELLS

type Listings_SELLS struct {
	Listings             int32    `protobuf:"varint,1,opt,name=listings,proto3" json:"listings,omitempty"`
	UnitPrice            int32    `protobuf:"varint,2,opt,name=unit_price,json=unitPrice,proto3" json:"unit_price,omitempty"`
	Quantity             int32    `protobuf:"varint,3,opt,name=quantity,proto3" json:"quantity,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Listings_SELLS) Descriptor

func (*Listings_SELLS) Descriptor() ([]byte, []int)

func (*Listings_SELLS) GetListings

func (m *Listings_SELLS) GetListings() int32

func (*Listings_SELLS) GetQuantity

func (m *Listings_SELLS) GetQuantity() int32

func (*Listings_SELLS) GetUnitPrice

func (m *Listings_SELLS) GetUnitPrice() int32

func (*Listings_SELLS) ProtoMessage

func (*Listings_SELLS) ProtoMessage()

func (*Listings_SELLS) Reset

func (m *Listings_SELLS) Reset()

func (*Listings_SELLS) String

func (m *Listings_SELLS) String() string

func (*Listings_SELLS) XXX_DiscardUnknown

func (m *Listings_SELLS) XXX_DiscardUnknown()

func (*Listings_SELLS) XXX_Marshal

func (m *Listings_SELLS) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Listings_SELLS) XXX_Merge

func (m *Listings_SELLS) XXX_Merge(src proto.Message)

func (*Listings_SELLS) XXX_Size

func (m *Listings_SELLS) XXX_Size() int

func (*Listings_SELLS) XXX_Unmarshal

func (m *Listings_SELLS) XXX_Unmarshal(b []byte) error

type MySQLConfig

type MySQLConfig struct {
	// Optional.
	Username, Password string

	// Host of the MySQL instance.
	//
	// If set, UnixSocket should be unset.
	Host string

	// Port of the MySQL instance.
	//
	// If set, UnixSocket should be unset.
	Port int

	// UnixSocket is the file path to a unix socket.
	//
	// If set, Host and Port should be unset.
	UnixSocket string
}

func (MySQLConfig) NewMySQLDB

func (mysqlConfig MySQLConfig) NewMySQLDB() (*MySQLConn, error)

newMySQLDB creates a new MySQLConn backed by a given MySQL server.

type MySQLConn

type MySQLConn struct {
	Conn             *sql.DB
	MaxAllowedPacket *sql.Stmt
	Item             *itemDatabase
	Price            *priceDatabase
	Event            *eventDatabase
}

func (*MySQLConn) BulkCreateItem

func (db *MySQLConn) BulkCreateItem(unsavedRows []Item) error

func (*MySQLConn) Close

func (db *MySQLConn) Close() error

Close closes the database, freeing up any resources. Before closing it finishing flushing any existing batch inserts.

func (*MySQLConn) GetMaxId

func (db *MySQLConn) GetMaxId() (int, error)

Returns Database max_allowed_packet variable in bytes

func (*MySQLConn) PrepareEventStatements

func (db *MySQLConn) PrepareEventStatements() error

func (*MySQLConn) PrepareItemStatements

func (db *MySQLConn) PrepareItemStatements() error

func (*MySQLConn) PreparePriceStatements

func (db *MySQLConn) PreparePriceStatements() error

type Prices

type Prices struct {
	Id                   uint32        `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Whitelisted          bool          `protobuf:"varint,2,opt,name=whitelisted,proto3" json:"whitelisted,omitempty"`
	FetchDatetime        int64         `protobuf:"varint,3,opt,name=fetch_datetime,json=fetchDatetime,proto3" json:"fetch_datetime,omitempty"`
	Buys                 *Prices_BUYS  `protobuf:"bytes,4,opt,name=buys,proto3" json:"buys,omitempty"`
	Sells                *Prices_SELLS `protobuf:"bytes,5,opt,name=sells,proto3" json:"sells,omitempty"`
	AggregateId          string        `protobuf:"bytes,6,opt,name=aggregate_id,json=aggregateId,proto3" json:"aggregate_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{}      `json:"-"`
	XXX_unrecognized     []byte        `json:"-"`
	XXX_sizecache        int32         `json:"-"`
}

ArticlePrice Listings for a specific item (highest buy, lowest sell)

func (*Prices) Descriptor

func (*Prices) Descriptor() ([]byte, []int)

func (*Prices) GetAggregateId

func (m *Prices) GetAggregateId() string

func (*Prices) GetBuys

func (m *Prices) GetBuys() *Prices_BUYS

func (*Prices) GetFetchDatetime

func (m *Prices) GetFetchDatetime() int64

func (*Prices) GetId

func (m *Prices) GetId() uint32

func (*Prices) GetSells

func (m *Prices) GetSells() *Prices_SELLS

func (*Prices) GetWhitelisted

func (m *Prices) GetWhitelisted() bool

func (*Prices) ProtoMessage

func (*Prices) ProtoMessage()

func (*Prices) Reset

func (m *Prices) Reset()

func (*Prices) String

func (m *Prices) String() string

func (*Prices) XXX_DiscardUnknown

func (m *Prices) XXX_DiscardUnknown()

func (*Prices) XXX_Marshal

func (m *Prices) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Prices) XXX_Merge

func (m *Prices) XXX_Merge(src proto.Message)

func (*Prices) XXX_Size

func (m *Prices) XXX_Size() int

func (*Prices) XXX_Unmarshal

func (m *Prices) XXX_Unmarshal(b []byte) error

type PricesRequest

type PricesRequest struct {
	Page                 uint32   `protobuf:"varint,1,opt,name=page,proto3" json:"page,omitempty"`
	PageSize             uint32   `protobuf:"varint,2,opt,name=pageSize,proto3" json:"pageSize,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*PricesRequest) Descriptor

func (*PricesRequest) Descriptor() ([]byte, []int)

func (*PricesRequest) GetPage

func (m *PricesRequest) GetPage() uint32

func (*PricesRequest) GetPageSize

func (m *PricesRequest) GetPageSize() uint32

func (*PricesRequest) ProtoMessage

func (*PricesRequest) ProtoMessage()

func (*PricesRequest) Reset

func (m *PricesRequest) Reset()

func (*PricesRequest) String

func (m *PricesRequest) String() string

func (*PricesRequest) XXX_DiscardUnknown

func (m *PricesRequest) XXX_DiscardUnknown()

func (*PricesRequest) XXX_Marshal

func (m *PricesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PricesRequest) XXX_Merge

func (m *PricesRequest) XXX_Merge(src proto.Message)

func (*PricesRequest) XXX_Size

func (m *PricesRequest) XXX_Size() int

func (*PricesRequest) XXX_Unmarshal

func (m *PricesRequest) XXX_Unmarshal(b []byte) error

type Prices_BUYS

type Prices_BUYS struct {
	Quantity             uint32   `protobuf:"varint,1,opt,name=quantity,proto3" json:"quantity,omitempty"`
	UnitPrice            uint32   `protobuf:"varint,2,opt,name=unit_price,json=unitPrice,proto3" json:"unit_price,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

Price includes quantity and the high/low price

func (*Prices_BUYS) Descriptor

func (*Prices_BUYS) Descriptor() ([]byte, []int)

func (*Prices_BUYS) GetQuantity

func (m *Prices_BUYS) GetQuantity() uint32

func (*Prices_BUYS) GetUnitPrice

func (m *Prices_BUYS) GetUnitPrice() uint32

func (*Prices_BUYS) ProtoMessage

func (*Prices_BUYS) ProtoMessage()

func (*Prices_BUYS) Reset

func (m *Prices_BUYS) Reset()

func (*Prices_BUYS) String

func (m *Prices_BUYS) String() string

func (*Prices_BUYS) XXX_DiscardUnknown

func (m *Prices_BUYS) XXX_DiscardUnknown()

func (*Prices_BUYS) XXX_Marshal

func (m *Prices_BUYS) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Prices_BUYS) XXX_Merge

func (m *Prices_BUYS) XXX_Merge(src proto.Message)

func (*Prices_BUYS) XXX_Size

func (m *Prices_BUYS) XXX_Size() int

func (*Prices_BUYS) XXX_Unmarshal

func (m *Prices_BUYS) XXX_Unmarshal(b []byte) error

type Prices_SELLS

type Prices_SELLS struct {
	Quantity             uint32   `protobuf:"varint,1,opt,name=quantity,proto3" json:"quantity,omitempty"`
	UnitPrice            uint32   `protobuf:"varint,2,opt,name=unit_price,json=unitPrice,proto3" json:"unit_price,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

Price includes quantity and the high/low price

func (*Prices_SELLS) Descriptor

func (*Prices_SELLS) Descriptor() ([]byte, []int)

func (*Prices_SELLS) GetQuantity

func (m *Prices_SELLS) GetQuantity() uint32

func (*Prices_SELLS) GetUnitPrice

func (m *Prices_SELLS) GetUnitPrice() uint32

func (*Prices_SELLS) ProtoMessage

func (*Prices_SELLS) ProtoMessage()

func (*Prices_SELLS) Reset

func (m *Prices_SELLS) Reset()

func (*Prices_SELLS) String

func (m *Prices_SELLS) String() string

func (*Prices_SELLS) XXX_DiscardUnknown

func (m *Prices_SELLS) XXX_DiscardUnknown()

func (*Prices_SELLS) XXX_Marshal

func (m *Prices_SELLS) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Prices_SELLS) XXX_Merge

func (m *Prices_SELLS) XXX_Merge(src proto.Message)

func (*Prices_SELLS) XXX_Size

func (m *Prices_SELLS) XXX_Size() int

func (*Prices_SELLS) XXX_Unmarshal

func (m *Prices_SELLS) XXX_Unmarshal(b []byte) error

type Response

type Response struct {
	IsSuccess            bool     `protobuf:"varint,1,opt,name=is_success,json=isSuccess,proto3" json:"is_success,omitempty"`
	Error                string   `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Response) Descriptor

func (*Response) Descriptor() ([]byte, []int)

func (*Response) GetError

func (m *Response) GetError() string

func (*Response) GetIsSuccess

func (m *Response) GetIsSuccess() bool

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) Reset

func (m *Response) Reset()

func (*Response) String

func (m *Response) String() string

func (*Response) XXX_DiscardUnknown

func (m *Response) XXX_DiscardUnknown()

func (*Response) XXX_Marshal

func (m *Response) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Response) XXX_Merge

func (m *Response) XXX_Merge(src proto.Message)

func (*Response) XXX_Size

func (m *Response) XXX_Size() int

func (*Response) XXX_Unmarshal

func (m *Response) XXX_Unmarshal(b []byte) error

type UnimplementedEventStoreServer

type UnimplementedEventStoreServer struct {
}

UnimplementedEventStoreServer can be embedded to have forward compatible implementations.

func (*UnimplementedEventStoreServer) CreateEvent

func (*UnimplementedEventStoreServer) CreateEvent(ctx context.Context, req *Event) (*Response, error)

func (*UnimplementedEventStoreServer) GetEvents

type UnimplementedItemStoreServer

type UnimplementedItemStoreServer struct {
}

UnimplementedItemStoreServer can be embedded to have forward compatible implementations.

func (*UnimplementedItemStoreServer) GetItems

Jump to

Keyboard shortcuts

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