Class: CfFactory::CfRoute53RecordSetGroup

Inherits:
Object
  • Object
show all
Includes:
CfBase
Defined in:
lib/cf_factory/route53/cf_route53_record_set_group.rb

Instance Method Summary collapse

Methods included from CfBase

#generate, #generate_ref, #get_deletion_policy, #get_name, #get_update_policy, #hash_to_string, #retrieve_attribute, #set_meta_data, #set_quotes, #set_tags

Constructor Details

#initialize(name, record_sets, options) ⇒ CfRoute53RecordSetGroup

Returns a new instance of CfRoute53RecordSetGroup.

Raises:

  • (Exception)


8
9
10
11
12
13
14
15
16
# File 'lib/cf_factory/route53/cf_route53_record_set_group.rb', line 8

def initialize(name, record_sets, options)
  raise Exception.new("don't use for now")
  @name = name
  @record_sets = record_sets
  @hosted_zone_id = options[:hosted_zone_id]
  @hosted_zone_name = options[:hosted_zone_name]
  @comment = options[:comment]      
  validate()
end

Instance Method Details

#get_cf_attributesObject



22
23
24
# File 'lib/cf_factory/route53/cf_route53_record_set_group.rb', line 22

def get_cf_attributes
  {}
end

#get_cf_propertiesObject



26
27
28
29
30
31
32
33
# File 'lib/cf_factory/route53/cf_route53_record_set_group.rb', line 26

def get_cf_properties
  result = {}      
  result["RecordSets"] = CfHelper.generate_inner_array(@record_sets)
  result["Comment"] = @comment unless @comment.nil?
  result["HostedZoneId"] = @hosted_zone_id unless @hosted_zone_id.nil?
  result["HostedZoneName"] = @hosted_zone_name unless @hosted_zone_name.nil? 
  result
end

#get_cf_typeObject



18
19
20
# File 'lib/cf_factory/route53/cf_route53_record_set_group.rb', line 18

def get_cf_type
  "AWS::Route53::RecordSetGroup"
end