Sha256: 962afa4094c63c766e43b22b62400bd5a5b808c7e8856454ec8a30f32e0e7558
Contents?: true
Size: 680 Bytes
Versions: 1
Compression:
Stored size: 680 Bytes
Contents
# Response object. # Generated on each ActiveSMS.send_sms by backend implementations. class ActiveSMS::Response # see initialize attr_reader :status # see initialize attr_accessor :meta # @param status [Symbol] # Status of sms request. Anything other than *:success* considered as failure. # @param meta [Hash] # Meta information which optionally can be returned by backend. def initialize(status:, meta: nil) @status = status @meta = meta end # @return [Boolean] whether request was succesful or not. def success? @status == :success end # @return [Boolean] whether request has failed or not. def failed? !success? end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
active_sms-0.2.1 | lib/active_sms/response.rb |