Class: Chef::Provider::OneUser
- Inherits:
-
LWRPBase
- Object
- LWRPBase
- Chef::Provider::OneUser
- Defined in:
- lib/chef/provider/one_user.rb
Overview
Implementation of Provider class.
Instance Attribute Summary collapse
-
#current_user ⇒ Object
readonly
Returns the value of attribute current_user.
Instance Method Summary collapse
Instance Attribute Details
#current_user ⇒ Object (readonly)
Returns the value of attribute current_user.
31 32 33 |
# File 'lib/chef/provider/one_user.rb', line 31 def current_user @current_user end |
Instance Method Details
#action_handler ⇒ Object
33 34 35 |
# File 'lib/chef/provider/one_user.rb', line 33 def action_handler @action_handler ||= Chef::Provisioning::ChefProviderActionHandler.new(self) end |
#exists?(filter) ⇒ Boolean
37 38 39 40 41 42 |
# File 'lib/chef/provider/one_user.rb', line 37 def exists?(filter) new_driver = driver @current_user = new_driver.one.get_resource(:user, filter) Chef::Log.debug("user '#{filter}' exists: #{!@current_user.nil?}") !@current_user.nil? end |