Class: QuickStart::Executable

Inherits:
Object
  • Object
show all
Defined in:
lib/quick_start/executable.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, path, options = {}) ⇒ Executable

Returns a new instance of Executable.



6
7
8
9
10
# File 'lib/quick_start/executable.rb', line 6

def	initialize(name, path, options = {})
	@name = name
	@path = path
	@options = options
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



4
5
6
# File 'lib/quick_start/executable.rb', line 4

def name
  @name
end

#optionsObject (readonly)

Returns the value of attribute options.



4
5
6
# File 'lib/quick_start/executable.rb', line 4

def options
  @options
end

#pathObject (readonly)

Returns the value of attribute path.



4
5
6
# File 'lib/quick_start/executable.rb', line 4

def path
  @path
end

Instance Method Details

#checkedObject Also known as: checked?



12
13
14
# File 'lib/quick_start/executable.rb', line 12

def checked
	options[:checked]
end

#checked=(value) ⇒ Object



18
19
20
# File 'lib/quick_start/executable.rb', line 18

def checked=(value)
	options[:checked] = value
end

#runObject



22
23
24
# File 'lib/quick_start/executable.rb', line 22

def	run
	Runner.run(self)
end