Class: Hypostasis::Connection
- Inherits:
-
Object
- Object
- Hypostasis::Connection
- Includes:
- Singleton
- Defined in:
- lib/hypostasis/connection.rb
Class Method Summary collapse
- .create_namespace(name, options = {}) ⇒ Object
- .database ⇒ Object
- .destroy_namespace(name) ⇒ Object
- .open ⇒ Object
- .open_namespace(name) ⇒ Object
Class Method Details
.create_namespace(name, options = {}) ⇒ Object
17 18 19 |
# File 'lib/hypostasis/connection.rb', line 17 def self.create_namespace(name, = {}) Hypostasis::Namespace.create(name, ) end |
.database ⇒ Object
13 14 15 |
# File 'lib/hypostasis/connection.rb', line 13 def self.database @@database ||= FDB.open end |
.destroy_namespace(name) ⇒ Object
25 26 27 28 |
# File 'lib/hypostasis/connection.rb', line 25 def self.destroy_namespace(name) database.clear_range_start_with(name.to_s) true end |
.open ⇒ Object
9 10 11 |
# File 'lib/hypostasis/connection.rb', line 9 def self.open self end |
.open_namespace(name) ⇒ Object
21 22 23 |
# File 'lib/hypostasis/connection.rb', line 21 def self.open_namespace(name) Hypostasis::Namespace.open(name) end |