com.vodafone360.people.service.io.api
Class ApiUtils

java.lang.Object
  extended by com.vodafone360.people.service.io.api.ApiUtils

public class ApiUtils
extends java.lang.Object

Class which provides helper functions for assembling Vectors of data prior to Hessian encoding.


Constructor Summary
ApiUtils()
           
 
Method Summary
protected static java.util.Hashtable<java.lang.String,java.lang.Object> createHashTable(java.util.Map<java.lang.String,java.util.List<java.lang.String>> map)
          Create a Hash table from supplied Map, this is passed to Hessian encoder to create Hessian encoded request body.
protected static java.util.Vector<java.lang.Object> createVectorOfContact(java.util.List<Contact> list)
          Create Vector of of Hash table items from a list of Contacts (each Contact being represented by a Hash table).
protected static java.util.Vector<java.lang.Object> createVectorOfContactDetail(java.util.List<ContactDetail> list)
          Create vector from list of ContactDetails.
protected static java.util.Vector<java.lang.Object> createVectorOfGroup(java.util.List<GroupItem> list)
          Create Vector of of Hash table items from a list of GroupItems (each GroupItems being represented by a Hash table).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ApiUtils

public ApiUtils()
Method Detail

createHashTable

protected static java.util.Hashtable<java.lang.String,java.lang.Object> createHashTable(java.util.Map<java.lang.String,java.util.List<java.lang.String>> map)
Create a Hash table from supplied Map, this is passed to Hessian encoder to create Hessian encoded request body.

Parameters:
map - The source map.
Returns:
Hash table from supplied Map.

createVectorOfContactDetail

protected static java.util.Vector<java.lang.Object> createVectorOfContactDetail(java.util.List<ContactDetail> list)
Create vector from list of ContactDetails. This vector is passed to the Hessian encoder for generation of Hessian encoded message body.

Parameters:
list - List of contact details.
Returns:
New vector.

createVectorOfContact

protected static java.util.Vector<java.lang.Object> createVectorOfContact(java.util.List<Contact> list)
Create Vector of of Hash table items from a list of Contacts (each Contact being represented by a Hash table). This is supplied to Hessian encoder.

Parameters:
list - List-array of Contacts.
Returns:
Vector of Hash-tables representing Contact list.

createVectorOfGroup

protected static java.util.Vector<java.lang.Object> createVectorOfGroup(java.util.List<GroupItem> list)
Create Vector of of Hash table items from a list of GroupItems (each GroupItems being represented by a Hash table). This is supplied to Hessian encoder.

Parameters:
list - List-array of Contacts.
Returns:
Vector of Hash-tables representing GroupItems list.


JavaDoc