def update_resource attr, value
client_opts = {}
client_opts[:identity] = identity
case attr.name
when :bounce_topic_arn
method = :set_identity_notification_topic
client_opts[:notification_type] = 'Bounce'
client_opts[:sns_topic] = value if value
when :complaint_topic_arn
method = :set_identity_notification_topic
client_opts[:notification_type] = 'Complaint'
client_opts[:sns_topic] = value if value
when :forwarding_enabled
method = :set_identity_feedback_forwarding_enabled
client_opts[:forwarding_enabled] = value
when :dkim_enabled
method = :set_identity_dkim_enabled
client_opts[:dkim_enabled] = value
else raise "unhandled attribute: #{attr.name}"
end
client.send(method, client_opts)
end