class
XMPP::Client
- XMPP::Client
- Reference
- Object
Included Modules
Defined in:
xmpp/client.crConstructors
Instance Method Summary
-
#bare_jid : String
Bare JID (node@domain) of the account, derived from the bound JID when available and falling back to the configured JID.
-
#bound_jid : String
Full JID assigned to the active session by RFC 6120 binding or Bind 2.
- #cipher : String | Nil
-
#connect
connect triggers actual TCP connection, based on previously defined parameters.
- #disconnect
- #last_resume_succeeded? : Bool
-
#request(iq : Stanza::IQ, timeout : Time::Span = 5.seconds) : Stanza::IQ | Nil
request performs a synchronous IQ request/response round-trip and returns the matching result stanza (or the IQ error stanza) within the given timeout.
-
#resume(state : SMState)
Resume attempts resuming a Stream Managed session, based on the provided stream management state
-
#send(packet : Stanza::Packet)
sends marshal's XMPP stanza and sends it to the server.
-
#send(packet : String)
send sends an XMPP stanza as a string to the server.
-
#session : Session
Session gathers data that be access by users of this Shard
- #tls_verified? : Bool
-
#tls_version : String | Nil
TLS introspection (RFC 7590 §3.6).
-
#unacknowledged_stanza_count : Int32
Components and custom stream clients that do not implement XEP-0198 retain the zero/false defaults.
Instance methods inherited from module XMPP::StreamManagement
disable_sm_tracking
disable_sm_tracking,
enable_sm_tracking
enable_sm_tracking,
process_sm_ack(h : UInt32)
process_sm_ack,
resend_unacked_stanzas
resend_unacked_stanzas,
send_with_sm(stanza : Stanza::Packet)send_with_sm(xml : String) send_with_sm, sm_enabled? : Bool sm_enabled?
Instance methods inherited from module XMPP::EventManager
current_state : ConnectionState
current_state,
event_handler : EventHandler | Nil
event_handler,
event_handler=(handler : EventHandler | Nil)
event_handler=
Instance methods inherited from module XMPP::StreamClient
connect
connect,
disconnect
disconnect,
event_handler=(handler : EventHandler | Nil)
event_handler=,
last_resume_succeeded? : Bool
last_resume_succeeded?,
resume(state : SMState)
resume,
unacknowledged_stanza_count : Int32
unacknowledged_stanza_count
Instance methods inherited from module XMPP::Sender
send(packet : String)send(packet : Stanza::Packet) send
Constructor Detail
Instance Method Detail
Bare JID (node@domain) of the account, derived from the bound JID when available and falling back to the configured JID.
connect triggers actual TCP connection, based on previously defined parameters. connect simply triggers resumption, with an empty session state.
request performs a synchronous IQ request/response round-trip and returns the matching result stanza (or the IQ error stanza) within the given timeout. Returns nil if no response arrives before the timeout.
Resume attempts resuming a Stream Managed session, based on the provided stream management state
send sends an XMPP stanza as a string to the server. It can be invalid XML or XMPP content. In that case, the server will disconnect the client. It is up to the user of this method to carefully craft the XML content to produce valid XMPP.
Components and custom stream clients that do not implement XEP-0198 retain the zero/false defaults.