Class BaseDialogTcapMessage
- java.lang.Object
-
- com.opencloud.sentinel.ipsmgw.eventmanager.tcapmessage.BaseDialogTcapMessage
-
- All Implemented Interfaces:
DialogTcapMessage
,com.opencloud.util.FastSerializable
,java.io.Serializable
- Direct Known Subclasses:
DialogMessageTcapMessage
,DialogOpenRefuseTcapMessage
,DialogProviderAbortTcapMessage
,DialogUserAbortTcapMessage
public abstract class BaseDialogTcapMessage extends java.lang.Object implements DialogTcapMessage, java.io.Serializable, com.opencloud.util.FastSerializable
Base class for all classes that represent a message received on a tcap dialog- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
BaseDialogTcapMessage.MessageType
-
Nested classes/interfaces inherited from interface com.opencloud.sentinel.ipsmgw.eventmanager.tcapmessage.DialogTcapMessage
DialogTcapMessage.Type
-
-
Field Summary
Fields Modifier and Type Field Description protected static TcapComponent[]
NO_COMPONENTS
-
Constructor Summary
Constructors Constructor Description BaseDialogTcapMessage(BaseDialogTcapMessage toCopy)
BaseDialogTcapMessage(BaseDialogTcapMessage.MessageType messageType, DialogTcapMessage.Type type)
BaseDialogTcapMessage(BaseDialogTcapMessage.MessageType messageType, DialogTcapMessage.Type type, java.lang.Object[] userInformation)
BaseDialogTcapMessage(java.io.DataInput ip)
-
Method Summary
-
-
-
Field Detail
-
NO_COMPONENTS
protected static final TcapComponent[] NO_COMPONENTS
-
-
Constructor Detail
-
BaseDialogTcapMessage
public BaseDialogTcapMessage(java.io.DataInput ip) throws java.io.IOException
- Throws:
java.io.IOException
-
BaseDialogTcapMessage
public BaseDialogTcapMessage(BaseDialogTcapMessage.MessageType messageType, DialogTcapMessage.Type type)
-
BaseDialogTcapMessage
public BaseDialogTcapMessage(BaseDialogTcapMessage.MessageType messageType, DialogTcapMessage.Type type, java.lang.Object[] userInformation)
-
BaseDialogTcapMessage
public BaseDialogTcapMessage(BaseDialogTcapMessage toCopy)
-
-
Method Detail
-
toStream
public void toStream(java.io.DataOutput op) throws java.io.IOException
- Specified by:
toStream
in interfacecom.opencloud.util.FastSerializable
- Throws:
java.io.IOException
-
hasComponents
public boolean hasComponents()
- Specified by:
hasComponents
in interfaceDialogTcapMessage
- Returns:
- true if this message has some associated components
-
getComponents
public TcapComponent[] getComponents()
- Specified by:
getComponents
in interfaceDialogTcapMessage
- Returns:
- the components associated with this message
-
getUserInformation
public final java.lang.Object[] getUserInformation()
-
setUserInformation
public final void setUserInformation(java.lang.Object[] userInformation)
-
getType
public final DialogTcapMessage.Type getType()
- Specified by:
getType
in interfaceDialogTcapMessage
- Returns:
- the type of this tcap dialog message
-
isType
public final boolean isType(DialogTcapMessage.Type toCheck)
- Specified by:
isType
in interfaceDialogTcapMessage
- Parameters:
toCheck
- the type to compare the type of this tcap message to- Returns:
- true, if the type if this tcap message is the compatible
toCheck
-
asDialogOpenRequest
public final DialogOpenRequestTcapMessage asDialogOpenRequest()
- Specified by:
asDialogOpenRequest
in interfaceDialogTcapMessage
- Returns:
- this message as an open request
-
asDialogOpenAccept
public final DialogMessageTcapMessage asDialogOpenAccept()
- Specified by:
asDialogOpenAccept
in interfaceDialogTcapMessage
- Returns:
- this message as an open accept
-
asDialogOpenRefuse
public final DialogOpenRefuseTcapMessage asDialogOpenRefuse()
- Specified by:
asDialogOpenRefuse
in interfaceDialogTcapMessage
- Returns:
- this message as an open refuse
-
asDialogUserAbort
public final DialogUserAbortTcapMessage asDialogUserAbort()
- Specified by:
asDialogUserAbort
in interfaceDialogTcapMessage
- Returns:
- this message as a dialog user abort
-
asDialogProviderAbort
public final DialogProviderAbortTcapMessage asDialogProviderAbort()
- Specified by:
asDialogProviderAbort
in interfaceDialogTcapMessage
- Returns:
- this message as a dialog provider abort
-
asDialogMessage
public final DialogMessageTcapMessage asDialogMessage()
- Specified by:
asDialogMessage
in interfaceDialogTcapMessage
- Returns:
- this message as a dialog message
-
isTcBegin
public final boolean isTcBegin()
- Specified by:
isTcBegin
in interfaceDialogTcapMessage
- Returns:
- true is this message is a TC-Begin
-
isTcContinue
public final boolean isTcContinue()
- Specified by:
isTcContinue
in interfaceDialogTcapMessage
- Returns:
- true is this message is a TC-Continue
-
isTcEnd
public final boolean isTcEnd()
- Specified by:
isTcEnd
in interfaceDialogTcapMessage
- Returns:
- true is this message is a TC-End
-
asTcContinue
public final void asTcContinue()
Description copied from interface:DialogTcapMessage
change this message to be a TC-Continue, if possible.- Specified by:
asTcContinue
in interfaceDialogTcapMessage
-
asTcEnd
public final void asTcEnd()
Description copied from interface:DialogTcapMessage
change this message to be a TC-End(prearranged = false), if possible.- Specified by:
asTcEnd
in interfaceDialogTcapMessage
-
asTcEnd
public final void asTcEnd(boolean prearranged)
Description copied from interface:DialogTcapMessage
change this message to be a TC-End(prearranged), if possible.- Specified by:
asTcEnd
in interfaceDialogTcapMessage
-
isPrearrangedEnd
public final boolean isPrearrangedEnd()
- Specified by:
isPrearrangedEnd
in interfaceDialogTcapMessage
- Returns:
- true if the prearranged flag is true
-
getMessageType
protected final BaseDialogTcapMessage.MessageType getMessageType()
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-