Class: Twilio::REST::Messaging::V2::TypingIndicatorInstance

Inherits:
InstanceResource show all
Defined in:
lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload) ⇒ TypingIndicatorInstance

Initialize the TypingIndicatorInstance

Parameters:

  • version (Version)

    Version that contains the resource

  • payload (Hash)

    payload that contains response from Twilio

  • account_sid (String)

    The SID of the Account that created this TypingIndicator resource.

  • sid (String)

    The SID of the Call resource to fetch.



204
205
206
207
208
209
210
211
212
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 204

def initialize(version, payload )
    super(version)
    
    
    # Marshaled Properties
    @properties = { 
        'success' => payload['success'],
    }
end

Instance Method Details

#inspectObject

Provide a detailed, user friendly representation



229
230
231
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 229

def inspect
    "<Twilio.Messaging.V2.TypingIndicatorInstance>"
end

#successBoolean

Returns Indicates if the typing indicator was sent successfully.

Returns:

  • (Boolean)

    Indicates if the typing indicator was sent successfully.



217
218
219
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 217

def success
    @properties['success']
end

#to_sObject

Provide a user friendly representation



223
224
225
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 223

def to_s
    "<Twilio.Messaging.V2.TypingIndicatorInstance>"
end