MGCP_Templates: More templates (for the MGW side)
diff --git a/library/MGCP_Templates.ttcn b/library/MGCP_Templates.ttcn
index 8b9aae9..1dacf3a 100644
--- a/library/MGCP_Templates.ttcn
+++ b/library/MGCP_Templates.ttcn
@@ -64,6 +64,12 @@
sdp := sdp
}
+ template MgcpCommand tr_CRCX := {
+ line := t_MgcpCmdLine("CRCX", ?, ?),
+ params := *,
+ sdp := *
+ }
+
template MgcpResponse tr_CRCX_ACK := {
line := {
code := "200",
@@ -74,6 +80,16 @@
sdp := ?
}
+ template MgcpResponse ts_CRCX_ACK(MgcpTransId trans_id, MgcpConnectionId conn_id, template SDP_Message sdp := omit) := {
+ line := {
+ code := "200",
+ trans_id := trans_id,
+ string := "OK"
+ },
+ params:= { ts_MgcpParConnectionId(conn_id) },
+ sdp := sdp
+ }
+
template MgcpCommand ts_MDCX(MgcpTransId trans_id, charstring ep, MgcpConnectionMode mode, MgcpCallId call_id, MgcpConnectionId conn_id, template SDP_Message sdp := omit) := {
line := t_MgcpCmdLine("MDCX", trans_id, ep),
params := {
@@ -86,6 +102,14 @@
sdp := sdp
}
+ template MgcpCommand tr_MDCX := {
+ line := t_MgcpCmdLine("MDCX", ?, ?),
+ params := *,
+ sdp := *
+ }
+
+ template MgcpResponse ts_MDCX_ACK(MgcpTransId trans_id, MgcpConnectionId conn_id, template SDP_Message sdp := omit) := ts_CRCX_ACK(trans_id, conn_id, sdp);
+
/* have a function that generates a template, rather than a template in order to handle
* optional parameters */
function ts_DLCX(MgcpTransId trans_id, charstring ep, template MgcpCallId call_id := omit,
@@ -103,6 +127,12 @@
return cmd;
}
+ template MgcpCommand tr_DLCX := {
+ line := t_MgcpCmdLine("DLCX", ?, ?),
+ params := *,
+ sdp := *
+ }
+
template MgcpResponse tr_DLCX_ACK := {
line := {
code := "200",
@@ -113,6 +143,8 @@
sdp := *
}
+ template MgcpResponse ts_DLCX_ACK(MgcpTransId trans_id, MgcpConnectionId conn_id, template SDP_Message sdp := omit) := ts_CRCX_ACK(trans_id, conn_id, sdp);
+
/* SDP Templates */
template SDP_Origin ts_SDP_origin(charstring addr, charstring session_id,
charstring session_version := "1",