lib/chatrix/client.rb
# Starts syncing against the homeserver.
#
# Launches a new thread that will continously check for new events
# from the server.
#
# @see #sync! See the documentation for {#sync!} for more information
#   and what happens in case of an error during sync.
Starts syncing against the homeserver.
Launches a new thread that will continously check for new events
from the server.
Starts syncing against the homeserver . Launches a new thread that will continously check for new events from the server .
def start_syncing
      @sync_thread ||= Thread.new do
        begin
          loop { sync! }
        rescue => e
          broadcast(:connection_error, e)
        ensure
          broadcast(:disconnected)
        end
      end
    end
def start_syncing @sync_thread ||= Thread . new do begin loop { sync! } rescue => e broadcast ( :connection_error , e ) ensure broadcast ( :disconnected ) end end end
Starts syncing against the homeserver.
Starts syncing against the homeserver .
see
sync. See the documentation for {#sync!} for more information and what happens in case of an error during sync.
sync . See the documentation for { #sync! } for more information and what happens in case of an error during sync .