Class: BackupFile
- Inherits:
-
Object
- Object
- BackupFile
- Includes:
- ActiveModel::SerializerSupport
- Defined in:
- app/models/backup_file.rb
Instance Attribute Summary collapse
-
#filename ⇒ Object
readonly
Returns the value of attribute filename.
-
#last_modified ⇒ Object
readonly
Returns the value of attribute last_modified.
-
#size ⇒ Object
readonly
Returns the value of attribute size.
-
#source ⇒ Object
readonly
Returns the value of attribute source.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(filename:, size:, last_modified:, source: nil) ⇒ BackupFile
constructor
A new instance of BackupFile.
Constructor Details
#initialize(filename:, size:, last_modified:, source: nil) ⇒ BackupFile
Returns a new instance of BackupFile.
8 9 10 11 12 13 |
# File 'app/models/backup_file.rb', line 8 def initialize(filename:, size:, last_modified:, source: nil) @filename = filename @size = size @last_modified = last_modified @source = source end |
Instance Attribute Details
#filename ⇒ Object (readonly)
Returns the value of attribute filename.
6 7 8 |
# File 'app/models/backup_file.rb', line 6 def filename @filename end |
#last_modified ⇒ Object (readonly)
Returns the value of attribute last_modified.
6 7 8 |
# File 'app/models/backup_file.rb', line 6 def last_modified @last_modified end |
#size ⇒ Object (readonly)
Returns the value of attribute size.
6 7 8 |
# File 'app/models/backup_file.rb', line 6 def size @size end |
#source ⇒ Object (readonly)
Returns the value of attribute source.
6 7 8 |
# File 'app/models/backup_file.rb', line 6 def source @source end |
Instance Method Details
#==(other) ⇒ Object
15 16 17 |
# File 'app/models/backup_file.rb', line 15 def ==(other) attributes == other.attributes end |