org.mobicents.servlet.sip.message
Class B2buaHelperImpl

java.lang.Object
  extended by org.mobicents.servlet.sip.message.B2buaHelperImpl
All Implemented Interfaces:
java.io.Serializable, B2buaHelper

public class B2buaHelperImpl
extends java.lang.Object
implements B2buaHelper, java.io.Serializable

Implementation of the B2BUA helper class.

Author:
mranga, Jean Deruelle
See Also:
Serialized Form

Field Summary
protected static java.util.Set<java.lang.String> B2BUA_SYSTEM_HEADERS
           
protected static java.util.Set<java.lang.String> CONTACT_FORBIDDEN_PARAMETER
           
 
Constructor Summary
B2buaHelperImpl()
           
 
Method Summary
 SipServletRequest createCancel(SipSession session)
          
 SipServletRequest createRequest(SipServletRequest origRequest)
          
 SipServletRequest createRequest(SipServletRequest origRequest, boolean linked, java.util.Map<java.lang.String,java.util.List<java.lang.String>> headerMap)
           
 SipServletRequest createRequest(SipSession session, SipServletRequest origRequest, java.util.Map<java.lang.String,java.util.List<java.lang.String>> headerMap)
           
 SipServletResponse createResponseToOriginalRequest(SipSession session, int status, java.lang.String reasonPhrase)
           
 SipSession getLinkedSession(SipSession session)
           
 SipServletRequest getLinkedSipServletRequest(SipServletRequest req)
           
 java.util.List<SipServletMessage> getPendingMessages(SipSession session, UAMode mode)
           
 java.util.Map<SipSessionKey,SipSessionKey> getSessionMap()
           
 SipFactoryImpl getSipFactoryImpl()
           
 SipManager getSipManager()
           
 void linkSipSessions(SipSession session1, SipSession session2)
           
 void setSessionMap(java.util.Map<SipSessionKey,SipSessionKey> sessionMap)
           
 void setSipFactoryImpl(SipFactoryImpl sipFactoryImpl)
           
 void setSipManager(SipManager sipManager)
           
 void unlinkSipSessions(SipSession session)
           
 void unlinkSipSessionsInternal(SipSession session, boolean checkSession)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

B2BUA_SYSTEM_HEADERS

protected static final java.util.Set<java.lang.String> B2BUA_SYSTEM_HEADERS

CONTACT_FORBIDDEN_PARAMETER

protected static final java.util.Set<java.lang.String> CONTACT_FORBIDDEN_PARAMETER
Constructor Detail

B2buaHelperImpl

public B2buaHelperImpl()
Method Detail

createRequest

public SipServletRequest createRequest(SipServletRequest origRequest,
                                       boolean linked,
                                       java.util.Map<java.lang.String,java.util.List<java.lang.String>> headerMap)
                                throws TooManyHopsException
Specified by:
createRequest in interface B2buaHelper
Throws:
TooManyHopsException

createRequest

public SipServletRequest createRequest(SipSession session,
                                       SipServletRequest origRequest,
                                       java.util.Map<java.lang.String,java.util.List<java.lang.String>> headerMap)
Specified by:
createRequest in interface B2buaHelper

createResponseToOriginalRequest

public SipServletResponse createResponseToOriginalRequest(SipSession session,
                                                          int status,
                                                          java.lang.String reasonPhrase)
Specified by:
createResponseToOriginalRequest in interface B2buaHelper

getLinkedSession

public SipSession getLinkedSession(SipSession session)
Specified by:
getLinkedSession in interface B2buaHelper

getLinkedSipServletRequest

public SipServletRequest getLinkedSipServletRequest(SipServletRequest req)
Specified by:
getLinkedSipServletRequest in interface B2buaHelper

getPendingMessages

public java.util.List<SipServletMessage> getPendingMessages(SipSession session,
                                                            UAMode mode)
Specified by:
getPendingMessages in interface B2buaHelper

linkSipSessions

public void linkSipSessions(SipSession session1,
                            SipSession session2)
Specified by:
linkSipSessions in interface B2buaHelper

unlinkSipSessions

public void unlinkSipSessions(SipSession session)
Specified by:
unlinkSipSessions in interface B2buaHelper

unlinkSipSessionsInternal

public void unlinkSipSessionsInternal(SipSession session,
                                      boolean checkSession)

createRequest

public SipServletRequest createRequest(SipServletRequest origRequest)

Specified by:
createRequest in interface B2buaHelper

createCancel

public SipServletRequest createCancel(SipSession session)

Specified by:
createCancel in interface B2buaHelper

getSipFactoryImpl

public SipFactoryImpl getSipFactoryImpl()
Returns:
the sipFactoryImpl

setSipFactoryImpl

public void setSipFactoryImpl(SipFactoryImpl sipFactoryImpl)
Parameters:
sipFactoryImpl - the sipFactoryImpl to set

getSipManager

public SipManager getSipManager()
Returns:
the sipManager

setSipManager

public void setSipManager(SipManager sipManager)
Parameters:
sipManager - the sipManager to set

setSessionMap

public void setSessionMap(java.util.Map<SipSessionKey,SipSessionKey> sessionMap)
Parameters:
sessionMap - the sessionMap to set

getSessionMap

public java.util.Map<SipSessionKey,SipSessionKey> getSessionMap()
Returns:
the sessionMap


Copyright © 2010. All Rights Reserved.