Class: ActionMailbox::Relayer::Result
- Defined in:
- actionmailbox/lib/action_mailbox/relayer.rb
Instance Attribute Summary collapse
-
#message ⇒ Object
Returns the value of attribute message.
-
#status_code ⇒ Object
Returns the value of attribute status_code.
Instance Method Summary collapse
Methods inherited from Struct
Instance Attribute Details
#message ⇒ Object
Returns the value of attribute message
9 10 11 |
# File 'actionmailbox/lib/action_mailbox/relayer.rb', line 9 def @message end |
#status_code ⇒ Object
Returns the value of attribute status_code
9 10 11 |
# File 'actionmailbox/lib/action_mailbox/relayer.rb', line 9 def status_code @status_code end |
Instance Method Details
#failure? ⇒ Boolean
14 15 16 |
# File 'actionmailbox/lib/action_mailbox/relayer.rb', line 14 def failure? transient_failure? || permanent_failure? end |
#permanent_failure? ⇒ Boolean
22 23 24 |
# File 'actionmailbox/lib/action_mailbox/relayer.rb', line 22 def permanent_failure? status_code.start_with?("5.") end |
#success? ⇒ Boolean
10 11 12 |
# File 'actionmailbox/lib/action_mailbox/relayer.rb', line 10 def success? !failure? end |
#transient_failure? ⇒ Boolean
18 19 20 |
# File 'actionmailbox/lib/action_mailbox/relayer.rb', line 18 def transient_failure? status_code.start_with?("4.") end |