Module: Puppet::Environments::EnvironmentLoader Private

Included in:
Cached, Combined, Directories, Static
Defined in:
lib/puppet/environments.rb

Overview

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Provide any common methods that loaders should have. It requires that any classes that include this module implement get

Instance Method Summary collapse

Instance Method Details

#clear_allObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



41
42
43
44
45
46
47
# File 'lib/puppet/environments.rb', line 41

def clear_all
  root = Puppet.lookup(:root_environment) { nil }
  unless root.nil?
    root.instance_variable_set(:@static_catalogs, nil)
    root.instance_variable_set(:@rich_data, nil)
  end
end

#get!(name) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



36
37
38
39
# File 'lib/puppet/environments.rb', line 36

def get!(name)
  environment = get(name)
  environment || raise(EnvironmentNotFound, name)
end

#guard(name) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

The base implementation is a noop, because ‘get` returns a new environment each time.

See Also:



53
# File 'lib/puppet/environments.rb', line 53

def guard(name); end

#unguard(name) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



54
# File 'lib/puppet/environments.rb', line 54

def unguard(name); end