inmemory

package
v0.0.0-...-fc38f95 Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2017 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type InMemoryEventBus

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

InMemoryEventBus provides an inmemory implementation of the VersionedEventPublisher VersionedEventReceiver interfaces

func NewInMemoryEventBus

func NewInMemoryEventBus() *InMemoryEventBus

NewInMemoryEventBus constructor

func (*InMemoryEventBus) PublishEvents

func (bus *InMemoryEventBus) PublishEvents(events []*goengine.DomainMessage) error

PublishEvents publishes events to the event bus

func (*InMemoryEventBus) ReceiveEvents

func (bus *InMemoryEventBus) ReceiveEvents(options goengine.VersionedEventReceiverOptions) error

ReceiveEvents starts a go routine that monitors incoming events and routes them to a receiver channel specified within the options

type InMemoryEventStore

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

func NewEventStore

func NewEventStore() *InMemoryEventStore

func (*InMemoryEventStore) Append

func (s *InMemoryEventStore) Append(events *goengine.EventStream) error

func (*InMemoryEventStore) CountEventsFor

func (s *InMemoryEventStore) CountEventsFor(streamName goengine.StreamName, id string) (int, error)

func (*InMemoryEventStore) FromVersion

func (s *InMemoryEventStore) FromVersion(streamName goengine.StreamName, id string, version int) (*goengine.EventStream, error)

func (*InMemoryEventStore) GetEventsFor

func (s *InMemoryEventStore) GetEventsFor(streamName goengine.StreamName, id string) (*goengine.EventStream, error)

Jump to

Keyboard shortcuts

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