Module: DbVcs::AdapterInterface

Included in:
DbVcs::Adapters::Mongo, DbVcs::Adapters::Mysql, DbVcs::Adapters::Postgres
Defined in:
lib/db_vcs/adapter_interface.rb

Instance Method Summary collapse

Instance Method Details

#configObject

Raises:

  • (NotImplementedError)


5
6
7
# File 'lib/db_vcs/adapter_interface.rb', line 5

def config
  raise NotImplementedError, "You have to implement this method in adapter's class"
end

#connectionObject

Raises:

  • (NotImplementedError)


9
10
11
# File 'lib/db_vcs/adapter_interface.rb', line 9

def connection
  raise NotImplementedError, "You have to implement this method in adapter's class"
end

#copy_database(to_db, from_db) ⇒ Object

Raises:

  • (NotImplementedError)


17
18
19
# File 'lib/db_vcs/adapter_interface.rb', line 17

def copy_database(to_db, from_db)
  raise NotImplementedError, "You have to implement this method in adapter's class"
end

#create_database(db_name) ⇒ Object

Raises:

  • (NotImplementedError)


21
22
23
# File 'lib/db_vcs/adapter_interface.rb', line 21

def create_database(db_name)
  raise NotImplementedError, "You have to implement this method in adapter's class"
end

#db_exists?(db_name) ⇒ Boolean

Returns:

  • (Boolean)

Raises:

  • (NotImplementedError)


13
14
15
# File 'lib/db_vcs/adapter_interface.rb', line 13

def db_exists?(db_name)
  raise NotImplementedError, "You have to implement this method in adapter's class"
end

#drop_by_dbname(db_name) ⇒ Object

Raises:

  • (NotImplementedError)


29
30
31
# File 'lib/db_vcs/adapter_interface.rb', line 29

def drop_by_dbname(db_name)
  raise NotImplementedError, "You have to implement this method in adapter's class"
end

#list_databasesObject

Raises:

  • (NotImplementedError)


25
26
27
# File 'lib/db_vcs/adapter_interface.rb', line 25

def list_databases
  raise NotImplementedError, "You have to implement this method in adapter's class"
end