Class: Cape::RecipeDefinitionDeprecated Private

Inherits:
RecipeDefinition show all
Defined in:
lib/cape/recipe_definition_deprecated.rb

Overview

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

Implements RecipeDefinition with deprecated methods.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RecipeDefinition

#cd, #env, #options, #rename

Constructor Details

#initialize(deprecation) ⇒ RecipeDefinitionDeprecated

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.

Constructs a new RecipeDefinitionDeprecated with the specified deprecation.

Parameters:



19
20
21
# File 'lib/cape/recipe_definition_deprecated.rb', line 19

def initialize(deprecation)
  @deprecation = deprecation
end

Instance Attribute Details

#deprecationDeprecation::Base (readonly)

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 object in which deprecated API usage is recorded.

Returns:



13
14
15
# File 'lib/cape/recipe_definition_deprecated.rb', line 13

def deprecation
  @deprecation
end

Instance Method Details

#[]=(name, value) ⇒ RecipeDefinitionDeprecated

Deprecated.

Sets a remote environment variable.

Parameters:

  • name (String)

    the name of a remote environment variable

  • value (String)

    a value for the remote environment variable

Returns:



33
34
35
36
37
# File 'lib/cape/recipe_definition_deprecated.rb', line 33

def []=(name, value)
  env[name]             = value
  deprecation.env[name] = value
  self
end