Class: LearnDoctor::HealthCheck::File
- Inherits:
-
Object
- Object
- LearnDoctor::HealthCheck::File
- Defined in:
- lib/learn_doctor/health_check/file.rb
Instance Attribute Summary collapse
-
#check_or_install ⇒ Object
readonly
Returns the value of attribute check_or_install.
-
#conn ⇒ Object
readonly
Returns the value of attribute conn.
-
#file ⇒ Object
Returns the value of attribute file.
-
#step ⇒ Object
readonly
Returns the value of attribute step.
Instance Method Summary collapse
-
#initialize(step, check_or_install) ⇒ File
constructor
A new instance of File.
- #path ⇒ Object
- #unlink! ⇒ Object
Constructor Details
#initialize(step, check_or_install) ⇒ File
Returns a new instance of File.
7 8 9 10 11 12 13 14 15 |
# File 'lib/learn_doctor/health_check/file.rb', line 7 def initialize(step, check_or_install) @step = step @check_or_install = check_or_install @conn = Faraday.new prepare_file! return self end |
Instance Attribute Details
#check_or_install ⇒ Object (readonly)
Returns the value of attribute check_or_install.
4 5 6 |
# File 'lib/learn_doctor/health_check/file.rb', line 4 def check_or_install @check_or_install end |
#conn ⇒ Object (readonly)
Returns the value of attribute conn.
4 5 6 |
# File 'lib/learn_doctor/health_check/file.rb', line 4 def conn @conn end |
#file ⇒ Object
Returns the value of attribute file.
5 6 7 |
# File 'lib/learn_doctor/health_check/file.rb', line 5 def file @file end |
#step ⇒ Object (readonly)
Returns the value of attribute step.
4 5 6 |
# File 'lib/learn_doctor/health_check/file.rb', line 4 def step @step end |
Instance Method Details
#path ⇒ Object
21 22 23 |
# File 'lib/learn_doctor/health_check/file.rb', line 21 def path file.path end |
#unlink! ⇒ Object
17 18 19 |
# File 'lib/learn_doctor/health_check/file.rb', line 17 def unlink! self.file.unlink end |