Module Jabber
In: lib/xmpp4r/connection.rb
lib/xmpp4r/client.rb
lib/xmpp4r/idgenerator.rb
lib/xmpp4r/xmlstanza.rb
lib/xmpp4r/component.rb
lib/xmpp4r/message.rb
lib/xmpp4r/presence.rb
lib/xmpp4r/jid.rb
lib/xmpp4r/iq/query/discoitems.rb
lib/xmpp4r/iq/query/discoinfo.rb
lib/xmpp4r/iq/query/roster.rb
lib/xmpp4r/iq/query/version.rb
lib/xmpp4r/iq/vcard.rb
lib/xmpp4r/iq/query.rb
lib/xmpp4r/helpers/roster.rb
lib/xmpp4r/helpers/version.rb
lib/xmpp4r/helpers/vcard.rb
lib/xmpp4r/streamparser.rb
lib/xmpp4r/iq.rb
lib/xmpp4r/xmpp4r.rb
lib/xmpp4r/stream.rb
lib/xmpp4r/debuglog.rb
lib/xmpp4r/x/roster.rb
lib/xmpp4r/x/delay.rb
lib/xmpp4r/x/muc.rb
lib/xmpp4r/x/mucuseritem.rb
lib/xmpp4r/authenticationfailure.rb
lib/xmpp4r/errorexception.rb
lib/xmpp4r/error.rb
lib/xmpp4r/x.rb
X XDelay XMuc XRoster XMucUser REXML::Element XRosterItem IqQuery XMLStanza IqVcard DiscoIdentity XMucUserItem DiscoItem Error RosterItem DiscoFeature IqQueryRoster IqQueryVersion IqQueryDiscoItems IqQueryDiscoInfo Message Presence Iq Singleton IdGenerator Connection Client Component Comparable JID RuntimeError ErrorException AuthenticationFailure RosterItem Stream StreamParser Roster Vcard Version lib/xmpp4r/authenticationfailure.rb lib/xmpp4r/iq/query/roster.rb lib/xmpp4r/idgenerator.rb lib/xmpp4r/iq/query/version.rb lib/xmpp4r/connection.rb lib/xmpp4r/x/mucuseritem.rb lib/xmpp4r/x/roster.rb lib/xmpp4r/iq.rb lib/xmpp4r/jid.rb lib/xmpp4r/iq/query.rb lib/xmpp4r/xmlstanza.rb lib/xmpp4r/x/delay.rb lib/xmpp4r/errorexception.rb lib/xmpp4r/client.rb lib/xmpp4r/stream.rb lib/xmpp4r/x/muc.rb lib/xmpp4r/streamparser.rb lib/xmpp4r/x.rb lib/xmpp4r/iq/vcard.rb lib/xmpp4r/iq/query/discoinfo.rb lib/xmpp4r/error.rb lib/xmpp4r/component.rb lib/xmpp4r/message.rb lib/xmpp4r/iq/query/discoitems.rb lib/xmpp4r/presence.rb lib/xmpp4r/helpers/roster.rb lib/xmpp4r/helpers/vcard.rb lib/xmpp4r/helpers/version.rb Helpers Jabber Module: Jabber

XMPP4R - XMPP Library for Ruby

License:Ruby’s license (see the LICENSE file) or GNU GPL, at your option.

Website::http://home.gna.org/xmpp4r/

Methods

debug   debug=   debuglog  

Classes and Modules

Module Jabber::Helpers
Class Jabber::AuthenticationFailure
Class Jabber::Client
Class Jabber::Component
Class Jabber::Connection
Class Jabber::DiscoFeature
Class Jabber::DiscoIdentity
Class Jabber::DiscoItem
Class Jabber::Error
Class Jabber::ErrorException
Class Jabber::IdGenerator
Class Jabber::Iq
Class Jabber::IqQuery
Class Jabber::IqQueryDiscoInfo
Class Jabber::IqQueryDiscoItems
Class Jabber::IqQueryRoster
Class Jabber::IqQueryVersion
Class Jabber::IqVcard
Class Jabber::JID
Class Jabber::Message
Class Jabber::Presence
Class Jabber::RosterItem
Class Jabber::Stream
Class Jabber::StreamParser
Class Jabber::X
Class Jabber::XDelay
Class Jabber::XMLStanza
Class Jabber::XMuc
Class Jabber::XMucUser
Class Jabber::XMucUserItem
Class Jabber::XRoster
Class Jabber::XRosterItem

Constants

XMPP4R_VERSION = '0.2'   XMPP4R Version number

Public Class methods

returns true if debugging mode is enabled. If you just want to log something if debugging is enabled, use Jabber::debuglog instead.

[Source]

    # File lib/xmpp4r/debuglog.rb, line 21
21:   def Jabber::debug
22:     @@debug
23:   end

Enable/disable debugging mode. When debug mode is enabled, information can be logged using Jabber::debuglog. When debug mode is disabled, calls to Jabber::debuglog are just ignored.

[Source]

    # File lib/xmpp4r/debuglog.rb, line 12
12:   def Jabber::debug=(debug)
13:     @@debug = debug
14:     if @@debug
15:       debuglog('Debugging mode enabled.')
16:     end
17:   end

Outputs a string only if debugging mode is enabled. If the string includes several lines, 4 spaces are added at the begginning of each line but the first one. Time is prepended to the string.

[Source]

    # File lib/xmpp4r/debuglog.rb, line 28
28:   def Jabber::debuglog(string)
29:     return if not @@debug
30:     s = string.chomp.gsub("\n", "\n    ")
31:     t = Time::new.strftime('%H:%M:%S')
32:     puts "#{t} #{s}"
33:   end

[Validate]