Sha256: d77953fbc2744cdeecf95c6ec6d53b9df8654965148726bec46c9d1f43ec6657
Contents?: true
Size: 723 Bytes
Versions: 18
Compression:
Stored size: 723 Bytes
Contents
# frozen_string_literal: true module JabberAdmin module Commands # Send a stanza; provide From JID and valid To JID. # # @see https://bit.ly/2rzxyK1 class SendStanza # Pass the correct data to the given callable. # # @param callable [Proc, #call] the callable to call # @param from [String] user JID wo/ resource (eg. +tom@localhost+) # @param to [String] user/room JID wo/ resource (eg. +bob@localhost+) # @param stanza [String] the XML stanz to send # (eg. <tt><message><ext attr='value'/></message></tt>) def self.call(callable, from:, to:, stanza:) callable.call('send_stanza', from: from, to: to, stanza: stanza) end end end end
Version data entries
18 entries across 18 versions & 1 rubygems