Class: Krakow::Command::Req

Inherits:
Krakow::Command show all
Defined in:
lib/krakow/command/req.rb

Overview

Re-queue a message

Instance Attribute Summary (collapse)

Attributes (collapse)

Class Method Summary (collapse)

Instance Method Summary (collapse)

Instance Attribute Details

- (Krakow::FrameType) response Originally defined in class Krakow::Command

Returns response to command

Returns:

Class Method Details

+ (Object) error



25
26
27
# File 'lib/krakow/command/req.rb', line 25

def error
  %w(E_INVALID E_REQ_FAILED)
end

Instance Method Details

- (String) message_id

Returns the message_id attribute

Returns:

  • (String)

    the message_id attribute



15
# File 'lib/krakow/command/req.rb', line 15

attribute :message_id, String, :required => true

- (TrueClass, FalseClass) message_id?

Returns truthiness of the message_id attribute

Returns:

  • (TrueClass, FalseClass)

    truthiness of the message_id attribute



15
# File 'lib/krakow/command/req.rb', line 15

attribute :message_id, String, :required => true

- (Integer) timeout

Returns the timeout attribute

Returns:

  • (Integer)

    the timeout attribute



16
# File 'lib/krakow/command/req.rb', line 16

attribute :timeout, Integer, :required => true

- (TrueClass, FalseClass) timeout?

Returns truthiness of the timeout attribute

Returns:

  • (TrueClass, FalseClass)

    truthiness of the timeout attribute



16
# File 'lib/krakow/command/req.rb', line 16

attribute :timeout, Integer, :required => true

- (Object) to_line



20
21
22
# File 'lib/krakow/command/req.rb', line 20

def to_line
  "#{name} #{message_id} #{self.timeout}\n"
end