class Launchy::Argv
Attributes
argv[R]
Public Class Methods
new( *args )
click to toggle source
# File lib/launchy/argv.rb, line 4 def initialize( *args ) @argv = args.flatten end
Public Instance Methods
==( other )
click to toggle source
# File lib/launchy/argv.rb, line 32 def ==( other ) @argv == other.argv end
[](idx)
click to toggle source
# File lib/launchy/argv.rb, line 16 def [](idx) @argv[idx] end
blank?()
click to toggle source
# File lib/launchy/argv.rb, line 24 def blank? @argv.empty? || (@argv.first.strip.size == 0) end
executable?()
click to toggle source
# File lib/launchy/argv.rb, line 28 def executable? ::Launchy::Application.find_executable( @argv.first ) end
to_s()
click to toggle source
# File lib/launchy/argv.rb, line 8 def to_s @argv.join(' ') end
to_str()
click to toggle source
# File lib/launchy/argv.rb, line 12 def to_str to_s end
valid?()
click to toggle source
# File lib/launchy/argv.rb, line 20 def valid? (not blank?) && executable? end