Oracle Fusion Middleware Java API Reference for Oracle Mobile Application Framework
2.0.0.0.0

E36392-01

oracle.adf.model.datacontrols.device
Class ContactAddresses

Object
  extended by oracle.adf.model.datacontrols.device.ContactAddresses
All Implemented Interfaces:
PostJSONDeserializable, PostJSONSerializable

public class ContactAddresses
extends Object
implements PostJSONSerializable, PostJSONDeserializable

Object used as part of a Contact


Constructor Summary
ContactAddresses()
          Default constructor
ContactAddresses(int id, String type, String formatted, String streetAddress, String locality, String region, String postalCode, String country)
          ContactAddresses constructor
 
Method Summary
 String getCountry()
          Get the country name
 String getFormatted()
          Get the formatted address
 int getId()
          Get a unique identifier for this address
 String getLocality()
          Get the city or locality
 String getPostalCode()
          Get the zip or postal code
 String getRegion()
          Get the state or region
 String getStreetAddress()
          Get the street address
 String getType()
          Get the type of the address
 oracle.adfmf.json.JSONObject modifyJSON(oracle.adfmf.json.JSONObject jsonObj)
          Method to normalize the JSON object.
 Object modifyObject(oracle.adfmf.json.JSONObject jsonObj)
          Method to update the class instance object by de-serializing the jsonObject into private setters.
 void setCountry(String country)
          Set the value for country
 void setFormatted(String formatted)
          Set the value for formatted address
 void setLocality(String locality)
          Set the value for locality
 void setPostalCode(String postalCode)
          Set the value for postal code
 void setRegion(String region)
          Set the value for region
 void setStreetAddress(String streetAddress)
          Set the value for street address
 void setType(String type)
          Set the value for address type
 String toString()
          Method to convert Contact object to string representation.
 
Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContactAddresses

public ContactAddresses()
Default constructor


ContactAddresses

public ContactAddresses(int id,
                        String type,
                        String formatted,
                        String streetAddress,
                        String locality,
                        String region,
                        String postalCode,
                        String country)
ContactAddresses constructor

Parameters:
id - for the contact
type - for the contact
formatted - for the contact
streetAddress - for the contact
locality - for the contact
region - for the contact
postalCode - for the contact
country - for the contact
Method Detail

getId

public int getId()
Get a unique identifier for this address

Returns:
A unique identifier for this address

getType

public String getType()
Get the type of the address

Returns:
A string that tells you what type of address this is (example: 'home')

getFormatted

public String getFormatted()
Get the formatted address

Returns:
The full address formatted for display

getStreetAddress

public String getStreetAddress()
Get the street address

Returns:
The full street address.

getLocality

public String getLocality()
Get the city or locality

Returns:
The city or locality.

getRegion

public String getRegion()
Get the state or region

Returns:
The state or region.

getPostalCode

public String getPostalCode()
Get the zip or postal code

Returns:
The zip code or postal code

getCountry

public String getCountry()
Get the country name

Returns:
The country name

setType

public void setType(String type)
Set the value for address type


setFormatted

public void setFormatted(String formatted)
Set the value for formatted address


setStreetAddress

public void setStreetAddress(String streetAddress)
Set the value for street address


setLocality

public void setLocality(String locality)
Set the value for locality


setRegion

public void setRegion(String region)
Set the value for region


setPostalCode

public void setPostalCode(String postalCode)
Set the value for postal code


setCountry

public void setCountry(String country)
Set the value for country


toString

public String toString()
Method to convert Contact object to string representation.

Overrides:
toString in class Object

modifyJSON

public oracle.adfmf.json.JSONObject modifyJSON(oracle.adfmf.json.JSONObject jsonObj)
Method to normalize the JSON object. This is done so as to remain in sync with what PhoneGap sends to iOS API calls.

Specified by:
modifyJSON in interface PostJSONSerializable
Parameters:
jsonObj - JSONObject to be modified.
Returns:
modified JSONObject

modifyObject

public Object modifyObject(oracle.adfmf.json.JSONObject jsonObj)
                    throws Exception
Method to update the class instance object by de-serializing the jsonObject into private setters.

Specified by:
modifyObject in interface PostJSONDeserializable
Parameters:
jsonObj - JSONObject to be modified.
Returns:
modified Object
Throws:
Exception

Oracle Fusion Middleware Java API Reference for Oracle Mobile Application Framework
2.0.0.0.0

E36392-01

Copyright © 2014 Oracle. All Rights Reserved.