de.janrufmonitor.framework
Interface ICallerFactory


public interface ICallerFactory

This interface must be implemented by a CallerFactory object, which should be used in the framework. A CallerFactory should be implemented as a singleton.

Author:
Thilo Brandt

Method Summary
 IAttribute createAttribute(String name, String value)
          Create an attribute with the specific data.
 IAttributeMap createAttributeList()
          Deprecated.  
 IAttributeMap createAttributeMap()
          Create an empty attribute map.
 ICaller createCaller(IName name, IPhonenumber phone)
          Create a new caller object with the specific data.
 ICaller createCaller(IName name, IPhonenumber phone, IAttribute attribute)
          Create a new caller object with the specific data.
 ICaller createCaller(IName name, IPhonenumber phone, IAttributeMap attributes)
          Create a new caller object with the specific data.
 IMultiPhoneCaller createCaller(IName name, List phones)
          Create a new caller object with the specific data.
 IMultiPhoneCaller createCaller(IName name, List phones, IAttributeMap attributes)
          Create a new caller object with the specific data.
 ICaller createCaller(IPhonenumber phone)
          Create a new caller object with the specific data.
 ICaller createCaller(String uuid, IName name, IPhonenumber phone)
          Create a new caller object with the specific data.
 ICaller createCaller(String uuid, IName name, IPhonenumber phone, IAttribute attribute)
          Create a new caller object with the specific data.
 ICaller createCaller(String uuid, IName name, IPhonenumber phone, IAttributeMap attributes)
          Create a new caller object with the specific data.
 IMultiPhoneCaller createCaller(String uuid, IName name, List phones, IAttributeMap attributes)
          Create a new multi phone caller object with the specific data.
 ICallerList createCallerList()
          Create an empty caller list.
 ICallerList createCallerList(int capacity)
          Create an empty caller list with an initial capacity.
 IPhonenumber createClirPhonenumber()
          Create a new phone number object with CLIR attribute.
 IPhonenumber createInternalPhonenumber(String internalNumber)
          Create a new phone number object with INTERNAL attribute.
 IName createName(String firstname, String lastname)
          Create a new name object with the specific data.
 IName createName(String firstname, String lastname, String additional)
          Create a new name object with the specific data.
 IPhonenumber createPhonenumber(boolean isClired)
          Create a new phone number object with the specific data.
 IPhonenumber createPhonenumber(String telephoneNumber)
          Create a new phone number object with the specific data.
 IPhonenumber createPhonenumber(String intAreaCode, String areaCode, String number)
          Create a new phone number object with the specific data.
 IMultiPhoneCaller toMultiPhoneCaller(ICaller caller)
          Transforms a ICaller objects to a IMultiPhoneCaller object.
 

Method Detail

createCaller

ICaller createCaller(String uuid,
                     IName name,
                     IPhonenumber phone,
                     IAttributeMap attributes)
Create a new caller object with the specific data.

Parameters:
uuid - UUID of the caller
name - name object of the caller
phone - phone number object of the caller
attributes - a attribute list to be set for the caller
Returns:
a new instance of a caller.

createCaller

ICaller createCaller(String uuid,
                     IName name,
                     IPhonenumber phone,
                     IAttribute attribute)
Create a new caller object with the specific data.

Parameters:
uuid - UUID of the caller
name - name object of the caller
phone - phone number object of the caller
attribute - a attribute to be set for the caller
Returns:
a new instance of a caller.

createCaller

ICaller createCaller(String uuid,
                     IName name,
                     IPhonenumber phone)
Create a new caller object with the specific data.

Parameters:
uuid - UUID of the caller
name - name object of the caller
phone - phone number object of the caller
Returns:
a new instance of a caller.

createCaller

ICaller createCaller(IName name,
                     IPhonenumber phone,
                     IAttributeMap attributes)
Create a new caller object with the specific data.

Parameters:
name - name object of the caller
phone - phone number object of the caller
attributes - a attribute list to be set for the caller
Returns:
a new instance of a caller.

createCaller

ICaller createCaller(IName name,
                     IPhonenumber phone,
                     IAttribute attribute)
Create a new caller object with the specific data.

Parameters:
name - name object of the caller
phone - phone number object of the caller
attribute - a attribute to be set for the caller
Returns:
a new instance of a caller.

createCaller

ICaller createCaller(IPhonenumber phone)
Create a new caller object with the specific data.

Parameters:
phone - phone number object of the caller
Returns:
a new instance of a caller.

createCaller

ICaller createCaller(IName name,
                     IPhonenumber phone)
Create a new caller object with the specific data.

Parameters:
name - name object of the caller
phone - phone number object of the caller
Returns:
a new instance of a caller.

createName

IName createName(String firstname,
                 String lastname,
                 String additional)
Create a new name object with the specific data.

Parameters:
firstname - firstname of the name object
lastname - lastname of the name object
additional - additional information of the name object
Returns:
a new instance of a name object.

createName

IName createName(String firstname,
                 String lastname)
Create a new name object with the specific data.

Parameters:
firstname - firstname of the name object
lastname - lastname of the name object
Returns:
a new instance of a name object.

createPhonenumber

IPhonenumber createPhonenumber(String intAreaCode,
                               String areaCode,
                               String number)
Create a new phone number object with the specific data.

Parameters:
intAreaCode - international area code of the phone number object
areaCode - local area code of the phone number object
number - call number of the phone number object
Returns:
a new instance of a phone number object.

createPhonenumber

IPhonenumber createPhonenumber(String telephoneNumber)
Create a new phone number object with the specific data.

Parameters:
telephoneNumber - complete telephonenumber of the phone number object
Returns:
a new instance of a phone number object.

createPhonenumber

IPhonenumber createPhonenumber(boolean isClired)
Create a new phone number object with the specific data.

Parameters:
isClired - true if the phone object should be clired (CLIR).
Returns:
a new instance of a phone number object.

createClirPhonenumber

IPhonenumber createClirPhonenumber()
Create a new phone number object with CLIR attribute.

Returns:
a new instance of a CLIR phone number object.

createInternalPhonenumber

IPhonenumber createInternalPhonenumber(String internalNumber)
Create a new phone number object with INTERNAL attribute.

Returns:
a new instance of a INTERNAL phone number object.

createAttribute

IAttribute createAttribute(String name,
                           String value)
Create an attribute with the specific data.

Parameters:
name - name of the attribute.
value - value of the attribute.
Returns:
a new instance of an attribute.

createAttributeList

IAttributeMap createAttributeList()
Deprecated. 

Create an empty attribute list.

Returns:
a new instance of an attribute list.

createAttributeMap

IAttributeMap createAttributeMap()
Create an empty attribute map.

Returns:
a new instance of an attribute map.

createCallerList

ICallerList createCallerList()
Create an empty caller list. Initial capacity is set to 1.

Returns:
a new instance of an caller list.

createCallerList

ICallerList createCallerList(int capacity)
Create an empty caller list with an initial capacity.

Returns:
a new instance of an caller list.

createCaller

IMultiPhoneCaller createCaller(String uuid,
                               IName name,
                               List phones,
                               IAttributeMap attributes)
Create a new multi phone caller object with the specific data.

Parameters:
uuid - UUID of the caller
name - name object of the caller
phones - a list of phone number objects of the caller
attributes - a attribute list to be set for the caller
Returns:
a new instance of a caller.

createCaller

IMultiPhoneCaller createCaller(IName name,
                               List phones,
                               IAttributeMap attributes)
Create a new caller object with the specific data.

Parameters:
name - name object of the caller
phones - a list of phone number objects of the caller
attributes - a attribute list to be set for the caller
Returns:
a new instance of a caller.

createCaller

IMultiPhoneCaller createCaller(IName name,
                               List phones)
Create a new caller object with the specific data.

Parameters:
name - name object of the caller
phones - a list of phone number objects of the caller
Returns:
a new instance of a caller.

toMultiPhoneCaller

IMultiPhoneCaller toMultiPhoneCaller(ICaller caller)
Transforms a ICaller objects to a IMultiPhoneCaller object. The new IMultiPhoneCaller object gets a new UUID (!).

Parameters:
caller - caller to be transformed
Returns:
a new IMultiPhoneCaller instance


Copyright © 2010 by Thilo Brandt. All Rights Reserved.