Sha256: a69b4c621cded9c5a30fb4abcc4f43a68d523af19319cc49237edfb7437d898f

Contents?: true

Size: 950 Bytes

Versions: 12

Compression:

Stored size: 950 Bytes

Contents

#
# bitclust/server.rb
#
# Copyright (c) 2006-2008 Minero Aoki
#
# This program is free software.
# You can distribute/modify this program under the Ruby License.
#

require 'bitclust/methoddatabase'
require 'bitclust/functiondatabase'
require 'bitclust/libraryentry'
require 'bitclust/classentry'
require 'bitclust/methodentry'
require 'bitclust/docentry'
require 'drb'
require 'webrick/server'

module BitClust

  class Server

    def initialize(db)
      @db = db
    end

    def listen(url, foreground = false)
      WEBrick::Daemon.start unless foreground
      DRb.start_service url, @db
      DRb.thread.join
    end

  end

  class Database   # reopen
    include DRb::DRbUndumped
  end

  class Entry   # reopen
    include DRb::DRbUndumped
  end

  class SearchResult   # reopen
    include DRb::DRbUndumped
  end

end

class Object
  def _remote_object?
    false
  end
end

class DRb::DRbObject
  def _remote_object?
    true
  end
end

Version data entries

12 entries across 8 versions & 1 rubygems

Version Path
bitclust-core-0.7.0 lib/bitclust/server.rb
bitclust-core-0.6.0 lib/bitclust/server.rb
bitclust-core-0.5.5 lib/bitclust/server.rb
bitclust-core-0.5.4 lib/bitclust/server.rb
bitclust-core-0.5.3 vendor/bundle/ruby/1.9.1/gems/bitclust-core-0.5.3/vendor/bundle/ruby/1.9.1/gems/bitclust-core-0.5.1/lib/bitclust/server.rb
bitclust-core-0.5.3 vendor/bundle/ruby/1.9.1/gems/bitclust-core-0.5.1/lib/bitclust/server.rb
bitclust-core-0.5.3 lib/bitclust/server.rb
bitclust-core-0.5.3 vendor/bundle/ruby/1.9.1/gems/bitclust-core-0.5.3/lib/bitclust/server.rb
bitclust-core-0.5.2 lib/bitclust/server.rb
bitclust-core-0.5.2 vendor/bundle/ruby/1.9.1/gems/bitclust-core-0.5.1/lib/bitclust/server.rb
bitclust-core-0.5.1 lib/bitclust/server.rb
bitclust-core-0.5.0 lib/bitclust/server.rb