com.twilio.sdk.resource
Class InstanceResource<C extends TwilioClient>

java.lang.Object
  extended by com.twilio.sdk.resource.Resource<C>
      extended by com.twilio.sdk.resource.InstanceResource<C>
Direct Known Subclasses:
Account, Address, Application, AuthorizedConnectApp, AvailablePhoneNumber, Call, Conference, ConnectApp, Credential, CredentialListInstance, CredentialListMapping, DependentPhoneNumber, Domain, Feedback, FeedbackSummary, IncomingPhoneNumber, IpAccessControlList, IpAccessControlListMapping, IpAddress, Media, Member, Message, NextGenInstanceResource, Notification, OutgoingCallerId, Participant, Queue, Recording, Sandbox, ShortCode, Sms, Token, Transcription, UsageRecord, UsageTrigger

public abstract class InstanceResource<C extends TwilioClient>
extends Resource<C>

The Class InstanceResource.


Constructor Summary
InstanceResource(C client)
          Instantiates a new instance resource.
InstanceResource(C client, Map<String,Object> properties)
          Instantiates a new instance resource.
InstanceResource(C client, Map<String,Object> properties, Map<String,String> filters)
          Instantiates a new instance resource.
 
Method Summary
 Object getObject(String name)
          Gets the property as an Object.
 String getProperty(String name)
          Gets the property.
 void update(List<org.apache.http.NameValuePair> params)
          Update.
 void update(Map<String,String> params)
          Update.
 
Methods inherited from class com.twilio.sdk.resource.Resource
setRequestAccountSid
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InstanceResource

public InstanceResource(C client)
Instantiates a new instance resource.

Parameters:
client - the client

InstanceResource

public InstanceResource(C client,
                        Map<String,Object> properties)
Instantiates a new instance resource.

Parameters:
client - the client
properties - the properties

InstanceResource

public InstanceResource(C client,
                        Map<String,Object> properties,
                        Map<String,String> filters)
Instantiates a new instance resource.

Parameters:
client - the client
properties - the properties
filters - the filters
Method Detail

getProperty

public String getProperty(String name)
Gets the property.

Parameters:
name - the name
Returns:
the property, or null if it doesn't exist or is NULL in the response

getObject

public Object getObject(String name)
Gets the property as an Object.

Parameters:
name - the name of the property
Returns:
the property as an Object

update

public void update(Map<String,String> params)
            throws TwilioRestException
Update.

Parameters:
params - the params
Throws:
TwilioRestException - the twilio rest exception

update

public void update(List<org.apache.http.NameValuePair> params)
            throws TwilioRestException
Update.

Parameters:
params - the params list
Throws:
TwilioRestException - the twilio rest exception


Copyright © 2011 Twilio, Inc. All Rights Reserved.