Class: OrientDbClient::ServerSession

Inherits:
Session
  • Object
show all
Defined in:
lib/orient_db_client/server_session.rb

Instance Attribute Summary

Attributes inherited from Session

#id

Instance Method Summary collapse

Methods inherited from Session

#initialize

Constructor Details

This class inherits a constructor from OrientDbClient::Session

Instance Method Details

#create_local_database(database, options = {}) ⇒ Object



5
6
7
8
9
# File 'lib/orient_db_client/server_session.rb', line 5

def create_local_database(database, options = {})
	options[:storage_type] = :local

	@connection.create_database(@id, database, options)
end

#create_memory_database(database, options = {}) ⇒ Object



11
12
13
14
15
# File 'lib/orient_db_client/server_session.rb', line 11

def create_memory_database(database, options = {})
	options[:storage_type] = :memory

	@connection.create_database(@id, database, options)
end

#database_exists?(database) ⇒ Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/orient_db_client/server_session.rb', line 17

def database_exists?(database)
	@connection.database_exists?(@id, database)
end

#delete_database(database) ⇒ Object



21
22
23
# File 'lib/orient_db_client/server_session.rb', line 21

def delete_database(database)
	@connection.delete_database(@id, database)
end