Class: BackupFlag
- Inherits:
-
Object
- Object
- BackupFlag
- Defined in:
- lib/cassandra.rb
Instance Attribute Summary collapse
-
#cluster ⇒ Object
readonly
Returns the value of attribute cluster.
-
#date ⇒ Object
readonly
Returns the value of attribute date.
-
#file ⇒ Object
readonly
Returns the value of attribute file.
Instance Method Summary collapse
-
#initialize(cluster, file) ⇒ BackupFlag
constructor
A new instance of BackupFlag.
Constructor Details
#initialize(cluster, file) ⇒ BackupFlag
Returns a new instance of BackupFlag.
175 176 177 178 179 180 |
# File 'lib/cassandra.rb', line 175 def initialize(cluster, file) @cluster = cluster @file = file.dup date_as_string = file.sub! 'BACKUP_COMPLETED_', '' @date = DateTime.strptime(date_as_string, '%Y_%m_%d') end |
Instance Attribute Details
#cluster ⇒ Object (readonly)
Returns the value of attribute cluster.
173 174 175 |
# File 'lib/cassandra.rb', line 173 def cluster @cluster end |
#date ⇒ Object (readonly)
Returns the value of attribute date.
173 174 175 |
# File 'lib/cassandra.rb', line 173 def date @date end |
#file ⇒ Object (readonly)
Returns the value of attribute file.
173 174 175 |
# File 'lib/cassandra.rb', line 173 def file @file end |