Module: Grass::FileSync

Included in:
Source
Defined in:
lib/grass/file_sync.rb

Defined Under Namespace

Classes: FileProxy

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#fileObject (readonly)

Returns the value of attribute file.



52
53
54
# File 'lib/grass/file_sync.rb', line 52

def file
  @file
end

Class Method Details

.included(base) ⇒ Object



46
47
48
49
50
# File 'lib/grass/file_sync.rb', line 46

def self.included(base)
  base.send :after_initialize, :init_file, if: 'binary.nil?'
  base.send :before_save, :write_file, if: 'binary.nil?'
  base.send :after_destroy, :delete_file, if: 'binary.nil?'
end