Class: Puppet::Pops::Binder::BindingsValidatorFactory

Inherits:
Validation::Factory show all
Defined in:
lib/puppet/pops/binder/bindings_validator_factory.rb

Overview

Configures validation suitable for the bindings model

Constant Summary collapse

Issues =
Puppet::Pops::Binder::BinderIssues

Instance Method Summary collapse

Methods inherited from Validation::Factory

#diagnostic_producer, #validator

Instance Method Details

#checker(diagnostic_producer) ⇒ Object

Produces the checker to use



8
9
10
# File 'lib/puppet/pops/binder/bindings_validator_factory.rb', line 8

def checker diagnostic_producer
  Puppet::Pops::Binder::BindingsChecker.new(diagnostic_producer)
end

#label_providerObject

Produces the label provider to use



13
14
15
# File 'lib/puppet/pops/binder/bindings_validator_factory.rb', line 13

def label_provider
  Puppet::Pops::Binder::BindingsLabelProvider.new()
end

#severity_producerObject

Produces the severity producer to use



18
19
20
21
22
23
24
25
26
27
# File 'lib/puppet/pops/binder/bindings_validator_factory.rb', line 18

def severity_producer
  p = super

  # Configure each issue that should **not** be an error
  #
  p[Issues::MISSING_BINDINGS] = :warning
  p[Issues::MISSING_LAYERS]   = :warning

  p
end