You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
lntop/events/events.go

30 lines
747 B
Go

package events
const (
BlockReceived = "block.received"
ChannelActive = "channel.active"
ChannelBalanceUpdated = "channel.balance.updated"
ChannelInactive = "channel.inactive"
ChannelPending = "channel.pending"
InvoiceCreated = "invoice.created"
InvoiceSettled = "invoice.settled"
PeerUpdated = "peer.updated"
TransactionCreated = "transaction.created"
WalletBalanceUpdated = "wallet.balance.updated"
RoutingEventUpdated = "routing.event.updated"
)
type Event struct {
Type string
ID string
Data interface{}
}
func New(kind string) *Event {
return &Event{Type: kind}
}
func NewWithData(kind string, data interface{}) *Event {
return &Event{Type: kind, Data: data}
}