Method: Chef::Provider::OneVnet#exists?

Defined in:
lib/chef/provider/one_vnet.rb

#exists?(filter) ⇒ Boolean

Returns:

  • (Boolean)


37
38
39
40
41
42
# File 'lib/chef/provider/one_vnet.rb', line 37

def exists?(filter)
  new_driver = driver
  @current_vnet = new_driver.one.get_resource(:virtualnetwork, filter)
  Chef::Log.debug("VNET '#{filter}' exists: #{!@current_vnet.nil?}")
  !@current_vnet.nil?
end