Class: EY::Backup::Engine
Constant Summary
Constants included
from Spawner
Spawner::CHUNK_SIZE
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
Methods included from Spawner
#ioify, #run, #runs?, #spawn
Methods inherited from Base
#logger
Constructor Details
#initialize(username, password, host, key_id) ⇒ Engine
Returns a new instance of Engine.
29
30
31
|
# File 'lib/ey_backup/engine.rb', line 29
def initialize(username, password, host, key_id)
@username, @password, @host, @key_id = username, password, host, key_id
end
|
Instance Attribute Details
#host ⇒ Object
Returns the value of attribute host.
6
7
8
|
# File 'lib/ey_backup/engine.rb', line 6
def host
@host
end
|
#key_id ⇒ Object
Returns the value of attribute key_id.
6
7
8
|
# File 'lib/ey_backup/engine.rb', line 6
def key_id
@key_id
end
|
#password ⇒ Object
Returns the value of attribute password.
6
7
8
|
# File 'lib/ey_backup/engine.rb', line 6
def password
@password
end
|
#username ⇒ Object
Returns the value of attribute username.
6
7
8
|
# File 'lib/ey_backup/engine.rb', line 6
def username
@username
end
|
Class Method Details
.descendants ⇒ Object
16
17
18
|
# File 'lib/ey_backup/engine.rb', line 16
def self.descendants
@descendants ||= []
end
|
.inherited(descendant) ⇒ Object
20
21
22
|
# File 'lib/ey_backup/engine.rb', line 20
def self.inherited(descendant)
descendants << descendant
end
|
.label ⇒ Object
8
9
10
|
# File 'lib/ey_backup/engine.rb', line 8
def self.label
@label
end
|
.lookup(label) ⇒ Object
24
25
26
27
|
# File 'lib/ey_backup/engine.rb', line 24
def self.lookup(label)
descendants.detect {|d| d.label == label } ||
EY::Backup.logger.fatal("Unknown database engine: #{label}")
end
|
.register(label) ⇒ Object
12
13
14
|
# File 'lib/ey_backup/engine.rb', line 12
def self.register(label)
@label = label
end
|
Instance Method Details
#gpg? ⇒ Boolean
33
34
35
|
# File 'lib/ey_backup/engine.rb', line 33
def gpg?
!key_id.nil? && key_id != ""
end
|