lib/puppet/pops/validation.rb
# A producer of severity for a given issue
# @return [SeverityProducer]
#
A producer of severity for a given issue
A producer of severity for a given issue
def accept(issue, semantic, arguments={}, except=nil)
      return unless will_accept? issue
      arguments[:label]    ||= @label_provider
      arguments[:semantic] ||= semantic
      arguments[:detail] ||= ''
      origin_adapter = Puppet::Pops::Utils.find_adapter(semantic, Puppet::Pops::Adapters::OriginAdapter)
      file = origin_adapter ? origin_adapter.origin : nil
      source_pos = Puppet::Pops::Utils.find_adapter(semantic, Puppet::Pops::Adapters::SourcePosAdapter)
      severity = @severity_producer.severity(issue)
      @acceptor.accept(Diagnostic.new(severity, issue, file, source_pos, arguments))
    end
def accept ( issue , semantic , arguments = { } , except = nil ) return unless will_accept? issue arguments [ :label ] ||= @label_provider arguments [ :semantic ] ||= semantic arguments [ :detail ] ||= '' origin_adapter = Puppet :: Pops :: Utils . find_adapter ( semantic , Puppet :: Pops :: Adapters :: OriginAdapter ) file = origin_adapter ? origin_adapter . origin : nil source_pos = Puppet :: Pops :: Utils . find_adapter ( semantic , Puppet :: Pops :: Adapters :: SourcePosAdapter ) severity = @severity_producer . severity ( issue ) @acceptor . accept ( Diagnostic . new ( severity , issue , file , source_pos , arguments ) ) end
A producer of severity for a given issue
A producer of severity for a given issue
# Set label provider unless caller provided a special label provider # A detail message is always provided, but is blank by default.
None
SeverityProducer
issue
<not_specific>
semantic
<not_specific>
arguments
<not_specific>
except
<not_specific>