Class: Chef::Cookbook::MinimalMetadata

Inherits:
Metadata show all
Defined in:
lib/chef/cookbook/metadata.rb

Overview

Chef::Cookbook::MinimalMetadata

MinimalMetadata is a duck type of Cookbook::Metadata, used internally by Chef Server when determining the optimal set of cookbooks for a node.

MinimalMetadata objects typically contain only enough information to solve the cookbook collection for a run list, but not enough to generate the proper response

Constant Summary

Constants inherited from Metadata

Chef::Cookbook::Metadata::ATTRIBUTES, Chef::Cookbook::Metadata::COMPARISON_FIELDS, Chef::Cookbook::Metadata::CONFLICTING, Chef::Cookbook::Metadata::DEPENDENCIES, Chef::Cookbook::Metadata::DESCRIPTION, Chef::Cookbook::Metadata::GROUPINGS, Chef::Cookbook::Metadata::LICENSE, Chef::Cookbook::Metadata::LONG_DESCRIPTION, Chef::Cookbook::Metadata::MAINTAINER, Chef::Cookbook::Metadata::MAINTAINER_EMAIL, Chef::Cookbook::Metadata::NAME, Chef::Cookbook::Metadata::PLATFORMS, Chef::Cookbook::Metadata::PROVIDING, Chef::Cookbook::Metadata::RECIPES, Chef::Cookbook::Metadata::RECOMMENDATIONS, Chef::Cookbook::Metadata::REPLACING, Chef::Cookbook::Metadata::SUGGESTIONS, Chef::Cookbook::Metadata::VERSION, Chef::Cookbook::Metadata::VERSION_CONSTRAINTS

Instance Attribute Summary

Attributes inherited from Metadata

#attributes, #conflicting, #cookbook, #dependencies, #groupings, #platforms, #providing, #recipes, #recommendations, #replacing, #suggestions, #version

Instance Method Summary collapse

Methods inherited from Metadata

#==, #attribute, #conflicts, #depends, #description, #from_hash, from_hash, from_json, #from_json, #grouping, #license, #long_description, #maintainer, #maintainer_email, #name, #provides, #recipe, #recommends, #replaces, #suggests, #supports, #to_hash, #to_json, validate_json

Methods included from Mixin::FromFile

#class_from_file, #from_file

Methods included from Mixin::ParamsValidate

#set_or_return, #validate

Methods included from Mixin::CheckHelper

#set_if_args

Constructor Details

#initialize(name, params) ⇒ MinimalMetadata

Returns a new instance of MinimalMetadata.



621
622
623
624
# File 'lib/chef/cookbook/metadata.rb', line 621

def initialize(name, params)
  @name = name
  from_hash(params)
end