Sha256: fcef94279397e84738a360e5d3761dca0ae2bf4eef942c3b6b9314e17ec3718f

Contents?: true

Size: 818 Bytes

Versions: 31

Compression:

Stored size: 818 Bytes

Contents

require 'rbbt/association'
require 'rbbt/association/item'
require 'rbbt/knowledge_base/entity'
require 'rbbt/knowledge_base/query'
require 'rbbt/knowledge_base/syndicate'

class KnowledgeBase

  attr_accessor :namespace, :dir, :databases, :indices, :registry, :format, :entity_options
  def initialize(dir, namespace = nil)
    @dir = Path.setup(dir.dup)

    @namespace = namespace
    @format = IndiferentHash.setup({})

    @registry ||= IndiferentHash.setup({})
    @entity_options = IndiferentHash.setup({})

    @indices = IndiferentHash.setup({})
    @databases = IndiferentHash.setup({})
    @identifiers = IndiferentHash.setup({})
    @fields = {}
    @descriptions = {}
    @databases = {}
  end

  def setup(name, matches, reverse = false)
    AssociationItem.setup matches, self, name, reverse
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
rbbt-util-5.19.18 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.17 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.16 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.15 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.14 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.13 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.12 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.11 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.10 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.9 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.8 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.7 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.6 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.5 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.4 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.3 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.2 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.1 lib/rbbt/knowledge_base.rb
rbbt-util-5.19.0 lib/rbbt/knowledge_base.rb
rbbt-util-5.18.1 lib/rbbt/knowledge_base.rb