Package org.ngengine.nostr4j.nip01
Class Nip01UserMetadataListener
java.lang.Object
org.ngengine.nostr4j.nip01.Nip01UserMetadataListener
- All Implemented Interfaces:
NostrSubEventListener
,NostrSubListener
-
Constructor Summary
ConstructorsConstructorDescriptionNip01UserMetadataListener
(Consumer<Nip24ExtraMetadata> consumer) Nip01UserMetadataListener
(NostrPublicKey pubkey, Consumer<Nip24ExtraMetadata> consumer) -
Method Summary
Modifier and TypeMethodDescriptionvoid
onSubEvent
(SignedNostrEvent event, boolean stored) Called when an event matching the subscription's filter is received.
-
Constructor Details
-
Nip01UserMetadataListener
-
Nip01UserMetadataListener
-
Nip01UserMetadataListener
public Nip01UserMetadataListener()
-
-
Method Details
-
onSubEvent
Description copied from interface:NostrSubEventListener
Called when an event matching the subscription's filter is received.This method is invoked for each event that matches the subscription's filter criteria and passes any duplicate detection checks implemented by the subscription's event tracker.
- Specified by:
onSubEvent
in interfaceNostrSubEventListener
- Parameters:
event
- The signed Nostr event that was receivedstored
- Whether this event came from the relay's stored history (true) or is a new event (false)
-