Class: PMD::Pause

Inherits:
Object
  • Object
show all
Defined in:
lib/pmd/pause.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializePause

Returns a new instance of Pause.



5
6
7
# File 'lib/pmd/pause.rb', line 5

def initialize

end

Class Method Details

.is_pausedObject



9
10
11
12
13
14
15
# File 'lib/pmd/pause.rb', line 9

def self.is_paused
  
  if File.exists? Config.pause_path
    return true
  end
  return false
end

Instance Method Details

#execute!Object



17
18
19
20
21
22
23
24
25
# File 'lib/pmd/pause.rb', line 17

def execute!

  if not File.exists? Config.pause_path
    FileUtils.touch Config.pause_path
  else
    FileUtils.rm Config.pause_path
  end

end