Class: Humidifier::Fn

Inherits:
Object
  • Object
show all
Defined in:
lib/humidifier/fn.rb

Constant Summary collapse

FUNCTIONS =

The list of all internal functions provided by AWS from http://docs.aws.amazon.com /AWSCloudFormation/latest/UserGuide/intrinsic-function-reference.html

Humidifier.underscore(
  %w[And Base64 Cidr Equals FindInMap GetAtt GetAZs If ImportValue Join
     Not Or Select Split Sub Transform]
)

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, value) ⇒ Fn

Returns a new instance of Fn.



16
17
18
19
# File 'lib/humidifier/fn.rb', line 16

def initialize(name, value)
  @name = "Fn::#{name}"
  @value = value
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



14
15
16
# File 'lib/humidifier/fn.rb', line 14

def name
  @name
end

#valueObject (readonly)

Returns the value of attribute value.



14
15
16
# File 'lib/humidifier/fn.rb', line 14

def value
  @value
end

Instance Method Details

#to_cfObject



21
22
23
# File 'lib/humidifier/fn.rb', line 21

def to_cf
  { name => Serializer.dump(value) }
end