Class: JSHint4r::Target
- Inherits:
-
Object
- Object
- JSHint4r::Target
- Defined in:
- lib/jshint4r/target.rb
Instance Attribute Summary collapse
-
#excludes ⇒ Object
readonly
Returns the value of attribute excludes.
-
#targets ⇒ Object
readonly
Returns the value of attribute targets.
Instance Method Summary collapse
- #each(&block) ⇒ Object
-
#initialize(targets, excludes = nil) ⇒ Target
constructor
A new instance of Target.
-
#real_targets ⇒ Object
- return
-
Rake::FileList.
Constructor Details
#initialize(targets, excludes = nil) ⇒ Target
Returns a new instance of Target.
5 6 7 8 |
# File 'lib/jshint4r/target.rb', line 5 def initialize( targets, excludes = nil ) @targets = targets || [] @excludes = excludes || [] end |
Instance Attribute Details
#excludes ⇒ Object (readonly)
Returns the value of attribute excludes.
9 10 11 |
# File 'lib/jshint4r/target.rb', line 9 def excludes @excludes end |
#targets ⇒ Object (readonly)
Returns the value of attribute targets.
9 10 11 |
# File 'lib/jshint4r/target.rb', line 9 def targets @targets end |
Instance Method Details
#each(&block) ⇒ Object
11 12 13 14 15 |
# File 'lib/jshint4r/target.rb', line 11 def each( &block ) real_targets.each { |f| block.call( f ) } end |
#real_targets ⇒ Object
- return
-
Rake::FileList
20 21 22 23 24 25 26 |
# File 'lib/jshint4r/target.rb', line 20 def real_targets if ( !@real_targets ) @real_targets = target_files end @real_targets end |