Documentation ¶
Index ¶
- Variables
- type SeaWatcher
- func (sw *SeaWatcher) ActiveSubscriptions() map[osmodels.EventType]map[string]func()
- func (sw *SeaWatcher) DecodeCollectionOfferEvent(itemEvent map[string]interface{}) (osmodels.CollectionOfferEvent, error)
- func (sw *SeaWatcher) DecodeItemReceivedBidEvent(itemEvent map[string]interface{}) (osmodels.ItemReceivedBidEvent, error)
- func (sw *SeaWatcher) EventChannel() chan map[string]interface{}
- func (sw *SeaWatcher) PublishSendSlugs()
- func (sw *SeaWatcher) Run()
- func (sw *SeaWatcher) SubscribeForSlug(eventType osmodels.EventType, slug string) bool
- func (sw *SeaWatcher) UnubscribeForSlug(eventType osmodels.EventType, slug string) bool
Constants ¶
This section is empty.
Variables ¶
View Source
var (
AvailableEventTypes = []osmodels.EventType{osmodels.ItemListed, osmodels.ItemReceivedBid, osmodels.CollectionOffer} // , osmodels.ItemMetadataUpdated} // ItemMetadataUpdated, ItemCancelled
)
Functions ¶
This section is empty.
Types ¶
type SeaWatcher ¶
type SeaWatcher struct {
// contains filtered or unexported fields
}
func NewSeaWatcher ¶ added in v0.4.2
func NewSeaWatcher(apiToken string, gb *gloomberg.Gloomberg) *SeaWatcher
func NewSeaWatcher(apiToken string, rdb rueidis.Client) *SeaWatcher {.
func (*SeaWatcher) ActiveSubscriptions ¶
func (sw *SeaWatcher) ActiveSubscriptions() map[osmodels.EventType]map[string]func()
func (*SeaWatcher) DecodeCollectionOfferEvent ¶ added in v0.7.1
func (sw *SeaWatcher) DecodeCollectionOfferEvent(itemEvent map[string]interface{}) (osmodels.CollectionOfferEvent, error)
func (*SeaWatcher) DecodeItemReceivedBidEvent ¶ added in v0.7.1
func (sw *SeaWatcher) DecodeItemReceivedBidEvent(itemEvent map[string]interface{}) (osmodels.ItemReceivedBidEvent, error)
func (*SeaWatcher) EventChannel ¶
func (sw *SeaWatcher) EventChannel() chan map[string]interface{}
func (*SeaWatcher) PublishSendSlugs ¶ added in v0.6.0
func (sw *SeaWatcher) PublishSendSlugs()
func (*SeaWatcher) Run ¶ added in v0.6.0
func (sw *SeaWatcher) Run()
Run starts the seawatcher by subscribing to the mgmt channel and listening for new slugs to subscribe to.
func (*SeaWatcher) SubscribeForSlug ¶
func (sw *SeaWatcher) SubscribeForSlug(eventType osmodels.EventType, slug string) bool
func (*SeaWatcher) UnubscribeForSlug ¶
func (sw *SeaWatcher) UnubscribeForSlug(eventType osmodels.EventType, slug string) bool
Click to show internal directories.
Click to hide internal directories.