A module shared between {Topic} and {Subscription}. Provides methods for getting and setting the delivery policy and for getting the effective delivery policy.
@return [nil,Hash] Returns the delivery policy.
# File lib/aws/sns/has_delivery_policy.rb, line 23 def delivery_policy parse_delivery_policy(delivery_policy_json) end
@param [nil,Hash,String<JSON>] policy A delivery policy. You can
pass a JSON string, A policy hash or nil.
# File lib/aws/sns/has_delivery_policy.rb, line 34 def delivery_policy= policy policy_json = case policy when nil then '' when String then policy else policy.to_json end update_delivery_policy(policy_json) end
@return [nil,String] Returns the delivery policy JSON string.
# File lib/aws/sns/has_delivery_policy.rb, line 47 def delivery_policy_json raise NotImplementedError end
@return [Hash] Returns the effective delivery policy.
# File lib/aws/sns/has_delivery_policy.rb, line 28 def effective_delivery_policy parse_delivery_policy(effective_delivery_policy_json) end
@return [String] Returns the effective delivery policy JSON string.
# File lib/aws/sns/has_delivery_policy.rb, line 52 def effective_delivery_policy_json raise NotImplementedError end
# File lib/aws/sns/has_delivery_policy.rb, line 57 def parse_delivery_policy policy_json policy_json.nil? ? nil : JSON.parse(policy_json) end
# File lib/aws/sns/has_delivery_policy.rb, line 62 def update_delivery_policy policy_json raise NotImplementedError end