Class: Fog::Parsers::AWS::RDS::EventSubscriptionParser

Inherits:
Base
  • Object
show all
Defined in:
lib/fog/aws/parsers/rds/event_subscription_parser.rb

Instance Method Summary collapse

Instance Method Details

#end_element(name) ⇒ Object



22
23
24
25
26
27
28
29
30
31
32
# File 'lib/fog/aws/parsers/rds/event_subscription_parser.rb', line 22

def end_element(name)
  case name
  when 'EventCategory'
    @event_subscription['EventCategories'] << value
    @in_event_categories_list = false
  when 'SubscriptionCreationTime'
    @event_subscription[name] = Time.parse(value)
  when 'Enabled', 'CustomerAwsId', 'SourceType', 'Status', 'CustSubscriptionId', 'SnsTopicArn'
    @event_subscription[name] = value
  end
end

#fresh_event_subscriptionObject



10
11
12
# File 'lib/fog/aws/parsers/rds/event_subscription_parser.rb', line 10

def fresh_event_subscription
  {'EventCategories'=> []}
end

#resetObject



6
7
8
# File 'lib/fog/aws/parsers/rds/event_subscription_parser.rb', line 6

def reset
  @event_subscription = fresh_event_subscription
end

#start_element(name, attrs = []) ⇒ Object



14
15
16
17
18
19
20
# File 'lib/fog/aws/parsers/rds/event_subscription_parser.rb', line 14

def start_element(name, attrs = [])
  super
  case name
  when 'EventCategoriesList'
    @in_event_categories_list = true
  end
end