Class: Queuel::SQS::Queue
- Inherits:
-
Base::Queue
- Object
- Base::Queue
- Queuel::SQS::Queue
- Extended by:
- Forwardable
- Defined in:
- lib/queuel/sqs/queue.rb
Instance Attribute Summary collapse
-
#credentials ⇒ Object
Returns the value of attribute credentials.
Instance Method Summary collapse
- #approximate_number_of_messages ⇒ Object
-
#initialize(client, queue_name, credentials = {}) ⇒ Queue
constructor
A new instance of Queue.
- #push(message, options = {}) ⇒ Object
- #size ⇒ Object
Methods inherited from Base::Queue
#max_pool_tasks, #peek, #pop, #receive
Methods included from Introspect
#const_with_nesting, #module_names
Constructor Details
#initialize(client, queue_name, credentials = {}) ⇒ Queue
Returns a new instance of Queue.
10 11 12 13 14 |
# File 'lib/queuel/sqs/queue.rb', line 10 def initialize(client, queue_name, credentials={}) self.client = client self.name = queue_name self.credentials = credentials end |
Instance Attribute Details
#credentials ⇒ Object
Returns the value of attribute credentials.
8 9 10 |
# File 'lib/queuel/sqs/queue.rb', line 8 def credentials @credentials end |
Instance Method Details
#approximate_number_of_messages ⇒ Object
22 23 24 |
# File 'lib/queuel/sqs/queue.rb', line 22 def queue_connection. end |
#push(message, options = {}) ⇒ Object
17 18 19 20 |
# File 'lib/queuel/sqs/queue.rb', line 17 def push(, = {}) = , .merge(credentials) queue_connection. end |
#size ⇒ Object
26 27 28 |
# File 'lib/queuel/sqs/queue.rb', line 26 def size end |