Module: Jsus::Util::Mixins::OperatesOnSources

Included in:
PostProcessor::Base, Validator::Base
Defined in:
lib/jsus/util/mixins/operates_on_sources.rb

Instance Method Summary collapse

Instance Method Details

#source_filesArray Also known as: sources

Returns source files for validation.

Returns:

  • (Array)

    source files for validation



7
8
9
# File 'lib/jsus/util/mixins/operates_on_sources.rb', line 7

def source_files
  @source_files ||= []
end

#source_files=(pool_or_array_or_container) ⇒ Object Also known as: sources=

Parameters:



15
16
17
18
19
20
21
22
23
24
# File 'lib/jsus/util/mixins/operates_on_sources.rb', line 15

def source_files=(pool_or_array_or_container)
  case pool_or_array_or_container
  when Pool
    @source_files = pool_or_array_or_container.sources.to_a
  when Array
    @source_files = pool_or_array_or_container
  when Container
    @source_files = pool_or_array_or_container.to_a
  end
end