Class: SQSAttributes
- Inherits:
-
Object
- Object
- SQSAttributes
- Extended by:
- SQS::Utilities
- Defined in:
- lib/sqs_async/sqs_attributes.rb
Instance Attribute Summary collapse
-
#approximate_number_of_messages ⇒ Object
Returns the value of attribute approximate_number_of_messages.
-
#approximate_number_of_messages_not_visible ⇒ Object
Returns the value of attribute approximate_number_of_messages_not_visible.
-
#create_timestamp ⇒ Object
Returns the value of attribute create_timestamp.
-
#last_modified_timestamp ⇒ Object
Returns the value of attribute last_modified_timestamp.
-
#maximum_message_size ⇒ Object
Returns the value of attribute maximum_message_size.
-
#message_retention_period ⇒ Object
Returns the value of attribute message_retention_period.
-
#policy ⇒ Object
Returns the value of attribute policy.
-
#queue_arn ⇒ Object
Returns the value of attribute queue_arn.
-
#visibility_timeout ⇒ Object
Returns the value of attribute visibility_timeout.
Class Method Summary collapse
Methods included from SQS::Utilities
action_from_caller, camelize, underscore
Instance Attribute Details
#approximate_number_of_messages ⇒ Object
Returns the value of attribute approximate_number_of_messages.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def @approximate_number_of_messages end |
#approximate_number_of_messages_not_visible ⇒ Object
Returns the value of attribute approximate_number_of_messages_not_visible.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def @approximate_number_of_messages_not_visible end |
#create_timestamp ⇒ Object
Returns the value of attribute create_timestamp.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def @create_timestamp end |
#last_modified_timestamp ⇒ Object
Returns the value of attribute last_modified_timestamp.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def @last_modified_timestamp end |
#maximum_message_size ⇒ Object
Returns the value of attribute maximum_message_size.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def @maximum_message_size end |
#message_retention_period ⇒ Object
Returns the value of attribute message_retention_period.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def @message_retention_period end |
#policy ⇒ Object
Returns the value of attribute policy.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def policy @policy end |
#queue_arn ⇒ Object
Returns the value of attribute queue_arn.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def queue_arn @queue_arn end |
#visibility_timeout ⇒ Object
Returns the value of attribute visibility_timeout.
10 11 12 |
# File 'lib/sqs_async/sqs_attributes.rb', line 10 def visibility_timeout @visibility_timeout end |
Class Method Details
.parse(xml) ⇒ Object
20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/sqs_async/sqs_attributes.rb', line 20 def self.parse(xml) doc = Nokogiri::XML(xml) queue_data = SQSAttributes.new doc.search("Attribute").each do |attribute| meth = underscore(attribute.at("Name").text.strip) if queue_data.respond_to? meth.to_sym queue_data.send "#{meth}=", attribute.at("Value").text.strip end end queue_data end |