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.



108
109
110
111
112
113
114
115
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 108

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

Instance Method Details

#inspectObject

Provide a detailed, user friendly representation



132
133
134
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 132

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.



120
121
122
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 120

def success
    @properties['success']
end

#to_sObject

Provide a user friendly representation



126
127
128
# File 'lib/twilio-ruby/rest/messaging/v2/typing_indicator.rb', line 126

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