# File lib/ohai/dsl/plugin/versionvi.rb, line 46 def self.collect_contents(contents) define_method(:run_plugin) { self.instance_eval(contents) } end
# File lib/ohai/dsl/plugin/versionvi.rb, line 27 def initialize(controller, plugin_path, plugin_dir_path) super(controller.data) @controller = controller @version = :version6 @source = plugin_path @plugin_dir_path = plugin_dir_path end
# File lib/ohai/dsl/plugin/versionvi.rb, line 35 def name # Ohai V6 doesn't have any name specification for plugins. # So we are using the partial path to infer the name of the plugin partial_path = Pathname.new(@source).relative_path_from(Pathname.new(@plugin_dir_path)).to_s partial_path.chomp(".rb").gsub("/", "::") end
Generated with the Darkfish Rdoc Generator 2.