Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EventMessage ¶
type EventMessage struct { Event eventenvelope.T Relay string }
type T ¶
type T struct { Label string Counter int Relay relay.I Filters filters.T // for this to be treated as a COUNT and not a REQ this must be set CountResult chan int // the Events channel emits all EVENTs that come in a Subscription // will be closed when the subscription ends Events event.C // the EndOfStoredEvents channel gets closed when an EOSE comes for that // subscription EndOfStoredEvents chan struct{} // the ClosedReason channel emits the reason when a CLOSED message is // received ClosedReason chan string // Context will be .Done() when the subscription ends Context context.T Cancel context.F // contains filtered or unexported fields }
func (*T) Close ¶
func (sub *T) Close()
Close just sends a CLOSE message. You probably want Unsub() instead.
func (*T) DispatchClosed ¶
func (*T) DispatchEose ¶
func (sub *T) DispatchEose()
func (*T) DispatchEvent ¶
func (*T) GetID ¶
GetID return the Nostr subscription ID as given to the I it is a concatenation of the label and a serial number.
Click to show internal directories.
Click to hide internal directories.