Sofaswitch-svn
Threads by month
- ----- 2026 -----
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
November 2006
- 1 participants
- 63 discussions
Author: derek
Date: Thu Nov 9 21:43:13 2006
New Revision: 167
Modified:
sofaswitch/trunk/callflow/docs/executionflow.dxy
Log:
Add description on using the CallFlow utility.
Modified: sofaswitch/trunk/callflow/docs/executionflow.dxy
==============================================================================
--- sofaswitch/trunk/callflow/docs/executionflow.dxy (original)
+++ sofaswitch/trunk/callflow/docs/executionflow.dxy Thu Nov 9 21:43:13 2006
@@ -74,7 +74,16 @@
Note that network events, timer events, other events, are only processed when
execution has stopped.
+\section secUsage Usage - selection cutting pasting etc
+You are going to create a new graph, or edit an existing graph. This is done
+by selecting New from the menu, or loading an existing file.
+
+Individual items in the graph can be moved by left down on the item and
+dragging to the desired position. To select and move multiple items, hold the
+shift key down and select the desired items, and then drag. Alternatively,
+select a region on the screen (left down, move to the opposite corner, left
+up), shift button down, and drag.
1
0
Author: derek
Date: Thu Nov 9 20:08:37 2006
New Revision: 166
Modified:
sofaswitch/trunk/callflow/bitmaps/Python.xpm
Log:
Fix python logo to be standard.
Modified: sofaswitch/trunk/callflow/bitmaps/Python.xpm
==============================================================================
--- sofaswitch/trunk/callflow/bitmaps/Python.xpm (original)
+++ sofaswitch/trunk/callflow/bitmaps/Python.xpm Thu Nov 9 20:08:37 2006
@@ -1,21 +1,393 @@
/* XPM */
static char *Python_xpm[]={
-"16 15 3 1",
-". c None",
-"# c #ff00ff",
-"a c #ffff00",
-"................",
-".....#aa........",
-".....#a####aa...",
-".....##a...#aa..",
-".....#a.....#a..",
-"....##a.....#a..",
-"....##a.....#a..",
-"....#a#a...#aa..",
-"....#a.####aa...",
-"...#aa..........",
-"...#a...........",
-"...#a...........",
-"...#a...........",
-"..#a............",
-"................"};
+"32 32 358 2",
+"Qt c None",
+"cG c #facc6e",
+".H c #7d9fbb",
+".i c #d9e0e5",
+"#K c #f9d867",
+"cm c #6f99ba",
+"cf c #96b3cc",
+"dJ c #f1e6c7",
+"ds c #f6e0a5",
+"#L c #a0bcd2",
+"ad c #f1e5c6",
+"dC c #f5e8c8",
+"b4 c #6191b8",
+"dI c #f5d794",
+"dD c #f7d37d",
+"dH c #fac148",
+"dE c #fac248",
+"dF c #fcc038",
+"dG c #ffbe31",
+"#r c #81a9cb",
+".# c #c3d1de",
+"cQ c #fbc03a",
+"#h c #3b80ba",
+"#2 c #7ca9cc",
+"di c #f7ce75",
+"#b c #376e9c",
+"#q c #386c96",
+".3 c #39709c",
+"#n c #3976ab",
+"#m c #3978ad",
+"#l c #3979af",
+"#k c #397bb1",
+"#j c #3a7cb5",
+"#i c #3a7db6",
+".e c #457fb2",
+".d c #4580b3",
+".c c #4884b6",
+".f c #5185b1",
+".T c #5e89ac",
+".b c #6394bd",
+".g c #6e97b9",
+".a c #97b5cf",
+".h c #b6c8d6",
+"da c #fbbf34",
+"cX c #fbc038",
+"c4 c #febc2b",
+"dB c #f7d48c",
+"dr c #f8c762",
+"cF c #f7c866",
+"cl c #f7d17f",
+"dt c #f7d980",
+".j c #93b4ce",
+"cP c #fdc235",
+"cO c #ffc532",
+"cN c #ffcb3b",
+"cM c #ffcc3b",
+".G c #4576a6",
+".t c #6992b5",
+"#1 c #f6d979",
+"b3 c #f2e5c5",
+"db c #f7dc84",
+"#J c #f9dd63",
+"#c c #387fba",
+".4 c #3881bd",
+".U c #3c83bd",
+".I c #4787bb",
+"as c #f2e0af",
+"aE c #f6d16a",
+"bN c #f7c85e",
+"bB c #fac03a",
+"aR c #fac841",
+"c5 c #fcd74d",
+"b. c #fdc536",
+"bn c #ffc532",
+"cY c #ffde50",
+"cR c #ffe354",
+"cH c #ffe457",
+"cn c #92b0c9",
+"dj c #f9d55c",
+"cr c #feea67",
+"cg c #6b97bb",
+"dA c #f9c766",
+"cq c #497da9",
+".k c #5d96c3",
+"#M c #7aa7cb",
+"#s c #98b8d3",
+"bO c #a8c0d5",
+"du c #f8da86",
+"aS c #3880bb",
+"aF c #4183bb",
+"cp c #4278a6",
+"bo c #4786b8",
+"co c #4d81ae",
+"at c #5992c0",
+"bC c #6998c0",
+"ae c #8eb2cf",
+"ce c #f8c559",
+"cE c #f9c349",
+"cD c #fbbf35",
+"cC c #fbbf36",
+"cB c #fbc238",
+"cA c #fbc73e",
+"cz c #fbc73f",
+"cy c #fbc83f",
+"cx c #fbc840",
+"cw c #fbcd46",
+"cv c #fbce47",
+"ac c #fad153",
+"cL c #fbd152",
+"dq c #fbc04b",
+"cu c #fcd34a",
+"dh c #fac048",
+".F c #3e77a6",
+".u c #5491c2",
+"b2 c #fcc345",
+"dc c #fcd651",
+"aH c #366b96",
+"#p c #366c99",
+"#C c #366c9a",
+"aj c #366d9b",
+"#a c #366d9c",
+"#B c #366e9d",
+"av c #366e9e",
+".1 c #366f9f",
+"#U c #3670a0",
+"#D c #376a94",
+"#V c #376b97",
+".2 c #376f9d",
+"#9 c #3771a2",
+"#A c #3772a3",
+"## c #3772a4",
+"#g c #3773a4",
+".R c #3773a5",
+".E c #3773a6",
+".0 c #3774a7",
+".D c #3774a8",
+"#8 c #3774a9",
+"#. c #3775a8",
+"aG c #3775a9",
+"bQ c #3775aa",
+"#f c #3776aa",
+".C c #3776ab",
+".Q c #3777ac",
+".9 c #3777ad",
+".B c #3778ad",
+".P c #3778ae",
+"ai c #3779ae",
+".O c #3779af",
+"b# c #3779b0",
+"ah c #377ab0",
+"#T c #377ab1",
+".Z c #377ab2",
+"#e c #377ab3",
+"aT c #377bb3",
+"#z c #387ab1",
+".A c #387ab2",
+"#7 c #387bb2",
+".N c #387bb3",
+".z c #387bb4",
+"#6 c #387bb5",
+"#y c #387cb4",
+".y c #387cb5",
+"#S c #387cb6",
+"ag c #387db6",
+"#d c #387db7",
+"#x c #387eb7",
+"au c #387eb8",
+"#5 c #387eb9",
+"#R c #387fba",
+"#Q c #3880bb",
+"#P c #3881bc",
+"#w c #3881bd",
+"#v c #3882be",
+"#O c #3883bf",
+"af c #3884c1",
+"#4 c #3884c2",
+"aI c #396c95",
+"bP c #397bb4",
+".5 c #3981bd",
+"aU c #3a78ab",
+"ak c #3b6d96",
+"ba c #3c79ab",
+".p c #3c7bb0",
+"bp c #3c7cb0",
+"#u c #3c83bc",
+".o c #3d7db3",
+".n c #3f7fb5",
+".x c #3f82bb",
+".v c #3f85bd",
+".J c #3f85be",
+".V c #4086c0",
+"ch c #417dae",
+".q c #427dad",
+"#N c #4489c2",
+".w c #4789c0",
+".S c #487da8",
+"#3 c #498cc2",
+".m c #4b89bc",
+"#o c #4f83ae",
+".r c #4f84b0",
+".8 c #4f8ab9",
+"b5 c #5087b4",
+"#t c #558fbf",
+".6 c #5693c4",
+"bD c #588cb7",
+"aJ c #5982a4",
+"aw c #638aab",
+"aV c #6391b6",
+".l c #6399c5",
+"bR c #6996bd",
+"b6 c #6a95ba",
+".s c #709bbe",
+"aW c #83a6c3",
+"a0 c #8aa6bd",
+"aZ c #8aa7c0",
+"aY c #8aa8c1",
+"aX c #8aaac5",
+".7 c #8bb2d3",
+".K c #90b8d9",
+"a1 c #95aab5",
+"bq c #9db7c5",
+"bb c #9eb6c8",
+".M c #9ebed9",
+".W c #b5cfe5",
+"aK c #b9c3bd",
+"#E c #bccad6",
+"al c #c0cacc",
+".Y c #c0d5e6",
+"bE c #d7d4a7",
+"a2 c #d9d1a6",
+"ax c #dccf9a",
+"bc c #ddd597",
+".L c #eff3fb",
+"bd c #f4e786",
+"br c #f5e47c",
+"bS c #f6e99e",
+"dz c #f7c968",
+"dv c #f9cd5f",
+"a3 c #f9dc75",
+"aL c #f9dd6d",
+"b7 c #f9efa2",
+"bh c #fae67e",
+"bg c #fae781",
+"bf c #faea84",
+"be c #faed87",
+"dy c #fbbb36",
+"dw c #fbc13b",
+"dk c #fbd156",
+"bi c #fbe073",
+"ck c #fcba32",
+"dx c #fcc031",
+"ar c #fcd556",
+"#I c #fce35d",
+"d# c #fdb929",
+"bM c #fdbe33",
+"cW c #fdbf30",
+"aD c #fdd048",
+"bj c #fdd954",
+"#0 c #fdda51",
+"bF c #fdeb66",
+"c3 c #febb28",
+"dg c #febf42",
+"bA c #fec231",
+"a9 c #fec737",
+"aQ c #fecb3c",
+"dl c #fecc3c",
+"a4 c #fed84a",
+"bT c #feeb5f",
+"do c #ffb521",
+"dp c #ffb525",
+"dn c #ffb926",
+"cd c #ffba27",
+"cc c #ffbc29",
+"b1 c #ffbc2a",
+"cb c #ffbd2a",
+"cV c #ffbe2c",
+"dd c #ffc033",
+"bL c #ffc12f",
+"ca c #ffc230",
+"cj c #ffc330",
+"c2 c #ffc343",
+"b0 c #ffc431",
+"bm c #ffc532",
+"bl c #ffc533",
+"c# c #ffc634",
+"cU c #ffc735",
+"cZ c #ffc73a",
+"bK c #ffc836",
+"dm c #ffc837",
+"a8 c #ffc938",
+"c8 c #ffc943",
+"bk c #ffca38",
+"c. c #ffca3a",
+"bZ c #ffcb3a",
+"bJ c #ffcb3b",
+"a7 c #ffcc3b",
+"bY c #ffcc3c",
+"aP c #ffcd3c",
+"a6 c #ffce3e",
+"bz c #ffcf3f",
+"bX c #ffcf40",
+"aO c #ffd141",
+"c7 c #ffd142",
+"aC c #ffd242",
+"d. c #ffd278",
+"a5 c #ffd343",
+"aN c #ffd443",
+"bW c #ffd444",
+"aB c #ffd544",
+"cK c #ffd545",
+"aq c #ffd646",
+"aM c #ffd647",
+"aA c #ffd747",
+"c6 c #ffd748",
+"ap c #ffd849",
+"ci c #ffd94a",
+"ab c #ffda4b",
+"ao c #ffda4c",
+"aa c #ffdb4c",
+"az c #ffdb4d",
+"by c #ffdc4d",
+"ay c #ffdc4e",
+"de c #ffdc95",
+"cT c #ffdd4e",
+"an c #ffdd4f",
+"bI c #ffdd50",
+"c0 c #ffdd90",
+"b9 c #ffde4f",
+"bV c #ffde50",
+"bx c #ffdf51",
+"cJ c #ffe051",
+"b8 c #ffe052",
+"bw c #ffe053",
+"#Z c #ffe152",
+"am c #ffe153",
+"cS c #ffe253",
+"a# c #ffe254",
+"ct c #ffe255",
+"#Y c #ffe354",
+"a. c #ffe355",
+"bU c #ffe356",
+"cI c #ffe357",
+"c1 c #ffe3a6",
+"bH c #ffe456",
+"bv c #ffe458",
+"#H c #ffe557",
+"#X c #ffe558",
+"bu c #ffe659",
+"bG c #ffe65a",
+"df c #ffe6b5",
+"#W c #ffe85b",
+"#G c #ffe85c",
+"cs c #ffe95c",
+"bt c #ffeb5e",
+"#F c #ffec5f",
+"bs c #ffed60",
+"c9 c #fffbf2",
+".X c #ffffff",
+"QtQtQtQtQtQtQtQtQtQtQt.#.a.b.c.d.e.e.f.g.h.iQtQtQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtQt.j.k.l.m.n.o.p.p.q.r.s.tQtQtQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQt.j.u.v.w.x.y.z.A.B.C.D.E.F.G.HQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQt.I.J.K.L.M.N.O.P.B.Q.R.R.R.S.TQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQt.U.V.W.X.Y.Z.O.C.C.0.R.R.1.2.3QtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQt.4.5.6.7.8.O.O.9#..R##.1#a#a#bQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQt#c#d.y#e.O.P.9#f.R#g.1#a#a#a#bQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQt#h#i#j#k#l#m#n#o.R###a#a#a#p#qQtQtQtQtQtQtQtQt",
+"QtQtQt#r#s#t#u#v#w#x#y#z.O.O.B.0.R#A#B#a#C#D#D#E#F#G#H#I#J#KQtQt",
+"QtQt#L#M#N#O#P#Q#R#S#T.O.9.Q#..R.R#U#a#a#V#D#D#E#W#X#Y#Z#0#1QtQt",
+"QtQt#2#3#4#v#R#5#S#6#7.P.C#8.R.R#9#a#a#p#D#D#D#Ea.a##ZaaabacadQt",
+"QtQtaeaf#v#v#Pag.zahai.B.B.R.R#9#a#aaj#D#D#DakalamanaoapaqarasQt",
+"QtQtat#O#P#Qau.y.zah.Q.C.D.R.Rav#a#a#V#D#D#DawaxayazaAaBaCaDaEQt",
+"QtQtaF#w#w#R.y.z.O.O.PaG.R#g#U#aajaH#D#DaIaJaKaLabaMaNaOaPaQaRQt",
+"QtQtaS#Qau.yaT.O.O.OaUaVaWaXaYaYaZa0a0a0a1a2a3a4aAa5a6a7a8a9b.Qt",
+"QtQtaS#Q#d.y.zb#.Obabbbcbdbebebebebfbgbhbibjabaqa5a6a7bkblbmbnQt",
+"QtQtbo#d.y.A.O.ObpbqbrbsbsbsbsbtbubvbwbxbyapaBa5bza7bkbmbmbAbBQt",
+"QtQtbC.y.Z.O.B.QbDbEbFbsbsbsbtbGbHa#bIayapaBa5a6bJbKblbmbLbMbNQt",
+"QtQtbObP.Nai.CbQbRbSbTbsbsbtbubUa#bVaaapbWbXbYbZblbmb0bLb1b2b3Qt",
+"QtQtb4b5.O.B.B#.b6b7bsbsbtbua.b8b9aaapaNbza7c.c#bmcacbcccdceQtQt",
+"QtQtcfcgch.CaG.0b6b7#F#WbGa#amayciaAaBbzbYbZc#bmcjcbcccdckclQtQt",
+"QtQtQtcmcncocpcpcqcrcs#XctbxancicucvcwcxcyczcAcBcCcDcDcEcFcGQtQt",
+"QtQtQtQtQtQtQtQtQtcHcI#YcJaacicKcLcMcNcOcOcOcPcQQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtcRcScTazabcKaCbYa7cUbmbmcVcWcXQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtcYanabciaBaObYbZbkcZc0c1c2c3c4QtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtc5a4c6aBc7a6a7cUbmc8c9.Xd.d#daQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtdbdcbWaObYa8c#bmb0dddedfdgdhdiQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtQtdjdkdldmbmbmbLcVdndodpdqdrQtQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtQtdsdtdudvdwdxccccdydzdAdBQtQtQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtQtQtQtdCdDdEdFdGdGdHdIdJQtQtQtQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQt",
+"QtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQt"};
1
0
Author: derek
Date: Thu Nov 9 19:49:35 2006
New Revision: 165
Added:
sofaswitch/trunk/callflow/tests/helloworld.src
Log:
Add the standard "hello world" graph.
Added: sofaswitch/trunk/callflow/tests/helloworld.src
==============================================================================
--- (empty file)
+++ sofaswitch/trunk/callflow/tests/helloworld.src Thu Nov 9 19:49:35 2006
@@ -0,0 +1 @@
+1<B>374<B>36<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>20<B>389<B>126<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>10<B>376<B>79<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "hello world!"<ms><special> <B><Shape>
1
0
Author: derek
Date: Thu Nov 9 19:48:19 2006
New Revision: 164
Added:
sofaswitch/trunk/callflow/docs/helloworld.png (contents, props changed)
Modified:
sofaswitch/trunk/callflow/docs/executionflow.dxy
Log:
Extend docs, add hello world example.
Modified: sofaswitch/trunk/callflow/docs/executionflow.dxy
==============================================================================
--- sofaswitch/trunk/callflow/docs/executionflow.dxy (original)
+++ sofaswitch/trunk/callflow/docs/executionflow.dxy Thu Nov 9 19:48:19 2006
@@ -1,19 +1,55 @@
/*! \page pageExecutionFlow Flow of execution through python code
-\section secOverview Oversight
+\section secIntro Introduction
+We describe the operation of this utilitiy with a series of examples and
+associated description. The first part of this document describes the
+generation of the graph with the gui, and the second part describes the
+running of the graph.
+
+\section secHelloWorld Hello World example
+Perhaps the simplest example of a graph you can create is the standard "Hello
+World" example, shown here.
+
+\image html helloworld.png
+
+Python will start executing at the very top box, process the code in the
+middle, and then terminate at the bottom. Program flow is invariably top to
+bottom. Arrows are drawn on the output and input of each box to indicate where
+the flow is going. You will notice four black circles, filled, on this
+graph. They indicate a connection between the different entitiy. The skull and
+crossbones symbol indicates end this graph now.
+
+\section secForLoop For Loops
+
The flow of execution is to follow the graph on the screen. Thus, when
given a graph like
\image html forloop.png
it will enter the for loop, and go around and around until the termination
-condition is met.
+condition is met. The for loop consists of the three boxes in the middle of
+this image. On each iteration, a Python command is executed, which is defined
+in the Python box in the very middle. You could, of course, put something
+different in the middle of the for loop.
+The loop variable, initialisation and termination condition are set at the
+start of the for loop. To change these, right click on the for loop box and
+adjust accordingly. It will generate an exception if you fail to provide an
+entry to the Initialise, Test or Increment fields. If this Python code is
+incorrect, it will except also. Notice too that the variables all have the
+word "self." as the first half. This ensures that variables in one graph will
+not interfere with those of another graph. If you wrote a nested for loop,
+they should use different variables.
+
While processing each of the nodes in the supplied graph, it is ignoring
all timer events. Execution continues until it falls of the end of the graph,
-or passes through an Eventer type structure and goes nowhere. Consider the
-following graph
+or passes through an Eventer type structure and goes nowhere.
+
+
+\section secEvent Event handling
+We describe the handling of events in this section, with a simple example.
+Consider the following graph
\image html simpleevent.png
Added: sofaswitch/trunk/callflow/docs/helloworld.png
==============================================================================
Binary file. No diff available.
1
0
09 Nov '06
Author: derek
Date: Thu Nov 9 18:02:28 2006
New Revision: 163
Added:
sofaswitch/trunk/callflow/docs.cfg
Removed:
sofaswitch/trunk/callflow/callflow.dxy
Modified:
sofaswitch/trunk/Makefile
sofaswitch/trunk/callflow/Makefile.am
sofaswitch/trunk/callflow/docs/executionflow.dxy
sofaswitch/trunk/callflow/docs/overview.dxy
sofaswitch/trunk/intro.html
sofaswitch/trunk/message.cxx
Log:
Work on improving the current documentation.
Add in links to CallFlow utility, so this is part of SofaSwitch docs.
Modified: sofaswitch/trunk/Makefile
==============================================================================
--- sofaswitch/trunk/Makefile (original)
+++ sofaswitch/trunk/Makefile Thu Nov 9 18:02:28 2006
@@ -29,20 +29,22 @@
all:
- @cd sofa ; make both
- @cd am ; make both
- @cd voip ; make both
- @cd mcu ; make both
- @cd server ; make both
- @cd sound ; make both
+ @cd sofa ; make both
+ @cd am ; make both
+ @cd callflow; make both
+ @cd mcu ; make both
+ @cd server ; make both
+ @cd sound ; make both
+ @cd voip ; make both
all2:
@cd sofa ; make -j 2 both
- @cd am ; make -j 2 both
- @cd voip ; make -j 2 both
- @cd mcu ; make -j 2 both
- @cd server ; make -j 2 both
- @cd sound ; make -j 2 both
+ @cd am ; make -j 2 both
+ @cd callflow; make both
+ @cd mcu ; make -j 2 both
+ @cd server ; make -j 2 both
+ @cd sound ; make -j 2 both
+ @cd voip ; make -j 2 both
@@ -50,18 +52,20 @@
@rm -fR $(HOME)/sofa_docs
@rm -fR html
@doxygen docs.cfg
- @cd am ; doxygen docs.cfg
- @cd mcu ; doxygen docs.cfg
- @cd server ; doxygen docs.cfg
- @cd sound ; doxygen docs.cfg
- @cd sofa ; doxygen docs.cfg
- @cd voip ; doxygen docs.cfg
- @mv am/html html/am
- @mv mcu/html html/mcu
- @mv server/html html/server
- @mv sofa/html html/sofa
- @mv sound/html html/sound
- @mv voip/html html/voip
+ @cd am ; doxygen docs.cfg
+ @cd callflow ; doxygen docs.cfg
+ @cd mcu ; doxygen docs.cfg
+ @cd server ; doxygen docs.cfg
+ @cd sofa ; doxygen docs.cfg
+ @cd sound ; doxygen docs.cfg
+ @cd voip ; doxygen docs.cfg
+ @mv am/html html/am
+ @mv callflow/html html/callflow
+ @mv mcu/html html/mcu
+ @mv server/html html/server
+ @mv sofa/html html/sofa
+ @mv sound/html html/sound
+ @mv voip/html html/voip
@mv html $(HOME)/sofa_docs
Modified: sofaswitch/trunk/callflow/Makefile.am
==============================================================================
--- sofaswitch/trunk/callflow/Makefile.am (original)
+++ sofaswitch/trunk/callflow/Makefile.am Thu Nov 9 18:02:28 2006
@@ -10,7 +10,7 @@
docs:dox
dox:
- doxygen callflow.dxy
+ doxygen docs.cfg
veryclean:distclean
Added: sofaswitch/trunk/callflow/docs.cfg
==============================================================================
--- (empty file)
+++ sofaswitch/trunk/callflow/docs.cfg Thu Nov 9 18:02:28 2006
@@ -0,0 +1,223 @@
+# Doxyfile 1.4.6
+
+#---------------------------------------------------------------------------
+# Project related configuration options
+#---------------------------------------------------------------------------
+PROJECT_NAME = CallFlow
+PROJECT_NUMBER = 1.0.0
+OUTPUT_DIRECTORY =
+CREATE_SUBDIRS = NO
+OUTPUT_LANGUAGE = English
+USE_WINDOWS_ENCODING = NO
+BRIEF_MEMBER_DESC = YES
+REPEAT_BRIEF = YES
+ABBREVIATE_BRIEF =
+ALWAYS_DETAILED_SEC = NO
+INLINE_INHERITED_MEMB = NO
+FULL_PATH_NAMES = YES
+STRIP_FROM_PATH =
+STRIP_FROM_INC_PATH =
+SHORT_NAMES = NO
+JAVADOC_AUTOBRIEF = NO
+MULTILINE_CPP_IS_BRIEF = NO
+DETAILS_AT_TOP = NO
+INHERIT_DOCS = YES
+SEPARATE_MEMBER_PAGES = NO
+TAB_SIZE = 8
+ALIASES =
+OPTIMIZE_OUTPUT_FOR_C = NO
+OPTIMIZE_OUTPUT_JAVA = NO
+BUILTIN_STL_SUPPORT = NO
+DISTRIBUTE_GROUP_DOC = NO
+SUBGROUPING = YES
+#---------------------------------------------------------------------------
+# Build related configuration options
+#---------------------------------------------------------------------------
+EXTRACT_ALL = YES
+EXTRACT_PRIVATE = NO
+EXTRACT_STATIC = NO
+EXTRACT_LOCAL_CLASSES = YES
+EXTRACT_LOCAL_METHODS = NO
+HIDE_UNDOC_MEMBERS = NO
+HIDE_UNDOC_CLASSES = NO
+HIDE_FRIEND_COMPOUNDS = NO
+HIDE_IN_BODY_DOCS = NO
+INTERNAL_DOCS = NO
+CASE_SENSE_NAMES = YES
+HIDE_SCOPE_NAMES = NO
+SHOW_INCLUDE_FILES = YES
+INLINE_INFO = YES
+SORT_MEMBER_DOCS = YES
+SORT_BRIEF_DOCS = NO
+SORT_BY_SCOPE_NAME = NO
+GENERATE_TODOLIST = YES
+GENERATE_TESTLIST = YES
+GENERATE_BUGLIST = YES
+GENERATE_DEPRECATEDLIST= YES
+ENABLED_SECTIONS =
+MAX_INITIALIZER_LINES = 30
+SHOW_USED_FILES = YES
+SHOW_DIRECTORIES = NO
+FILE_VERSION_FILTER =
+#---------------------------------------------------------------------------
+# configuration options related to warning and progress messages
+#---------------------------------------------------------------------------
+QUIET = NO
+WARNINGS = YES
+WARN_IF_UNDOCUMENTED = YES
+WARN_IF_DOC_ERROR = YES
+WARN_NO_PARAMDOC = NO
+WARN_FORMAT = "$file:$line: $text"
+WARN_LOGFILE =
+#---------------------------------------------------------------------------
+# configuration options related to the input files
+#---------------------------------------------------------------------------
+INPUT = src docs .
+FILE_PATTERNS = *.h *.dxy
+RECURSIVE = NO
+EXCLUDE =
+EXCLUDE_SYMLINKS = NO
+EXCLUDE_PATTERNS =
+EXAMPLE_PATH =
+EXAMPLE_PATTERNS =
+EXAMPLE_RECURSIVE = NO
+IMAGE_PATH = src docs
+INPUT_FILTER =
+FILTER_PATTERNS =
+FILTER_SOURCE_FILES = NO
+#---------------------------------------------------------------------------
+# configuration options related to source browsing
+#---------------------------------------------------------------------------
+SOURCE_BROWSER = NO
+INLINE_SOURCES = NO
+STRIP_CODE_COMMENTS = YES
+REFERENCED_BY_RELATION = YES
+REFERENCES_RELATION = YES
+USE_HTAGS = NO
+VERBATIM_HEADERS = YES
+#---------------------------------------------------------------------------
+# configuration options related to the alphabetical class index
+#---------------------------------------------------------------------------
+ALPHABETICAL_INDEX = YES
+COLS_IN_ALPHA_INDEX = 5
+IGNORE_PREFIX =
+#---------------------------------------------------------------------------
+# configuration options related to the HTML output
+#---------------------------------------------------------------------------
+GENERATE_HTML = YES
+HTML_OUTPUT = html
+HTML_FILE_EXTENSION = .html
+HTML_HEADER =
+HTML_FOOTER =
+HTML_STYLESHEET =
+HTML_ALIGN_MEMBERS = YES
+GENERATE_HTMLHELP = NO
+CHM_FILE =
+HHC_LOCATION =
+GENERATE_CHI = NO
+BINARY_TOC = NO
+TOC_EXPAND = NO
+DISABLE_INDEX = NO
+ENUM_VALUES_PER_LINE = 4
+GENERATE_TREEVIEW = NO
+TREEVIEW_WIDTH = 250
+#---------------------------------------------------------------------------
+# configuration options related to the LaTeX output
+#---------------------------------------------------------------------------
+GENERATE_LATEX = NO
+LATEX_OUTPUT = latex
+LATEX_CMD_NAME = latex
+MAKEINDEX_CMD_NAME = makeindex
+COMPACT_LATEX = NO
+PAPER_TYPE = a4wide
+EXTRA_PACKAGES =
+LATEX_HEADER =
+PDF_HYPERLINKS = NO
+USE_PDFLATEX = NO
+LATEX_BATCHMODE = NO
+LATEX_HIDE_INDICES = NO
+#---------------------------------------------------------------------------
+# configuration options related to the RTF output
+#---------------------------------------------------------------------------
+GENERATE_RTF = NO
+RTF_OUTPUT = rtf
+COMPACT_RTF = NO
+RTF_HYPERLINKS = NO
+RTF_STYLESHEET_FILE =
+RTF_EXTENSIONS_FILE =
+#---------------------------------------------------------------------------
+# configuration options related to the man page output
+#---------------------------------------------------------------------------
+GENERATE_MAN = NO
+MAN_OUTPUT = man
+MAN_EXTENSION = .3
+MAN_LINKS = NO
+#---------------------------------------------------------------------------
+# configuration options related to the XML output
+#---------------------------------------------------------------------------
+GENERATE_XML = NO
+XML_OUTPUT = xml
+XML_SCHEMA =
+XML_DTD =
+XML_PROGRAMLISTING = YES
+#---------------------------------------------------------------------------
+# configuration options for the AutoGen Definitions output
+#---------------------------------------------------------------------------
+GENERATE_AUTOGEN_DEF = NO
+#---------------------------------------------------------------------------
+# configuration options related to the Perl module output
+#---------------------------------------------------------------------------
+GENERATE_PERLMOD = NO
+PERLMOD_LATEX = NO
+PERLMOD_PRETTY = YES
+PERLMOD_MAKEVAR_PREFIX =
+#---------------------------------------------------------------------------
+# Configuration options related to the preprocessor
+#---------------------------------------------------------------------------
+ENABLE_PREPROCESSING = YES
+MACRO_EXPANSION = NO
+EXPAND_ONLY_PREDEF = NO
+SEARCH_INCLUDES = YES
+INCLUDE_PATH =
+INCLUDE_FILE_PATTERNS =
+PREDEFINED =
+EXPAND_AS_DEFINED =
+SKIP_FUNCTION_MACROS = YES
+#---------------------------------------------------------------------------
+# Configuration::additions related to external references
+#---------------------------------------------------------------------------
+TAGFILES =
+GENERATE_TAGFILE =
+ALLEXTERNALS = NO
+EXTERNAL_GROUPS = YES
+PERL_PATH = /usr/bin/perl
+#---------------------------------------------------------------------------
+# Configuration options related to the dot tool
+#---------------------------------------------------------------------------
+CLASS_DIAGRAMS = YES
+HIDE_UNDOC_RELATIONS = YES
+HAVE_DOT = YES
+CLASS_GRAPH = YES
+COLLABORATION_GRAPH = YES
+GROUP_GRAPHS = YES
+UML_LOOK = NO
+TEMPLATE_RELATIONS = NO
+INCLUDE_GRAPH = YES
+INCLUDED_BY_GRAPH = YES
+CALL_GRAPH = YES
+GRAPHICAL_HIERARCHY = YES
+DIRECTORY_GRAPH = YES
+DOT_IMAGE_FORMAT = png
+DOT_PATH =
+DOTFILE_DIRS =
+MAX_DOT_GRAPH_WIDTH = 1400
+MAX_DOT_GRAPH_HEIGHT = 1800
+MAX_DOT_GRAPH_DEPTH = 10
+DOT_TRANSPARENT = NO
+DOT_MULTI_TARGETS = NO
+GENERATE_LEGEND = YES
+DOT_CLEANUP = YES
+#---------------------------------------------------------------------------
+# Configuration::additions related to the search engine
+#---------------------------------------------------------------------------
+SEARCHENGINE = NO
Modified: sofaswitch/trunk/callflow/docs/executionflow.dxy
==============================================================================
--- sofaswitch/trunk/callflow/docs/executionflow.dxy (original)
+++ sofaswitch/trunk/callflow/docs/executionflow.dxy Thu Nov 9 18:02:28 2006
@@ -7,7 +7,7 @@
\image html forloop.png
-it will enter the forloop, and go around and around until the termination
+it will enter the for loop, and go around and around until the termination
condition is met.
While processing each of the nodes in the supplied graph, it is ignoring
Modified: sofaswitch/trunk/callflow/docs/overview.dxy
==============================================================================
--- sofaswitch/trunk/callflow/docs/overview.dxy (original)
+++ sofaswitch/trunk/callflow/docs/overview.dxy Thu Nov 9 18:02:28 2006
@@ -11,11 +11,12 @@
functionality and ease of integrating with exWidgets) and has
been released under the MPL license.
-Last updated 15 September 2006
Copyright (C) 2006 Indranet Technologies Ltd, All right reserved
-\section WhyCallFlow Why do we neeed CallFlow ?
+Author, Derek J Smithies, <derek(a)indranet.co.nz>
+
+\section WhyCallFlow Why do we need CallFlow ?
My (DJS) initial thoughts on the design of SofaSwitch was that there would
be individual entities (server, voip, am etc) all controlled by a custom
script, written in some scripting language. I wrote the entities first, and
@@ -26,18 +27,25 @@
original design. This had the unfortunate outcome of making those scripts
invalid. A second lesson was learnt - python is not very good on
threads. Things like the global interpreter lock started to get in the
-way. python script.
+way. Further, the scripts became a maintainence nightmare. This was
+discouraging.
At this stage, I was uncertain. Should I change to a different (and more
superior) scripting language? Some thought and discussion showed that python
-is the way to go. Choosing an unknonw (but superior?) language like XYZ would
+is the way to go. Choosing an unknown (but superior?) language like XYZ would
indeed solve the above problems, but introduce two new problems: 1)it is now
much harder to get get going in the project and 2)it becomes much harder to
-install sofaswitch. Minor considerations such as, "we might loose
+install SofaSwitch. Minor considerations such as, "we might loose
cross-platform features if we switch to XYZ" were part of the problem space.
+Worse still, by demanding the scripting language is written in Python (or
+Perl, or Lua, or C, etc) I was raising the bar for the system administrator
+before he/she could use SofaSwitch. They were now reqired to learn the
+scripting language and how SofaSwitch works. Everyone understands flowcharts -
+if only there was a scripting language based on flowcharts.
+
Clearly, the way ahead was to write a custom utility to write the python
-controlscripts. Now, we expect that some may wish to write their own python
+control scripts. Now, we expect that some may wish to write their own python
scripts. This is fine - you are welcome to learn from our current
codebase. Given the modular structure of SofaSwitch, this is
inevitable. Different modules will be glued together in different ways.
@@ -48,19 +56,22 @@
\section WhatDo What does CallFlow do ?
In this section, I describe, in overview, what CallFlow does
-\li Draw the diagram of the call handling for one call
+\li Draw the diagram of the particular processing required.
\li Compile this to python, which creates two files. The first file
describes the graph, and the second file describes the handling of
the graph. The second file is "hardwired" to load that particular
graph file. However, the second file is is, essentially, the same between
every compile.
\li You use Python to execute the second file, which loads the graph file.
+\li Multiple threads of execution in the Python control script are handled
+ easily, by loading in graph files. Thus, on detecting an incoming call
+ (for example) a graph file to deal with one incoming voip call is loaded
-
\subsection history History
\li 15 September 2006 - Created by Derek J Smithies
\li 21 September 2006 - Add Why section Derek J Smithies
+\li 10 November 2006 - spelling & textual improvements Derek J Smithies
*/
Modified: sofaswitch/trunk/intro.html
==============================================================================
--- sofaswitch/trunk/intro.html (original)
+++ sofaswitch/trunk/intro.html Thu Nov 9 18:02:28 2006
@@ -18,11 +18,12 @@
<large>
<center>
-<li><a class="el" href="jopal/html/index.html">voip handler</a> </li>
+<li><a class="el" href="voip/html/index.html">voip handler</a> </li>
<li><a class="el" href="mcu/html/index.html">conference utility</a> </li>
<li><a class="el" href="server/html/index.html">message server</a> </li>
<li><a class="el" href="am/html/index.html">answering machine</a> </li>
<li><a class="el" href="sound/html/index.html">sound card utility</a> </li>
+<li><a class="el" href="callflow/html/index.html">GUI to generate control code</a> </li>
</center>
</large>
Modified: sofaswitch/trunk/message.cxx
==============================================================================
--- sofaswitch/trunk/message.cxx (original)
+++ sofaswitch/trunk/message.cxx Thu Nov 9 18:02:28 2006
@@ -2,14 +2,10 @@
\page pageMessageProtocol Message Protocol
-The protocol used for control communications is described here, in the
-following sections. Also described is the relationship between different
-components, which is required for the communications protocol to make any
-"sense".
\li \ref secIntroduction
\li \ref secMessageContents
-\li \ref secSupervisorWorker
+\li \ref secSofaSwitchEntities
\li \ref secCurrentCommands
\li \ref secServerCommands
\li \ref secTransferUdp
@@ -21,29 +17,44 @@
\section secIntroduction Introduction
-Workers and Supervisors are the doers - entities that control voice
-calls. The distinction between them is explained in section
-\ref secSupervisorWorker.
+As stated before, SofaSwitch consists of many different running applications,
+where each different application may run on a different machine and will have
+a different purpose. Consequently, there is a need for a standardised method
+of communication between the applications which will work transparently across
+OS's, hardware types, and network types.
-The method by which one Worker/Supervisor sends messages to another
-Worker/Supervisor is very simple. A text message is composed, sent to
-the server via a TCP socket, which then relays the message on to the
-desired destination. Thus, we have a star network. Every
-Worker/Supervisor has one TCP connection to the server, for
-sending/receiving messages relevant to/from the server.
+The protocol used for control communications is described in this page. Also
+described is the relationship between different components, which is required
+for the communications protocol to make any "sense".
-We are opposed to "micro management". Thus, a Supervisor is not required to
-worry about the details of any one voice circuit. In fact, the only control a
-Supervisor will have over any voice circuit is to create the Worker to handle
-that voice circuit. Note however that the Supervisor will be able to report
-the status of individual workers/voice circuits.
+We describe the syntax for placing the control messages inside TCP
+packets. Some justification is given for the choices made. However, there
+will be some topics that no amount of justification/discussion will be
+convincing enough.
-Similarily, when two Workers have to arrange the transfer of audio
-data between themselves, it is none of the Controller's business. The
-controller should merely say to one worker, "arrange audio transfer
-with that worker". Consequently, the Controller is not aware of what
-port the Worker is using for audio
+A key element in understanding why we chose where communication flows is that
+we are opposed to "micro manaagement". By "micro management", we refer to the
+practice where one part of the software has an excessive interest in the
+minute details of another component in the software. For more details, see
+\htmlonly
+<a href="http://en.wikipedia.org/wiki/Micromanagement">wikipedia-micro management</a>
+\endhtmlonly
+
+To illustrate, the Controlling entity directs two nodes to send audio between
+them. There are two distinct methods for implementing this:
+\li for the Controller to work out what ports are available in the two nodes,
+ and then advise both nodes to which port to send the audio data
+ \li two nodes are told they are talking to each other by the Controller.
+ Then, the two nodes discuss amongst themselves
+ how they communicate (which could be via tcp, bridging, pipes, etc)
+
+The first approach is micro management - the Controller does not need to know
+about ports. Worse, it constrains the two nodes to only talk via network
+ports. The second approach is harder - the nodes are all given some
+"intelligence" and have to be able to respond to a wider range of messages.
+
+
\section secMessageContents The contents of all messages
Control communication is always via text messages on TCP sockets. The last
@@ -56,37 +67,41 @@
Connect to this server. This server will then spawn of a TCPConnection
class to listen for all further communications from switch. Node
switch then sends a zero terminated string of
-
<center>
"switch"0
</center>
+to this server. This string identifies the remote node to this server. On
+receipt of this string, the server can make a unique label for the
+TCPConnection class, and add it to the internal list. Once the TCPConnection
+class has been added to the internal list, full bidirectional comms is now
+possible with node "switch".
-to this server. This string identifies the remote node to this server.
-On receipt of this string, the server can make a unique label for the
-TCPConnection class, and add it to the internal list. Once the
-TCPConnection class has been added to the internal list, full
-bidirectional comms is now possible with node "switch".
+The server assumes all remote nodes will correctly choose a valid unique ID.
+My preference is that the supervisor connects with a label such as
+"controller", "voip", or "am". Workers spawned by that supervisor have a
+number appended to the supervisor's label. Thus, the voip supervisor connects
+as "voip". All workers spawned by the voip supervisor will be called "voip1",
+"voip2", etc. This naming scheme makes debugging somewhat easier, as you can
+identify, from the label, the origin/destination of a message.
+
In some cases, the connecting node has no idea what unique ID to specify. It
-will (in this case) use the string "?" and let the server assign a unique ID.
+will (in this case) use the string "?"0 and let the server assign a unique ID.
The connecting node can then use the command "whoami" to enquire of the server
-to find out what unique ID was assigned.
+to find out what unique ID was assigned. This indentification process is ideal
+for Controllers. You can invoke a script which launches a new Controller to do
+some adjustment, without worrying about "will this script correctly pick a
+unique id?".
-The server assumes all remote nodes will correctly choose a valid
-unique ID. My preference is that the supervisor connects with a
-label such as "controller", "voip", or "am". Workers spawned by
-that supervisor have a number appended to the supervisor's
-label. Thus, the voip supervisor connects as "voip". All workers
-spawned by the voip supervisor will be called "voip1", "voip2",
-etc. This naming scheme makes debugging somewhat easier, as you can
-identify, from the label, the origin/destination of a message.
-
-A message sent to the server has the format
-remoteNode : message
-
+A control message, which is sent via the server has the format
+<center>
+ remoteNode : message
+</center>
The server changes the message, and sends it to the remote node as
+<center>
sourceNode : message
+</center>
Thus, this server has changed the message. This is acceptable, as it
means that the receiving node is able to determine who sent the
@@ -97,41 +112,77 @@
To illustrate, suppose A sends the message "status" to B.
A sends to the sever
-
+<center>
"B:status"0 (string, with a trailing zero byte)
+</center>
the server receives this packet and then sends to B
-
+<center>
"A:status"0 (string, with a trailing zero byte)
+</center>
Note - the quotes are there to illustrate it is a string, and are not
included in the packet.
-\section secSupervisorWorker Supervisor and Worker
-It is important to note that a sofaswitch application will have two distinct endpoints in it.
-The application will have 1 Supervisor and multiple Workers.
+\section secSofaSwitchEntities Entities provided by SofaSwitch
+There are several distinct entities used by SofaSwitch. It is important to
+understand the difference between them, and how the entities interact.
+
<center>
<table width="600">
-<tr><td> Worker </td><td> handles commands associated with one particular voip circuit.
- Thus, for a voice over IP application, there will be X workers
- for the X active voice calls in the voip application.
+<tr><td> Worker </td><td> handles commands associated with one particular audio circuit.
+ In a voip application, which is capable of handling 30 (say) concurrent calls,
+ there will be (at most) 30 active Workers.
</td></tr>
<tr><td> Supervisor</td><td> responsible for establishing (as required) new
- Workers. It can be used to terminate the sofaswitch
- application. Messages which are appropriate for a
- particular Worker are never ever sent via the
- supervisor </td></tr>
-</table>.
+ Workers. It can be used to terminate the SofaSwitch
+ application. Messages which are appropriate for a particular
+ Worker are never ever sent via the Supervisor
+</td></tr>
+<tr><td>Server</td><td> is responsible for passing control messages between
+ different SofaSwitch entities. There is only one instance of
+ a Server in the SofaSwitch network, so all control messages
+ pass through the Server. Thus, the Server knows about every
+ active SofaSwitch entity.
+</td></tr>
+<tr><td>Controller</td><td> is responsible for generating control mesasges to
+ get things to happen. It is this entity who initiates
+ responses from the SofaSwitch system as real world events
+ happen. There may be multiple active Controllers - this is a
+ matter of implementation for the user.
+</td></tr>
+</table>
</center>
-Even the controller can be split up into a Worker/Supervisor
-distinction. The Worker in the controller sends commands appropriate
-to managing one current call. The Supervisor creates Workers to handle
-new calls, as required.
+Even the controller can be split up into a Worker/Supervisor distinction. The
+Worker in the controller sends commands appropriate to managing one current
+call. The Supervisor creates Workers to handle new calls, as required. How the
+Controller is configured/written is entirely up to the user. We have provided
+Python examples, and a graphical editor to generate those Python examples, but
+the user may choose to implement a completely different system.
+
+Workers and Supervisors exist together inside one running application to
+handle voice calls. The Worker is the only entity who "touches" raw audio
+data. Everything else worries about control. The Supervisor is in direct
+contact with 1 (or more) Workers. Thus, the supervisor is responsible for
+Worker creation/initiation/deletion. There are several SofaSwitch
+applications (am, mcu, voip), each of which contain one Supervisor and
+multiple workers. By sending audio between the different workers, we can
+create the functionality of a voice switch.
+
+We have a "star" shaped network, as all control messages go via the
+server. However, this is not strictly true as raw audio will pass directly
+between any two workers. Alternatively, audio is never ever passed through the
+server. This design decision was made so that any extra burst of processing
+required on the server will not slow down/interrupt audio traffic. Further,
+removing audio traffic from the server reduces the load on the server
+considerably.
+
\section secCurrentCommands Worker/Supervisor commands
+
The following commands are provided in this protocol. They are
designed to be sent from a Worker/Supervisor to a
Worker/Supervisor. Most will be sent by Workers, but there is no check
@@ -186,10 +237,9 @@
Some commands are actioned by the server, and not passed on to the
destination node. These commands do not have a destination node
specified. They are therefore of the format:
-
-
+<center>
"command"0
-
+</center>
which contains no colon character, and is terminated by a zero
byte. As before, the quotes are there to illustrate it is a string,
and are not included in the packet.
@@ -209,11 +259,13 @@
are. This command is useful when we are some controller who
has connected to the server and asked the server to generate
a unique Id for us. It is also a debugging tool from the command
- prompt case - we can enquire of the server to check our ID.
+ prompt case - we can enquire of the server to report our ID.
</td></tr>
-<tr><td>adviseontermination remNode</td></td>This commands the server to (on this node
- terminating) send a message to the specified node (remNode). The message
- will advise remNode that this this node has died.
+<tr><td>adviseontermination remNode</td><td>This commands the server to (on
+ this node terminating) send a message to the specified node
+ (remNode). The message will advise remNode that this this
+ node has died. Thus, the controller will get a message if the
+ box running the answer machine (for example) is unplugged.
</td></tr>
</table>
</center>
1
0
Author: derek
Date: Wed Nov 8 23:03:57 2006
New Revision: 162
Modified:
sofaswitch/trunk/mcu/participant.h
Log:
Fix a poorly constructed doxygen comment.
Modified: sofaswitch/trunk/mcu/participant.h
==============================================================================
--- sofaswitch/trunk/mcu/participant.h (original)
+++ sofaswitch/trunk/mcu/participant.h Wed Nov 8 23:03:57 2006
@@ -257,10 +257,15 @@
srcMemberId(this).
Remember, this participant instance is from srcMemberId(this) to
- dstMemberId;
+ dstMemberId. For every current instance of a Participant class, there
+ is on pointing in the reverse direction. So, you have a Participant
+ from srcMemberId to dstMemberId, and another from dstMemberId to
+ srcMemberId.
- This is a one line method, that was not easy to move into this method.
- -that would have meanth including member.h into this file, and having a
+ This is a one line method, that was not easy to move into this class
+ definition file
+
+ -that would have meant including member.h into this file, and having a
weird double reverse include process. Further, we can now nicely put
comment generating code into the body of this method.
*/
1
0
Author: derek
Date: Wed Nov 8 22:51:30 2006
New Revision: 161
Modified:
sofaswitch/trunk/callflow/src/canvas.cpp
sofaswitch/trunk/callflow/src/loadnewgraph.cpp
sofaswitch/trunk/callflow/src/shapelist.cpp
sofaswitch/trunk/callflow/tests/amplaywavfile.src
sofaswitch/trunk/callflow/tests/dtmf_from_sound.src
sofaswitch/trunk/callflow/tests/forloop.src
sofaswitch/trunk/callflow/tests/loadgraph.src
sofaswitch/trunk/callflow/tests/makevoipcall.src
sofaswitch/trunk/callflow/tests/requestnode.src
sofaswitch/trunk/callflow/tests/simpleeventer.src
sofaswitch/trunk/callflow/tests/timetest.src
Log:
Make sure all the tests work.
Loadgraph works correctly - the spawned thread now closes down at the right time.
Modified: sofaswitch/trunk/callflow/src/canvas.cpp
==============================================================================
--- sofaswitch/trunk/callflow/src/canvas.cpp (original)
+++ sofaswitch/trunk/callflow/src/canvas.cpp Wed Nov 8 22:51:30 2006
@@ -18,7 +18,7 @@
#error Clipboard must be enabled for copy and paste to work.
#endif
-#include <wx/textfile.h>
+#include <wx/textfile.h>
#include <wx/tokenzr.h>
#include <wx/tipwin.h>
#include <wx/timer.h>
@@ -27,536 +27,610 @@
#include "canvas.h"
#include "callflow.h"
-BEGIN_EVENT_TABLE(MyCanvas, wxScrolledWindow)
-
- EVT_LEFT_DOWN (MyCanvas::OnLeftDown)
- EVT_LEFT_UP (MyCanvas::OnLeftUp)
- EVT_RIGHT_DOWN (MyCanvas::OnRightDown)
- EVT_MOTION (MyCanvas::OnMouseMove)
- EVT_PAINT (MyCanvas::OnPaint)
- EVT_ENTER_WINDOW(MyCanvas::OnMouseEnter)
- EVT_LEAVE_WINDOW(MyCanvas::OnMouseLeave)
- EVT_CHAR (MyCanvas::OnChar)
- EVT_TIMER (TimerId, MyCanvas::OnProgressTimer)
-
-END_EVENT_TABLE()
-
-MyCanvas::MyCanvas(MyFrame* parent):
- wxScrolledWindow((wxWindow*)parent, -1)
+BEGIN_EVENT_TABLE (MyCanvas, wxScrolledWindow) EVT_LEFT_DOWN (MyCanvas::OnLeftDown) EVT_LEFT_UP (MyCanvas::OnLeftUp) EVT_RIGHT_DOWN (MyCanvas::OnRightDown) EVT_MOTION (MyCanvas::OnMouseMove) EVT_PAINT (MyCanvas::OnPaint) EVT_ENTER_WINDOW (MyCanvas::OnMouseEnter) EVT_LEAVE_WINDOW (MyCanvas::OnMouseLeave) EVT_CHAR (MyCanvas::OnChar) EVT_TIMER (TimerId, MyCanvas::OnProgressTimer) END_EVENT_TABLE ()MyCanvas::MyCanvas (MyFrame * parent):
+wxScrolledWindow ((wxWindow *) parent, -1)
{
- pFrame = parent ;
- SetVirtualSize (1000, 1000); // width, height
- SetScrollRate(20,20); // scroll x and y
- SetBackgroundColour (wxColour (255, 255, 240));
- editingMode = WaitDownEvent;
+ pFrame = parent;
+ SetVirtualSize (1000, 1000); // width, height
+ SetScrollRate (20, 20); // scroll x and y
+ SetBackgroundColour (wxColour (255, 255, 240));
+ editingMode = WaitDownEvent;
- timerActivity = new wxTimer(this, TimerId);
- timerActivity->Start(500);
+ timerActivity = new wxTimer (this, TimerId);
+ timerActivity->Start (500);
}
MyCanvas::~MyCanvas ()
{
- delete timerActivity;
+ delete timerActivity;
}
// Called when window needs to be repainted.
-void MyCanvas::OnPaint(wxPaintEvent& event)
-{
- activeShapes.ClearConnectionPoints();
- activeShapes.MarkConnectionPoints();
-
- wxPaintDC dc(this);
- PrepareDC(dc);
-
- // Find Out where the window is scrolled to
- int vbX,vbY; // Top left corner of client
- GetViewStart(&vbX,&vbY);
- wxRegionIterator upd(GetUpdateRegion()); // get the update rect list
-
- wxRect nrect;
- while (upd) {
- wxRect rect(upd.GetRect());
- wxPoint tl(rect.x, rect.y);
- wxPoint ntl;
- CalcUnscrolledPosition(tl.x, tl.y, &ntl.x, &ntl.y);
- wxSize updateSize(upd.GetWidth(), upd.GetHeight());
- nrect= wxRect(ntl, updateSize);
-
- MyListShapes::iterator it = activeShapes.begin();
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- if (oneShape->Intersects(nrect))
- oneShape->Draw(dc);
- }
- it++;
- }
- upd ++ ;
- }
-
- if (selectingRegion.IsSelected()) {
- selectingRegion.Draw(dc);
- }
-
- if (GetEditingMode() == PlaceJoinBlocks) {
- wxPoint last;
- if (joinBlocks.GetLastPoint(last)) {
- dc.DrawLine(last, lastMousePoint);
- joinBlocks.Draw(dc);
+void
+MyCanvas::OnPaint (wxPaintEvent & event)
+{
+ activeShapes.ClearConnectionPoints ();
+ activeShapes.MarkConnectionPoints ();
+
+ wxPaintDC dc (this);
+ PrepareDC (dc);
+
+ // Find Out where the window is scrolled to
+ int vbX, vbY; // Top left corner of client
+ GetViewStart (&vbX, &vbY);
+ wxRegionIterator upd (GetUpdateRegion ()); // get the update rect list
+
+ wxRect nrect;
+ while (upd)
+ {
+ wxRect rect (upd.GetRect ());
+ wxPoint tl (rect.x, rect.y);
+ wxPoint ntl;
+ CalcUnscrolledPosition (tl.x, tl.y, &ntl.x, &ntl.y);
+ wxSize updateSize (upd.GetWidth (), upd.GetHeight ());
+ nrect = wxRect (ntl, updateSize);
+
+ MyListShapes::iterator it = activeShapes.begin ();
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ if (oneShape->Intersects (nrect))
+ oneShape->Draw (dc);
+ }
+ it++;
+ }
+ upd++;
}
- }
+
+ if (selectingRegion.IsSelected ())
+ {
+ selectingRegion.Draw (dc);
+ }
+
+ if (GetEditingMode () == PlaceJoinBlocks)
+ {
+ wxPoint last;
+ if (joinBlocks.GetLastPoint (last))
+ {
+ dc.DrawLine (last, lastMousePoint);
+ joinBlocks.Draw (dc);
+ }
+ }
}
-wxPoint MyCanvas::GetUnscrolledPosition(wxMouseEvent & event)
+wxPoint MyCanvas::GetUnscrolledPosition (wxMouseEvent & event)
{
- wxPoint pt(event.GetX(), event.GetY());
- wxPoint disp;
- CalcUnscrolledPosition(pt.x, pt.y, &disp.x, &disp.y);
+ wxPoint
+ pt (event.GetX (), event.GetY ());
+ wxPoint
+ disp;
+ CalcUnscrolledPosition (pt.x, pt.y, &disp.x, &disp.y);
// printf(" %d,%d ===> %d,%d\n", pt.x, pt.y, disp.x, disp.y);
- return disp;
+ return disp;
}
-void MyCanvas::OnLeftDown (wxMouseEvent & event)
+void
+MyCanvas::OnLeftDown (wxMouseEvent & event)
{
- wxPoint pt = GetUnscrolledPosition(event);
- lastMousePoint = pt;
- lastMouseDownPoint = pt;
+ wxPoint pt = GetUnscrolledPosition (event);
+ lastMousePoint = pt;
+ lastMouseDownPoint = pt;
- if (GetEditingMode() == PlaceJoinBlocks) {
- joinBlocks.AddNewPoint(pt);
- Refresh();
- return;
- }
+ if (GetEditingMode () == PlaceJoinBlocks)
+ {
+ joinBlocks.AddNewPoint (pt);
+ Refresh ();
+ return;
+ }
- if (GetEditingMode() == PlaceOneShape) {
- DndShape::Kind kind = pFrame->GetImageTypeForPlacing();
- DndShape *newShape = DndShape::Construct(kind);
- if (newShape != NULL) {
- pFrame->SetImageTypeForPlacing(DndShape::None);
- newShape->CenterOnThisPosition(pt);
- activeShapes.Append(newShape);
- Refresh();
- SetEditingMode(WaitDownEvent);
- }
- return;
- }
+ if (GetEditingMode () == PlaceOneShape)
+ {
+ DndShape::Kind kind = pFrame->GetImageTypeForPlacing ();
+ DndShape *newShape = DndShape::Construct (kind);
+ if (newShape != NULL)
+ {
+ pFrame->SetImageTypeForPlacing (DndShape::None);
+ newShape->CenterOnThisPosition (pt);
+ activeShapes.Append (newShape);
+ Refresh ();
+ SetEditingMode (WaitDownEvent);
+ }
+ return;
+ }
- /* Left button down, no current "Kind" selected. we are therefore going to
- move an object from the cureent position, or mark additional buttons.. */
- if (!event.ShiftDown()) {
- selectingRegion.SetSelected(false);
- selectingRegion.SetPosition(lastMousePoint);
- activeShapes.UnselectAllShapes();
- }
- SetEditingMode(DownEventNew);
+ /* Left button down, no current "Kind" selected. we are therefore going to
+ * move an object from the cureent position, or mark additional buttons.. */
+ if (!event.ShiftDown ())
+ {
+ selectingRegion.SetSelected (false);
+ selectingRegion.SetPosition (lastMousePoint);
+ activeShapes.UnselectAllShapes ();
+ }
+ SetEditingMode (DownEventNew);
- MyListShapes::iterator it = activeShapes.begin();
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- if (oneShape->Intersects(pt)) {
- oneShape->SetSelected();
- Refresh();
- return;
+ MyListShapes::iterator it = activeShapes.begin ();
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ if (oneShape->Intersects (pt))
+ {
+ oneShape->SetSelected ();
+ Refresh ();
+ return;
+ }
+ }
+ it++;
}
- }
- it++;
- }
-
- if (!event.ShiftDown())
- SetEditingMode(SelectRectangle);
+
+ if (!event.ShiftDown ())
+ SetEditingMode (SelectRectangle);
}
-void MyCanvas::OnProgressTimer(wxTimerEvent & event)
+void
+MyCanvas::OnProgressTimer (wxTimerEvent & event)
{
- static int count = 0;
- count++;
- bool mouseHasStopped = (lastMouseMovePoint == oldMousePoint);
- oldMousePoint = lastMouseMovePoint;
+ static int count = 0;
+ count++;
+ bool mouseHasStopped = (lastMouseMovePoint == oldMousePoint);
+ oldMousePoint = lastMouseMovePoint;
- if (mouseHasStopped) {
- MyListShapes::iterator it = activeShapes.begin();
- // printf(" Found a no movment at %3d %3d for %d\n",
- // oldMousePoint.x, oldMousePoint.y, count++);
-
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- if (oneShape->Intersects(oldMousePoint)) {
- wxPaintDC dc(this);
- PrepareDC(dc);
- wxCoord w, h;
- wxString toolTip = oneShape->GetToolTip();
- GetTextExtent(toolTip, &w, &h);
- wxPoint thisPoint;
- thisPoint.x = oldMousePoint.x - (w/2);
- thisPoint.y = oldMousePoint.y - h;
- dc.SetPen(*wxWHITE);
- dc.SetBrush(wxBrush(*wxWHITE, wxSOLID));
- dc.DrawRoundedRectangle(thisPoint.x, thisPoint.y, w, h, 5);
- dc.SetPen(*wxBLACK);
- dc.DrawText(toolTip, thisPoint);
- }
- }
- it++;
- }
- } else
- Refresh();
+ if (mouseHasStopped)
+ {
+ MyListShapes::iterator it = activeShapes.begin ();
+ // printf(" Found a no movment at %3d %3d for %d\n",
+ // oldMousePoint.x, oldMousePoint.y, count++);
+
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ if (oneShape->Intersects (oldMousePoint))
+ {
+ wxPaintDC dc (this);
+ PrepareDC (dc);
+ wxCoord w, h;
+ wxString toolTip =
+ oneShape->GetToolTip ();
+ GetTextExtent (toolTip, &w, &h);
+ wxPoint thisPoint;
+ thisPoint.x =
+ oldMousePoint.x - (w / 2);
+ thisPoint.y = oldMousePoint.y - h;
+ dc.SetPen (*wxWHITE);
+ dc.SetBrush (wxBrush
+ (*wxWHITE, wxSOLID));
+ dc.DrawRoundedRectangle (thisPoint.x,
+ thisPoint.y,
+ w, h, 5);
+ dc.SetPen (*wxBLACK);
+ dc.DrawText (toolTip, thisPoint);
+ }
+ }
+ it++;
+ }
+ }
+ else
+ Refresh ();
}
-void MyCanvas::OnMouseMove (wxMouseEvent & event)
-{
- wxPoint currentMousePoint = GetUnscrolledPosition(event);
- lastMouseMovePoint = currentMousePoint;
+void
+MyCanvas::OnMouseMove (wxMouseEvent & event)
+{
+ wxPoint currentMousePoint = GetUnscrolledPosition (event);
+ lastMouseMovePoint = currentMousePoint;
- EditingMode em = GetEditingMode();
+ EditingMode em = GetEditingMode ();
- if (em == PlaceOneShape) {
- lastMousePoint = currentMousePoint;
- return;
- }
+ if (em == PlaceOneShape)
+ {
+ lastMousePoint = currentMousePoint;
+ return;
+ }
- if (em == DownEventNew) {
- if (selectingRegion.IsSelected()) {
- SetEditingMode(MovingShapesRectangle);
- } else {
- SetEditingMode(MovingShapes);
- }
- }
+ if (em == DownEventNew)
+ {
+ if (selectingRegion.IsSelected ())
+ {
+ SetEditingMode (MovingShapesRectangle);
+ }
+ else
+ {
+ SetEditingMode (MovingShapes);
+ }
+ }
- if (em == PlaceJoinBlocks) {
- lastMousePoint = currentMousePoint;
- Refresh();
- return;
- }
+ if (em == PlaceJoinBlocks)
+ {
+ lastMousePoint = currentMousePoint;
+ Refresh ();
+ return;
+ }
- if (event.LeftIsDown()) {
- if ((em == MovingShapes) || (em == MovingShapesRectangle)) {
- wxPoint delta;
-
- delta.x = currentMousePoint.x - lastMousePoint.x;
- delta.y = currentMousePoint.y - lastMousePoint.y;
-
- MyListShapes::iterator it = activeShapes.begin();
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- if (oneShape->IsSelected()) {
- oneShape->AdjustPosition(delta);
- }
- }
- it++;
+ if (event.LeftIsDown ())
+ {
+ if ((em == MovingShapes) || (em == MovingShapesRectangle))
+ {
+ wxPoint delta;
+
+ delta.x = currentMousePoint.x - lastMousePoint.x;
+ delta.y = currentMousePoint.y - lastMousePoint.y;
+
+ MyListShapes::iterator it = activeShapes.begin ();
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ if (oneShape->IsSelected ())
+ {
+ oneShape->
+ AdjustPosition
+ (delta);
+ }
+ }
+ it++;
+ }
+
+ if (em == MovingShapesRectangle)
+ selectingRegion.AdjustPosition (delta);
+ lastMousePoint = currentMousePoint;
+ Refresh ();
+ return;
+ }
}
-
- if (em == MovingShapesRectangle)
- selectingRegion.AdjustPosition(delta);
+
lastMousePoint = currentMousePoint;
- Refresh();
- return;
- }
- }
+ if (em == SelectRectangle)
+ {
+ //Calculate the region that we draw a box around.
+ selectingRegion.SetOtherCorner (currentMousePoint);
- lastMousePoint = currentMousePoint;
- if (em == SelectRectangle) {
- //Calculate the region that we draw a box around.
- selectingRegion.SetOtherCorner(currentMousePoint);
+ MyListShapes::iterator it = activeShapes.begin ();
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ bool isSelected =
+ oneShape->Intersects (selectingRegion.
+ GetRect ());
+ oneShape->SetSelected (isSelected);
+ }
+ it++;
+ }
+ Refresh ();
+ return;
+ }
- MyListShapes::iterator it = activeShapes.begin();
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- bool isSelected = oneShape->Intersects(selectingRegion.GetRect());
- oneShape->SetSelected(isSelected);
- }
- it++;
- }
- Refresh();
- return;
- }
-
// printf("On mouse move at %d, %d %s\n",
-// event.GetX(), event.GetY(),
-// (event.LeftIsDown() ? "is down" : "is up"));
+// event.GetX(), event.GetY(),
+// (event.LeftIsDown() ? "is down" : "is up"));
}
-
-void MyCanvas::OnLeftUp (wxMouseEvent & event)
+
+void
+MyCanvas::OnLeftUp (wxMouseEvent & event)
{
- if (GetEditingMode() != PlaceJoinBlocks)
- SetEditingMode(WaitDownEvent);
- Refresh();
- // printf("On mouse left up at %d, %d \n",
- // event.GetX(), event.GetY());
+ if (GetEditingMode () != PlaceJoinBlocks)
+ SetEditingMode (WaitDownEvent);
+ Refresh ();
+ // printf("On mouse left up at %d, %d \n",
+ // event.GetX(), event.GetY());
}
-void MyCanvas::OnMouseEnter (wxMouseEvent & event)
+void
+MyCanvas::OnMouseEnter (wxMouseEvent & event)
{
- if (GetEditingMode() == PlaceOneShape) {
- Refresh();
- return;
- }
-
- // SetEditingMode(WaitDownEvent);
- Refresh();
+ if (GetEditingMode () == PlaceOneShape)
+ {
+ Refresh ();
+ return;
+ }
+
+ // SetEditingMode(WaitDownEvent);
+ Refresh ();
}
-void MyCanvas::OnMouseLeave (wxMouseEvent & event)
+void
+MyCanvas::OnMouseLeave (wxMouseEvent & event)
{
- // SetEditingMode(WaitDownEvent);
- Refresh();
+ // SetEditingMode(WaitDownEvent);
+ Refresh ();
}
-
-void MyCanvas::OnRightDown (wxMouseEvent & event)
+
+void
+MyCanvas::OnRightDown (wxMouseEvent & event)
{
- wxPoint pt = GetUnscrolledPosition(event);
- if (editingMode == PlaceJoinBlocks) {
- joinBlocks.AddNewPoint(pt);
-
- DndShape *nJoin = DndShape::Construct(DndShape::JoinBlocks);
- wxString points = joinBlocks.GetShapeInfoSpecial();
- joinBlocks.RemoveCurrentPoints();
- nJoin->SetShapeInfoSpecial(points);
- activeShapes.Append(nJoin);
-
- SetEditingMode(WaitDownEvent);
- Refresh();
- return;
- }
+ wxPoint pt = GetUnscrolledPosition (event);
+ if (editingMode == PlaceJoinBlocks)
+ {
+ joinBlocks.AddNewPoint (pt);
- MyListShapes::iterator it = activeShapes.begin();
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- if (oneShape->Intersects(pt))
- oneShape->ProcessRightMouseButton(pFrame);
- }
- it++;
- }
+ DndShape *nJoin = DndShape::Construct (DndShape::JoinBlocks);
+ wxString points = joinBlocks.GetShapeInfoSpecial ();
+ joinBlocks.RemoveCurrentPoints ();
+ nJoin->SetShapeInfoSpecial (points);
+ activeShapes.Append (nJoin);
+
+ SetEditingMode (WaitDownEvent);
+ Refresh ();
+ return;
+ }
+
+ MyListShapes::iterator it = activeShapes.begin ();
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ if (oneShape->Intersects (pt))
+ oneShape->ProcessRightMouseButton (pFrame);
+ }
+ it++;
+ }
}
-void MyCanvas::ScreenToClipboard()
+void
+MyCanvas::ScreenToClipboard ()
{
- wxString toCopy;
-
- MyListShapes::iterator it = activeShapes.begin();
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- if (oneShape->IsSelected())
- toCopy += oneShape->GetShapeInfo();
- }
- it++;
- }
-
- //printf("shape %s\n", (const char *)toCopy);
- wxTheClipboard->UsePrimarySelection();
- if (wxTheClipboard->Open()) {
- wxTheClipboard->SetData( new wxTextDataObject(toCopy) );
- wxTheClipboard->Close();
- }
+ wxString toCopy;
+
+ MyListShapes::iterator it = activeShapes.begin ();
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ if (oneShape->IsSelected ())
+ toCopy += oneShape->GetShapeInfo ();
+ }
+ it++;
+ }
+
+ //printf("shape %s\n", (const char *)toCopy);
+ wxTheClipboard->UsePrimarySelection ();
+ if (wxTheClipboard->Open ())
+ {
+ wxTheClipboard->SetData (new wxTextDataObject (toCopy));
+ wxTheClipboard->Close ();
+ }
}
-void MyCanvas::ClipboardToScreen()
+void
+MyCanvas::ClipboardToScreen ()
{
- if (!wxTheClipboard->Open())
- return;
+ if (!wxTheClipboard->Open ())
+ return;
- activeShapes.UnselectAllShapes();
+ activeShapes.UnselectAllShapes ();
- if (wxTheClipboard->IsSupported( wxDF_TEXT )) {
- wxTextDataObject data;
- wxTheClipboard->GetData(data);
- activeShapes.AddNewShapes(data.GetText(), true);
- Refresh();
- }
- wxTheClipboard->Close();
-}
+ if (wxTheClipboard->IsSupported (wxDF_TEXT))
+ {
+ wxTextDataObject data;
+ wxTheClipboard->GetData (data);
+ activeShapes.AddNewShapes (data.GetText (), true);
+ }
+ wxTheClipboard->Close ();
+}
- void MyCanvas::OnChar(wxKeyEvent& event)
+void
+MyCanvas::OnChar (wxKeyEvent & event)
{
- wxString key;
- bool changedScreen = false;
- long keycode = event.GetKeyCode();
+ wxString key;
+ bool changedScreen = false;
+ long keycode = event.GetKeyCode ();
- if (keycode == WXK_DELETE) {
- RemoveSelectedShapes();
- changedScreen = true;
- }
-
- // printf ("keyocde is %d\n", keycode);
- if (event.ControlDown()) {
- // printf("Control is down\n");
- if (keycode == 99) { /* Process Ctrl - c */
- ScreenToClipboard();
- changedScreen = true;
- }
+ if (keycode == WXK_DELETE)
+ {
+ RemoveSelectedShapes ();
+ changedScreen = true;
+ }
- if ((keycode == WXK_INSERT) || (keycode == 118)) { /* Process Ctrl - v */
- ClipboardToScreen();
- changedScreen = true;
- }
+ // printf ("keyocde is %d\n", keycode);
+ if (event.ControlDown ())
+ {
+ // printf("Control is down\n");
+ if (keycode == 99)
+ { /* Process Ctrl - c */
+ ScreenToClipboard ();
+ changedScreen = true;
+ }
- }
+ if ((keycode == WXK_INSERT) || (keycode == 118))
+ { /* Process Ctrl - v */
+ ClipboardToScreen ();
+ changedScreen = true;
+ }
- if (changedScreen) {
- Refresh();
- event.Skip();
- return;
- }
+ }
+
+ if (changedScreen)
+ {
+ Refresh ();
+ event.Skip ();
+ return;
+ }
}
-void MyCanvas::ShapeInformationToFile(wxString & fileName)
+void
+MyCanvas::ShapeInformationToFile (wxString & fileName)
{
- wxString data;
+ wxString data;
- MyListShapes::iterator it = activeShapes.begin();
- while (it != activeShapes.end()) {
- DndShape *oneShape = it->second;
- if (oneShape != NULL) {
- data += oneShape->GetShapeInfo();
- }
- it++;
- }
-
- wxTextFile file(fileName);
-
- if (!file.Exists())
- file.Create();
- file.Open();
- if (!file.IsOpened()) {
- return;
- }
+ MyListShapes::iterator it = activeShapes.begin ();
+ while (it != activeShapes.end ())
+ {
+ DndShape *oneShape = it->second;
+ if (oneShape != NULL)
+ {
+ data += oneShape->GetShapeInfo ();
+ }
+ it++;
+ }
- file.Clear();
- file.AddLine(data);
- file.Write();
- file.Close();
+ wxTextFile file (fileName);
+
+ if (!file.Exists ())
+ file.Create ();
+ file.Open ();
+ if (!file.IsOpened ())
+ {
+ return;
+ }
+
+ file.Clear ();
+ file.AddLine (data);
+ file.Write ();
+ file.Close ();
}
-void MyCanvas::ReadShapeInformationFromFile(wxString & fileName)
+void
+MyCanvas::ReadShapeInformationFromFile (wxString & fileName)
{
- wxTextFile file(fileName);
- file.Open();
+ wxTextFile file (fileName);
+ file.Open ();
- if (!file.IsOpened()) {
- return;
- }
+ if (!file.IsOpened ())
+ {
+ return;
+ }
- wxString data;
- for (data = file.GetFirstLine(); !file.Eof();)
- data += wxString(file.GetEOL()) + file.GetNextLine();
+ wxString data;
+ for (data = file.GetFirstLine (); !file.Eof ();)
+ data += wxString (file.GetEOL ()) + file.GetNextLine ();
- file.Close();
+ file.Close ();
- RemoveCurrentShapes();
- activeShapes.AddNewShapes(data);
- Refresh();
+ RemoveCurrentShapes ();
+ activeShapes.AddNewShapes (data);
+ Refresh ();
}
-void MyCanvas::RemoveCurrentShapes()
-{
- selectingRegion.SetSelected(false);
- activeShapes.RemoveCurrentShapes();
+void
+MyCanvas::RemoveCurrentShapes ()
+{
+ selectingRegion.SetSelected (false);
+ activeShapes.RemoveCurrentShapes ();
}
-void MyCanvas::DisplayTextPopup(const wxString& text) //, const wxPoint& WXUNUSED(pos))
+void
+MyCanvas::DisplayTextPopup (const wxString & text) //, const wxPoint& WXUNUSED(pos))
{
#if wxUSE_TIPWINDOW
- // #warning "tip windows on "
- static wxString oldMessage;
- if (text == oldMessage)
- return;
- oldMessage = text;
+ // #warning "tip windows on "
+ static wxString oldMessage;
+ if (text == oldMessage)
+ return;
+ oldMessage = text;
- static wxTipWindow* s_tipWindow = NULL;
-
- if (s_tipWindow){
- // Prevent s_tipWindow being nulled in OnIdle,
- // thereby removing the chance for the window to be closed by ShowHelp
- s_tipWindow->SetTipWindowPtr(NULL);
- s_tipWindow->Close();
- }
- s_tipWindow = NULL;
-
- if ( !text.empty() ) {
- s_tipWindow = new wxTipWindow(wxTheApp->GetTopWindow(), text, 100, & s_tipWindow);
-
- return;
- }
+ static wxTipWindow *s_tipWindow = NULL;
+
+ if (s_tipWindow)
+ {
+ // Prevent s_tipWindow being nulled in OnIdle,
+ // thereby removing the chance for the window to be closed by ShowHelp
+ s_tipWindow->SetTipWindowPtr (NULL);
+ s_tipWindow->Close ();
+ }
+ s_tipWindow = NULL;
+
+ if (!text.empty ())
+ {
+ s_tipWindow =
+ new wxTipWindow (wxTheApp->GetTopWindow (), text, 100,
+ &s_tipWindow);
+
+ return;
+ }
#else
- wxUnusedVar(text);
+ wxUnusedVar (text);
#endif // wxUSE_TIPWINDOW
- }
+}
-void MyCanvas::SetEditingMode(EditingMode newMode)
+void
+MyCanvas::SetEditingMode (EditingMode newMode)
{
- if (newMode == editingMode)
- return;
+ if (newMode == editingMode)
+ return;
- editingMode = newMode;
- // printf("YES. set editing mode to %d\n\n", newMode);
- switch (newMode)
- {
- case WaitDownEvent:;
- {
- CloseJoinBlocks();
- pFrame->SetStatusText("Waiting for a mouse click event");
- }
- break;
- case DownEventNew:;
- {
- CloseJoinBlocks();
- pFrame->SetStatusText("Waiting for a mouse click event");
- }
- break;
- case PlaceOneShape:;
- {
- CloseJoinBlocks();
- wxString kindName = DndShape::GetKindName(pFrame->GetImageTypeForPlacing());
- wxString mess= wxString("Set the mouse at desired position to place a ") + kindName;
- pFrame->SetStatusText(mess);
- selectingRegion.SetSelected(false);
- activeShapes.UnselectAllShapes();
- }
- break;
- case SelectRectangle:;
- {
- CloseJoinBlocks();
- pFrame->SetStatusText("Mark a rectangle on screen, and select objects within");
- selectingRegion.SetOtherCorner(lastMouseDownPoint);
- selectingRegion.SetSelected(true);
- }
- break;
- case MovingShapes:;
- {
- CloseJoinBlocks();
- pFrame->SetStatusText("Moving one or more shapes on the screen");
- }
- break;
- case MovingShapesRectangle:;
- {
- CloseJoinBlocks();
- pFrame->SetStatusText("Moving one or more shapes, and a selecting rectangle, on the screen");
- }
- break;
- case PlaceJoinBlocks:;
- {
- pFrame->SetStatusText("Draw interconnecting logic flow between blocks on the screen");
- }
- break;
- default:
- {
- pFrame->SetStatusText("Should not be selected");
- }
- break;
- }
+ editingMode = newMode;
+ // printf("YES. set editing mode to %d\n\n", newMode);
+ switch (newMode)
+ {
+ case WaitDownEvent:;
+ {
+ CloseJoinBlocks ();
+ pFrame->SetStatusText
+ ("Waiting for a mouse click event");
+ }
+ break;
+ case DownEventNew:;
+ {
+ CloseJoinBlocks ();
+ pFrame->SetStatusText
+ ("Waiting for a mouse click event");
+ }
+ break;
+ case PlaceOneShape:;
+ {
+ CloseJoinBlocks ();
+ wxString kindName =
+ DndShape::GetKindName (pFrame->
+ GetImageTypeForPlacing
+ ());
+ wxString mess =
+ wxString
+ ("Set the mouse at desired position to place a ")
+ + kindName;
+ pFrame->SetStatusText (mess);
+ selectingRegion.SetSelected (false);
+ activeShapes.UnselectAllShapes ();
+ }
+ break;
+ case SelectRectangle:;
+ {
+ CloseJoinBlocks ();
+ pFrame->SetStatusText
+ ("Mark a rectangle on screen, and select objects within");
+ selectingRegion.SetOtherCorner (lastMouseDownPoint);
+ selectingRegion.SetSelected (true);
+ }
+ break;
+ case MovingShapes:;
+ {
+ CloseJoinBlocks ();
+ pFrame->SetStatusText
+ ("Moving one or more shapes on the screen");
+ }
+ break;
+ case MovingShapesRectangle:;
+ {
+ CloseJoinBlocks ();
+ pFrame->SetStatusText
+ ("Moving one or more shapes, and a selecting rectangle, on the screen");
+ }
+ break;
+ case PlaceJoinBlocks:;
+ {
+ pFrame->SetStatusText
+ ("Draw interconnecting logic flow between blocks on the screen");
+ }
+ break;
+ default:
+ {
+ pFrame->SetStatusText ("Should not be selected");
+ }
+ break;
+ }
}
-
-
-
Modified: sofaswitch/trunk/callflow/src/loadnewgraph.cpp
==============================================================================
--- sofaswitch/trunk/callflow/src/loadnewgraph.cpp (original)
+++ sofaswitch/trunk/callflow/src/loadnewgraph.cpp Wed Nov 8 22:51:30 2006
@@ -72,6 +72,7 @@
file.AddLine(" f = MyFactory() ");
file.AddLine(" f.isMaster = False ");
file.AddLine(" f.setGraph(fname) ");
+ file.AddLine(" f.setMaster(False) ");
file.AddLine(" reactor.connectTCP(sofaServer, 5000, f) ");
file.AddLine(" return self.data[a][\"Output\"] ");
file.AddLine("");
Modified: sofaswitch/trunk/callflow/src/shapelist.cpp
==============================================================================
--- sofaswitch/trunk/callflow/src/shapelist.cpp (original)
+++ sofaswitch/trunk/callflow/src/shapelist.cpp Wed Nov 8 22:51:30 2006
@@ -316,6 +316,13 @@
file.AddLine(tString.c_str());
file.AddLine(" ");
+ file.AddLine(" def setMaster(self, newIsMaster): ");
+ file.AddLine(" \"\"\"Set the flag to indicate if we have been spawned ");
+ file.AddLine(" as a child process, or if we are key launching ");
+ file.AddLine(" process that was invoked from the command line. ");
+ file.AddLine(" \"\"\" ");
+ file.AddLine(" self.isMaster = newIsMaster ");
+ file.AddLine(" ");
file.AddLine(" def setGraphData(self, graphFile): ");
file.AddLine(" \"\"\"Read in the file which describes where the flow ");
file.AddLine(" of execution goes, and variables associated with ");
@@ -540,13 +547,19 @@
file.AddLine(" p.factory = self ");
file.AddLine(" self.myController = p ");
file.AddLine(" self.myController.setGraphData(self.myGraphName) ");
+ file.AddLine(" self.myController.setMaster(self.isMaster) ");
file.AddLine(" return p ");
file.AddLine(" ");
file.AddLine(" def setGraph(self, newName): ");
file.AddLine(" self.myGraphName = newName ");
file.AddLine(" ");
+ file.AddLine(" def setMaster(self, newMaster): ");
+ file.AddLine(" self.isMaster = newMaster ");
+ file.AddLine(" ");
+ file.AddLine(" ");
file.AddLine("f = MyFactory() ");
file.AddLine(wxString::Format("f.setGraph(\"%s\") ", graphFileName.c_str()));
+ file.AddLine("f.setMaster(True) ");
file.AddLine("reactor.connectTCP(sofaServer, 5000, f) ");
file.AddLine("reactor.run() ");
file.AddLine(" ");
Modified: sofaswitch/trunk/callflow/tests/amplaywavfile.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/amplaywavfile.src (original)
+++ sofaswitch/trunk/callflow/tests/amplaywavfile.src Wed Nov 8 22:51:30 2006
@@ -1,3 +1,3 @@
-9<B>632<B>318<B>632,366,638,319,685,318,685,330<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>821<B>356<B>821,357,977,357,1018,356<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>1<B>190<B>19<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>9<B>544<B>394<B>606,394,602,560,544,561<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>5<B>241<B>359<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>(self.amNode != None) and (self.soundNode != None)<ms><special> <B><Shape>17<B>516<B>509<B> extra <special>Tool Tip<ms>Write To File<ms><special>Filename to contain new audio (Python code)<ms>"recorded_audio.wav"<ms><special>answering machine node<ms>self.amNode<ms><special> <B><Shape>15<B>989<B>451<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>"sound"<ms><special>Second SofaSwitch worker (python)<ms>"sound"<ms><special> <B><Shape>14<B>202<B>162<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>amREQ<ms><special>Python variable to hold event data<ms>self.amNode<ms><special> <B><Shape>2<B>307<B>394<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>14<B>295<B>185<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>soundREQU<ms><special>Python variable to hold event data<ms>self.soundNode<ms><special> <B><Shape>9<B>559<B>339<B>559,339,604,342<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>16<B>516<B>561<B> extra <special>Tool Tip<ms>initial wav file<ms><special>Filename to read audio from (Python code)<ms>"../prompts/instructions.wav"<ms><special>answering machine node<ms>self.amNode<ms><special> <B><Shape>20<B>529<B>662<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>9<B>712<B>318<B>712,358,755,361,750,320,793,318,798,333<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>16<B>505<B>364<B> extra <special>Tool Tip<ms>Read From File<ms><special>Filename to read audio from (Python code)<ms>"../prompts/sample_message.wav"<ms><special>answering machine node<ms>self.amNode<ms><special> <B><Shape>5<B>991<B>358<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>self.dtmfData=="9"<ms><special> <B><Shape>10<B>990<B>405<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "hangup, as dtmf 9 has been received"<ms><special> <B><Shape>9<B>266<B>329<B>308,329,266,359<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>2<B>505<B>398<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>9<B>264<B>199<B>264,513,264,635,426,639,428,199,532,202,532,262<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>13<B>190<B>210<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>request voip<ms><special> <B><Shape>10<B>190<B>254<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Have a new am node on ", self.amNode<ms><special> <B><Shape>13<B>284<B>231<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>request sound<ms><special> <B><Shape>15<B>240<B>412<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>self.amNode<ms><special>Second SofaSwitch worker (python)<ms>self.soundNode<ms><special> <B><Shape>9<B>302<B>485<B>302,485,544,492,542,506<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>5<B>770<B>331<B> extra <special>Tool Tip<ms>play leaving sound<ms><special>Test (Python code)<ms>self.dtmfData=="3"<ms><special> <B><Shape>5<B>660<B>332<B> extra <special>Tool Tip<ms>play entering sound<ms><special>Test (Python code)<ms>self.dtmfData=="2"<ms><special> <B><Shape>5<B>507<B>312<B> extra <special>Tool Tip<ms>Test Roger voice<ms><special>Test (Python code)<ms>self.dtmfData=="1"<ms><special> <B><Shape>2<B>659<B>427<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>2<B>1058<B>385<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>5<B>581<B>341<B> extra <special>Tool Tip<ms>Repeat instructions<ms><special>Test (Python code)<ms>self.dtmfData=="4"<ms><special> <B><Shape>11<B>190<B>68<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from<ms>am<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestam<ms><special> <B><Shape>10<B>507<B>259<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "dtmf received of ", self.dtmfData<ms><special> <B><Shape>14<B>529<B>614<B> extra <special>Tool Tip<ms>Catch the timer which, when fired,
-indicates the end of this call<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>hanguptime<ms><special>Python variable to hold event data<ms>self.hanguptime<ms><special> <B><Shape>16<B>659<B>379<B> extra <special>Tool Tip<ms>play entering sound<ms><special>Filename to read audio from (Python code)<ms>"../prompts/entering.wav"<ms><special>answering machine node (Python code)<ms>self.amNode<ms><special> <B><Shape>9<B>291<B>382<B>291,386,334,382,332,395<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>2<B>769<B>426<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>14<B>251<B>461<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>DTMF<ms><special>Python variable to hold event data<ms>self.dtmfData<ms><special> <B><Shape>7<B>989<B>497<B> extra <special>Tool Tip<ms>End Call<ms><special>Worker node to activate (python code)<ms>self.amNode<ms><special> <B><Shape>10<B>282<B>279<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print " have a sound node of ", self.soundNode<ms><special> <B><Shape>12<B>990<B>549<B> extra <special>Tool Tip<ms>Initiate a timer, which causes this to
-end.<ms><special>Timer period (seconds)<ms>0.1<ms><special>Timer label (string literal)<ms>hanguptime<ms><special> <B><Shape>9<B>1039<B>386<B>1039,386,1082,387<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>248<B>182<B>248,183,308,182<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>214<B>304<B>214,304,262,356<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>16<B>770<B>378<B> extra <special>Tool Tip<ms>play leaving sound<ms><special>Filename to read audio from (Python code)<ms>"../prompts/leaving.wav"<ms><special>answering machine node (Python code)<ms>self.amNode<ms><special> <B><Shape>11<B>189<B>117<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from<ms>sound<ms><special>Timer period (seconds)<ms>2<ms><special>Timer label<ms>request sound<ms><special> <B><Shape>2<B>991<B>588<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>
+12<B>990<B>549<B> extra <special>Tool Tip<ms>Initiate a timer, which causes this to
+end.<ms><special>Timer period (seconds)<ms>0.1<ms><special>Timer label (string literal)<ms>hanguptime<ms><special> <B><Shape>14<B>251<B>461<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>DTMF<ms><special>Python variable to hold event data<ms>self.dtmfData<ms><special> <B><Shape>16<B>505<B>364<B> extra <special>Tool Tip<ms>Play Rogers voice<ms><special>Filename to read audio from (Python code)<ms>"../prompts/sample_message.wav"<ms><special>answering machine node<ms>self.amNode<ms><special> <B><Shape>16<B>516<B>561<B> extra <special>Tool Tip<ms>initial wav file<ms><special>Filename to read audio from (Python code)<ms>"../prompts/instructions.wav"<ms><special>answering machine node<ms>self.amNode<ms><special> <B><Shape>2<B>769<B>426<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>9<B>559<B>339<B>559,339,604,342<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>11<B>191<B>67<B> extra <special>Tool Tip<ms>Request Node from AM module<ms><special>Request node from (Python code)<ms>"am"<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestam<ms><special>Additional information (Python code)<ms><ms><special> <B><Shape>5<B>660<B>332<B> extra <special>Tool Tip<ms>play entering sound<ms><special>Test (Python code)<ms>self.dtmfData=="2"<ms><special> <B><Shape>5<B>241<B>359<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>(self.amNode != None) and (self.soundNode != None)<ms><special> <B><Shape>10<B>507<B>259<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "dtmf received of ", self.dtmfData<ms><special> <B><Shape>20<B>529<B>662<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>13<B>190<B>210<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>request voip<ms><special> <B><Shape>7<B>989<B>497<B> extra <special>Tool Tip<ms>End Call<ms><special>Worker node to activate (python code)<ms>self.amNode<ms><special> <B><Shape>9<B>1039<B>386<B>1039,386,1082,387<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>5<B>507<B>312<B> extra <special>Tool Tip<ms>Test Roger voice<ms><special>Test (Python code)<ms>self.dtmfData=="1"<ms><special> <B><Shape>9<B>266<B>329<B>308,329,266,359<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>13<B>284<B>231<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>request sound<ms><special> <B><Shape>9<B>712<B>318<B>712,358,755,361,750,320,793,318,798,333<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>291<B>382<B>291,386,334,382,332,395<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>5<B>581<B>341<B> extra <special>Tool Tip<ms>Repeat instructions<ms><special>Test (Python code)<ms>self.dtmfData=="4"<ms><special> <B><Shape>10<B>990<B>405<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "hangup, as dtmf 9 has been received"<ms><special> <B><Shape>9<B>632<B>318<B>632,366,638,319,685,318,685,330<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>202<B>162<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>amREQ<ms><special>Python variable to hold event data<ms>self.amNode<ms><special> <B><Shape>9<B>214<B>304<B>214,304,262,356<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>15<B>240<B>412<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>self.amNode<ms><special>Second SofaSwitch worker (python)<ms>self.soundNode<ms><special> <B><Shape>2<B>659<B>427<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>15<B>989<B>451<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>"sound"<ms><special>Second SofaSwitch worker (python)<ms>"sound"<ms><special> <B><Shape>14<B>295<B>185<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>soundREQU<ms><special>Python variable to hold event data<ms>self.soundNode<ms><special> <B><Shape>9<B>302<B>485<B>302,485,544,492,542,506<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>821<B>356<B>821,357,977,357,1018,356<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>5<B>770<B>331<B> extra <special>Tool Tip<ms>play leaving sound<ms><special>Test (Python code)<ms>self.dtmfData=="3"<ms><special> <B><Shape>14<B>529<B>614<B> extra <special>Tool Tip<ms>Catch the timer which, when fired,
+indicates the end of this call<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>hanguptime<ms><special>Python variable to hold event data<ms>self.hanguptime<ms><special> <B><Shape>9<B>248<B>182<B>248,183,308,182<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>17<B>516<B>509<B> extra <special>Tool Tip<ms>Write To File<ms><special>Filename to contain new audio (Python code)<ms>"recorded_audio.wav"<ms><special>answering machine node<ms>self.amNode<ms><special> <B><Shape>16<B>659<B>379<B> extra <special>Tool Tip<ms>play entering sound<ms><special>Filename to read audio from (Python code)<ms>"../prompts/entering.wav"<ms><special>answering machine node (Python code)<ms>self.amNode<ms><special> <B><Shape>5<B>991<B>358<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>self.dtmfData=="9"<ms><special> <B><Shape>10<B>190<B>254<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Have a new am node on ", self.amNode<ms><special> <B><Shape>9<B>544<B>394<B>606,394,602,560,544,561<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>2<B>505<B>398<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>2<B>1058<B>385<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>10<B>282<B>279<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print " have a sound node of ", self.soundNode<ms><special> <B><Shape>2<B>307<B>394<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>16<B>770<B>378<B> extra <special>Tool Tip<ms>play leaving sound<ms><special>Filename to read audio from (Python code)<ms>"../prompts/leaving.wav"<ms><special>answering machine node (Python code)<ms>self.amNode<ms><special> <B><Shape>2<B>991<B>588<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>9<B>264<B>199<B>264,513,264,635,426,639,428,199,532,202,532,262<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>1<B>190<B>19<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>11<B>191<B>109<B> extra <special>Tool Tip<ms>Request Node from sound module<ms><special>Request node from (Python code)<ms>"sound"<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestsound<ms><special>Additional information (Python code)<ms><ms><special> <B><Shape>
Modified: sofaswitch/trunk/callflow/tests/dtmf_from_sound.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/dtmf_from_sound.src (original)
+++ sofaswitch/trunk/callflow/tests/dtmf_from_sound.src Wed Nov 8 22:51:30 2006
@@ -1 +1 @@
-2<B>320<B>493<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>5<B>108<B>450<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>self.dtmfData=="*"<ms><special> <B><Shape>10<B>108<B>407<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "DTMF detected is ", self.dtmfData<ms><special> <B><Shape>20<B>120<B>491<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>9<B>130<B>361<B>258,390,131,361,130,363<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>246<B>251<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>REQ<ms><special>Python variable to hold event data<ms>self.newNode<ms><special> <B><Shape>11<B>232<B>159<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from<ms>sound<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestnode<ms><special> <B><Shape>14<B>334<B>283<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>requestnode<ms><special>Python variable to hold event data<ms>self.timerData<ms><special> <B><Shape>1<B>231<B>108<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>9<B>157<B>475<B>157,475,347,493<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>13<B>231<B>340<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>requestnode<ms><special> <B><Shape>9<B>345<B>370<B>348,370,345,494<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>10<B>323<B>322<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "timer has expired at ", time.asctime(), " ", self.timerData<ms><special> <B><Shape>10<B>231<B>295<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have a new node on ", self.newNode<ms><special> <B><Shape>9<B>295<B>275<B>295,275,348,279<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>120<B>365<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>DTMF<ms><special>Python variable to hold event data<ms>self.dtmfData<ms><special> <B><Shape>10<B>232<B>204<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Have requested a node from sound at ", time.asctime()<ms><special> <B><Shape>
+9<B>335<B>274<B>338,274,335,398<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>1<B>221<B>12<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>11<B>222<B>64<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from (Python code)<ms>"sound"<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestnode<ms><special>Additional information (Python code)<ms><ms><special> <B><Shape>9<B>120<B>265<B>248,294,121,265,120,267<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>147<B>379<B>147,379,337,397<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>285<B>179<B>285,179,338,183<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>10<B>221<B>199<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have a new node on ", self.newNode<ms><special> <B><Shape>14<B>324<B>187<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>requestnode<ms><special>Python variable to hold event data<ms>self.timerData<ms><special> <B><Shape>20<B>110<B>395<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>5<B>98<B>354<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>self.dtmfData=="*"<ms><special> <B><Shape>14<B>236<B>155<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>REQ<ms><special>Python variable to hold event data<ms>self.newNode<ms><special> <B><Shape>10<B>313<B>226<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "timer has expired at ", time.asctime(), " ", self.timerData<ms><special> <B><Shape>10<B>222<B>108<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Have requested a node from sound at ", time.asctime()<ms><special> <B><Shape>10<B>98<B>311<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "DTMF detected is ", self.dtmfData<ms><special> <B><Shape>14<B>110<B>269<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>DTMF<ms><special>Python variable to hold event data<ms>self.dtmfData<ms><special> <B><Shape>2<B>310<B>397<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>13<B>221<B>244<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>requestnode<ms><special> <B><Shape>
Modified: sofaswitch/trunk/callflow/tests/forloop.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/forloop.src (original)
+++ sofaswitch/trunk/callflow/tests/forloop.src Wed Nov 8 22:51:30 2006
@@ -1 +1 @@
-10<B>307<B>108<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "loop index is ", self.i<ms><special> <B><Shape>3<B>299<B>62<B> extra <special>Tool Tip<ms>Start For<ms><special>Initialise (Python code)<ms>self.i = 0<ms><special>Test for Termination (Python code)<ms>self.i < 10<ms><special>Increment (Python code)<ms>self.i+=1<ms><special> <B><Shape>1<B>306<B>11<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>20<B>322<B>199<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>4<B>301<B>152<B> extra <special>Tool Tip<ms>End For Loop<ms><special> <B><Shape>9<B>258<B>84<B>296,87,258,84,259,174,299,178<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>
+4<B>301<B>152<B> extra <special>Tool Tip<ms>End For Loop<ms><special> <B><Shape>1<B>306<B>11<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>3<B>299<B>62<B> extra <special>Tool Tip<ms>Start For<ms><special>Initialise (Python code)<ms>self.i = 0<ms><special>Test for Termination (Python code)<ms>self.i < 10<ms><special>Increment (Python code)<ms>self.i+=1<ms><special> <B><Shape>20<B>322<B>199<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>10<B>307<B>108<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "loop index is ", self.i<ms><special> <B><Shape>9<B>258<B>84<B>296,87,258,84,259,174,299,178<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>
Modified: sofaswitch/trunk/callflow/tests/loadgraph.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/loadgraph.src (original)
+++ sofaswitch/trunk/callflow/tests/loadgraph.src Wed Nov 8 22:51:30 2006
@@ -1 +1 @@
-12<B>378<B>172<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>2<ms><special>Timer label (string literal)<ms>endloadgraph<ms><special> <B><Shape>1<B>379<B>35<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>20<B>391<B>305<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>18<B>378<B>79<B> extra <special>Tool Tip<ms>Load New Graph<ms><special>new graph file (Python code)<ms>"am_test.graph"<ms><special> <B><Shape>10<B>378<B>126<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have generated the new graph"<ms><special> <B><Shape>14<B>389<B>221<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>endloadgraph<ms><special>Python variable to hold event data<ms>self.eventData<ms><special> <B><Shape>10<B>377<B>262<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "end the master now"<ms><special> <B><Shape>
+10<B>378<B>126<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have generated the new graph"<ms><special> <B><Shape>20<B>391<B>305<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>1<B>379<B>35<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>18<B>378<B>79<B> extra <special>Tool Tip<ms>Load New Graph<ms><special>new graph file (Python code)<ms>"am_test.graph"<ms><special> <B><Shape>14<B>389<B>221<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>endloadgraph<ms><special>Python variable to hold event data<ms>self.eventData<ms><special> <B><Shape>12<B>378<B>172<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>20<ms><special>Timer label (string literal)<ms>endloadgraph<ms><special> <B><Shape>10<B>377<B>262<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "end the master now"<ms><special> <B><Shape>
Modified: sofaswitch/trunk/callflow/tests/makevoipcall.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/makevoipcall.src (original)
+++ sofaswitch/trunk/callflow/tests/makevoipcall.src Wed Nov 8 22:51:30 2006
@@ -1,3 +1,3 @@
-9<B>248<B>182<B>248,183,308,182<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>2<B>44<B>394<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>12<B>43<B>349<B> extra <special>Tool Tip<ms>Initiate a timer, which causes this to
-end.<ms><special>Timer period (seconds)<ms>0.1<ms><special>Timer label (string literal)<ms>hanguptime<ms><special> <B><Shape>7<B>42<B>303<B> extra <special>Tool Tip<ms>End Call<ms><special>Worker node to activate (python code)<ms>self.voipNode<ms><special> <B><Shape>2<B>307<B>394<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>13<B>284<B>231<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>request sound<ms><special> <B><Shape>1<B>190<B>19<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>15<B>42<B>257<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>"sound"<ms><special>Second SofaSwitch worker (python)<ms>"sound"<ms><special> <B><Shape>5<B>241<B>359<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>(self.voipNode != None) and (self.soundNode != None)<ms><special> <B><Shape>11<B>189<B>117<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from<ms>sound<ms><special>Timer period (seconds)<ms>2<ms><special>Timer label<ms>request sound<ms><special> <B><Shape>10<B>239<B>508<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "dtmf received of ", self.dtmfData<ms><special> <B><Shape>11<B>190<B>68<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from<ms>voip<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>request voip<ms><special> <B><Shape>13<B>190<B>260<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>request voip<ms><special> <B><Shape>9<B>266<B>329<B>308,329,266,359<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>6<B>191<B>209<B> extra <special>Tool Tip<ms>Make Call<ms><special>Worker node to activate (python code)<ms>self.voipNode<ms><special>Call destination (python code)<ms>"h323:h323.voxgratia.org"<ms><special> <B><Shape>9<B>217<B>357<B>217,357,265,359<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>291<B>382<B>291,386,334,382,332,395<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>10<B>43<B>211<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "hangup, as dtmf 9 has been received"<ms><special> <B><Shape>20<B>368<B>626<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>9<B>302<B>486<B>302,486,376,486,380,579<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>5<B>240<B>549<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>self.dtmfData=="9"<ms><special> <B><Shape>15<B>240<B>412<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>self.voipNode<ms><special>Second SofaSwitch worker (python)<ms>self.soundNode<ms><special> <B><Shape>14<B>295<B>185<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>soundREQU<ms><special>Python variable to hold event data<ms>self.soundNode<ms><special> <B><Shape>14<B>202<B>162<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>voipREQ<ms><special>Python variable to hold event data<ms>self.voipNode<ms><special> <B><Shape>2<B>266<B>623<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>9<B>63<B>173<B>262,598,139,599,141,173,63,174,67,213<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>10<B>190<B>308<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Have a new voip node on ", self.voipNode<ms><special> <B><Shape>14<B>367<B>581<B> extra <special>Tool Tip<ms>Catch the timer which, when fired,
-indicates the end of this call<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>hanguptime<ms><special>Python variable to hold event data<ms>self.hanguptime<ms><special> <B><Shape>19<B>267<B>578<B> extra <special>Tool Tip<ms>Send Dtmf<ms><special>Worker node to activate (python code)<ms>self.voipNode<ms><special>DTMF to send to worker node (python code)<ms>self.dtmfData<ms><special> <B><Shape>10<B>282<B>279<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print " have a sound node of ", self.soundNode<ms><special> <B><Shape>14<B>251<B>463<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>DTMF<ms><special>Python variable to hold event data<ms>self.dtmfData<ms><special> <B><Shape>
+13<B>190<B>260<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>requestvoip<ms><special> <B><Shape>13<B>284<B>231<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>requestsound<ms><special> <B><Shape>9<B>302<B>486<B>302,486,376,486,380,579<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>11<B>191<B>109<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from (Python code)<ms>"sound"<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestsound<ms><special>Additional information (Python code)<ms><ms><special> <B><Shape>14<B>251<B>463<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>DTMF<ms><special>Python variable to hold event data<ms>self.dtmfData<ms><special> <B><Shape>2<B>44<B>394<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>9<B>217<B>357<B>217,357,265,359<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>12<B>43<B>349<B> extra <special>Tool Tip<ms>Initiate a timer, which causes this to
+end.<ms><special>Timer period (seconds)<ms>0.1<ms><special>Timer label (string literal)<ms>hanguptime<ms><special> <B><Shape>10<B>190<B>308<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Have a new voip node on ", self.voipNode<ms><special> <B><Shape>9<B>266<B>329<B>308,329,266,359<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>295<B>185<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>soundREQU<ms><special>Python variable to hold event data<ms>self.soundNode<ms><special> <B><Shape>2<B>307<B>394<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>10<B>43<B>211<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "hangup, as dtmf 9 has been received"<ms><special> <B><Shape>1<B>190<B>19<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>10<B>239<B>508<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "dtmf received of ", self.dtmfData<ms><special> <B><Shape>9<B>63<B>173<B>262,598,139,599,141,173,63,174,67,213<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>202<B>162<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>voipREQ<ms><special>Python variable to hold event data<ms>self.voipNode<ms><special> <B><Shape>11<B>191<B>71<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from (Python code)<ms>"voip"<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestvoip<ms><special>Additional information (Python code)<ms><ms><special> <B><Shape>20<B>368<B>626<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>19<B>267<B>578<B> extra <special>Tool Tip<ms>Send Dtmf<ms><special>Worker node to activate (python code)<ms>self.voipNode<ms><special>DTMF to send to worker node (python code)<ms>self.dtmfData<ms><special> <B><Shape>6<B>191<B>209<B> extra <special>Tool Tip<ms>Make Call<ms><special>Worker node to activate (python code)<ms>self.voipNode<ms><special>Call destination (python code)<ms>"h323:h323.voxgratia.org"<ms><special> <B><Shape>9<B>291<B>382<B>291,386,334,382,332,395<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>15<B>240<B>412<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>self.voipNode<ms><special>Second SofaSwitch worker (python)<ms>self.soundNode<ms><special> <B><Shape>15<B>42<B>257<B> extra <special>Tool Tip<ms>Transfer Media<ms><special>First SofaSwitch worker (python)<ms>"sound"<ms><special>Second SofaSwitch worker (python)<ms>"sound"<ms><special> <B><Shape>7<B>42<B>303<B> extra <special>Tool Tip<ms>End Call<ms><special>Worker node to activate (python code)<ms>self.voipNode<ms><special> <B><Shape>2<B>266<B>623<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>9<B>248<B>182<B>248,183,308,182<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>367<B>581<B> extra <special>Tool Tip<ms>Catch the timer which, when fired,
+indicates the end of this call<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>hanguptime<ms><special>Python variable to hold event data<ms>self.hanguptime<ms><special> <B><Shape>5<B>241<B>359<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>(self.voipNode != None) and (self.soundNode != None)<ms><special> <B><Shape>10<B>282<B>279<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print " have a sound node of ", self.soundNode<ms><special> <B><Shape>5<B>240<B>549<B> extra <special>Tool Tip<ms>Conditional<ms><special>Test (Python code)<ms>self.dtmfData=="9"<ms><special> <B><Shape>
Modified: sofaswitch/trunk/callflow/tests/requestnode.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/requestnode.src (original)
+++ sofaswitch/trunk/callflow/tests/requestnode.src Wed Nov 8 22:51:30 2006
@@ -1 +1 @@
-14<B>336<B>282<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>requestnode<ms><special>Python variable to hold event data<ms>self.timerData<ms><special> <B><Shape>1<B>231<B>157<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>2<B>323<B>370<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>13<B>231<B>340<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>requestnode<ms><special> <B><Shape>10<B>231<B>295<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have a new node on ", self.eventData<ms><special> <B><Shape>20<B>245<B>386<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>11<B>231<B>208<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from<ms>voip<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestnode<ms><special> <B><Shape>14<B>244<B>255<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>NEWID<ms><special>Python variable to hold event data<ms>self.eventData<ms><special> <B><Shape>9<B>290<B>279<B>290,280,350,279<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>10<B>323<B>322<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "timer has expired at ", time.asctime(), " from ", self.timerData<ms><special> <B><Shape>
+14<B>244<B>255<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>NEWID<ms><special>Python variable to hold event data<ms>self.eventData<ms><special> <B><Shape>13<B>231<B>340<B> extra <special>Tool Tip<ms>Stop Timer<ms><special>Timer to stop<ms>requestnode<ms><special> <B><Shape>2<B>323<B>370<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>20<B>245<B>386<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>10<B>323<B>322<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "timer has expired at ", time.asctime(), " from ", self.timerData<ms><special> <B><Shape>10<B>231<B>295<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have a new node on ", self.eventData<ms><special> <B><Shape>9<B>290<B>279<B>290,280,350,279<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>1<B>231<B>157<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>11<B>232<B>206<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from (Python code)<ms>"voip"<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>request node<ms><special>Additional information (Python code)<ms><ms><special> <B><Shape>14<B>336<B>282<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>request node<ms><special>Python variable to hold event data<ms>self.timerData<ms><special> <B><Shape>
Modified: sofaswitch/trunk/callflow/tests/simpleeventer.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/simpleeventer.src (original)
+++ sofaswitch/trunk/callflow/tests/simpleeventer.src Wed Nov 8 22:51:30 2006
@@ -1 +1 @@
-10<B>287<B>172<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have received a new node ", self.newNode<ms><special> <B><Shape>20<B>300<B>324<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>2<B>327<B>251<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>10<B>326<B>202<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print " Finished main stream of execution "<ms><special> <B><Shape>9<B>349<B>148<B>349,148,351,201<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>1<B>285<B>27<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>11<B>286<B>78<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from<ms>voip<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestnode<ms><special> <B><Shape>14<B>301<B>125<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>REQ<ms><special>Python variable to hold event data<ms>self.newNode<ms><special> <B><Shape>9<B>312<B>219<B>312,219,312,326<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>
+1<B>285<B>27<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>9<B>312<B>219<B>312,219,312,326<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>10<B>326<B>202<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print " Finished main stream of execution "<ms><special> <B><Shape>11<B>287<B>76<B> extra <special>Tool Tip<ms>Request Node<ms><special>Request node from (Python code)<ms>"voip"<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>requestnode<ms><special>Additional information (Python code)<ms><ms><special> <B><Shape>10<B>287<B>172<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "have received a new node ", self.newNode<ms><special> <B><Shape>2<B>327<B>251<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>14<B>301<B>125<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>REQ<ms><special>Python variable to hold event data<ms>self.newNode<ms><special> <B><Shape>20<B>300<B>324<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>9<B>349<B>148<B>349,148,351,201<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>
Modified: sofaswitch/trunk/callflow/tests/timetest.src
==============================================================================
--- sofaswitch/trunk/callflow/tests/timetest.src (original)
+++ sofaswitch/trunk/callflow/tests/timetest.src Wed Nov 8 22:51:30 2006
@@ -1 +1 @@
-14<B>220<B>256<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>timer2<ms><special>Python variable to hold event data<ms>self.timer2<ms><special> <B><Shape>14<B>347<B>327<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>10<ms><special>Python variable to hold event data<ms>self.timer3<ms><special> <B><Shape>20<B>346<B>417<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>12<B>127<B>125<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>timer1<ms><special> <B><Shape>10<B>123<B>74<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Start ", time.asctime()<ms><special> <B><Shape>10<B>334<B>370<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "t10 ", time.asctime(), " data is ", self.timer3<ms><special> <B><Shape>10<B>126<B>221<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "t1 ", time.asctime(), " data is ", self.timer1Data<ms><special> <B><Shape>12<B>207<B>202<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>2<ms><special>Timer label<ms>timer2<ms><special> <B><Shape>10<B>207<B>305<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "t2 ", time.asctime(), " data is ", self.timer2<ms><special> <B><Shape>9<B>270<B>278<B>270,280,359,278<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>12<B>335<B>275<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>10<ms><special>Timer label (string literal)<ms>t10<ms><special> <B><Shape>9<B>231<B>351<B>232,351,231,422<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>2<B>204<B>419<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>1<B>123<B>26<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>14<B>139<B>179<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>timer1<ms><special>Python variable to hold event data<ms>self.timer1Data<ms><special> <B><Shape>9<B>150<B>271<B>150,271,152,406,223,407,229,423<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>9<B>188<B>201<B>188,201,231,202<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>
+12<B>335<B>275<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>10<ms><special>Timer label (string literal)<ms>t10<ms><special> <B><Shape>10<B>334<B>370<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "t10 ", time.asctime(), " data is ", self.timer3<ms><special> <B><Shape>2<B>204<B>419<B> extra <special>Tool Tip<ms>End Processing<ms><special> <B><Shape>10<B>126<B>221<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "t1 ", time.asctime(), " data is ", self.timer1Data<ms><special> <B><Shape>9<B>231<B>351<B>232,351,231,422<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>12<B>207<B>202<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>2<ms><special>Timer label<ms>timer2<ms><special> <B><Shape>14<B>139<B>179<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>timer1<ms><special>Python variable to hold event data<ms>self.timer1Data<ms><special> <B><Shape>9<B>188<B>201<B>188,201,231,202<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>20<B>346<B>417<B> extra <special>Tool Tip<ms>Death<ms><special> <B><Shape>12<B>127<B>125<B> extra <special>Tool Tip<ms>Timer<ms><special>Timer period (seconds)<ms>1<ms><special>Timer label<ms>timer1<ms><special> <B><Shape>10<B>207<B>305<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "t2 ", time.asctime(), " data is ", self.timer2<ms><special> <B><Shape>10<B>123<B>74<B> extra <special>Tool Tip<ms>Python<ms><special>Python Code<ms>print "Start ", time.asctime()<ms><special> <B><Shape>1<B>123<B>26<B> extra <special>Tool Tip<ms>Start Processing<ms><special> <B><Shape>9<B>150<B>271<B>150,271,152,406,223,407,229,423<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>347<B>327<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>10<ms><special>Python variable to hold event data<ms>self.timer3<ms><special> <B><Shape>9<B>270<B>278<B>270,280,359,278<special>Tool Tip<ms>Join blocks shape<ms><special> <B><Shape>14<B>220<B>256<B> extra <special>Tool Tip<ms>Eventer<ms><special>Event sought (Python code)<ms><ms><special>Event sought (Regular Exp)<ms>timer2<ms><special>Python variable to hold event data<ms>self.timer2<ms><special> <B><Shape>
1
0
Author: derek
Date: Mon Nov 6 22:09:32 2006
New Revision: 160
Modified:
sofaswitch/trunk/callflow/src/callflow.cpp
sofaswitch/trunk/callflow/src/death.cpp
sofaswitch/trunk/callflow/src/requestnode.cpp
sofaswitch/trunk/callflow/src/shapelist.cpp
Log:
get the close down to work correctly (I think)
Get the requesting of a node to work, particularly when passing additional information.
Requesting of a node works when supplied text is a string (with quotes) or
consists of python variables.
Modified: sofaswitch/trunk/callflow/src/callflow.cpp
==============================================================================
--- sofaswitch/trunk/callflow/src/callflow.cpp (original)
+++ sofaswitch/trunk/callflow/src/callflow.cpp Mon Nov 6 22:09:32 2006
@@ -309,7 +309,7 @@
toolBar->AddTool(wxH_FILEOPEN, wxBitmap ( FileOpen_xpm ), wxT("open a file"));
toolBar->AddTool(wxH_FILESAVE, wxBitmap ( FileSave_xpm ), wxT("Save to the current file"));
toolBar->AddTool(wxH_FILESAVE__AS, wxBitmap ( FileSave_As_xpm ), wxT("Save to the file you specify"));
- toolBar->AddTool(wxH_FILEE_XIT, wxBitmap ( FileE_xit_xpm ), wxT(""));
+ toolBar->AddTool(wxH_FILEE_XIT, wxBitmap ( FileE_xit_xpm ), wxT("End this program now"));
toolBar->AddTool(wxH_CONTROLSCOMPILE, wxBitmap ( compile_xpm ), wxT("Compile to code"));
toolBar->AddSeparator() ;
Modified: sofaswitch/trunk/callflow/src/death.cpp
==============================================================================
--- sofaswitch/trunk/callflow/src/death.cpp (original)
+++ sofaswitch/trunk/callflow/src/death.cpp Mon Nov 6 22:09:32 2006
@@ -52,9 +52,10 @@
file.AddLine(" \"\"\"Terminate processing of this flow chart, by closing this particular connection. ");
file.AddLine(" \"\"\" ");
file.AddLine(" if self.isMaster: ");
- file.AddLine(" reactor.disconnectAll() ");
+ file.AddLine(" reactor.stop() ");
file.AddLine(" else: ");
file.AddLine(" self.transport.loseConnection() ");
+ file.AddLine(" self.keepGoing = False ");
file.AddLine(" return None ");
file.AddLine(" ");
Modified: sofaswitch/trunk/callflow/src/requestnode.cpp
==============================================================================
--- sofaswitch/trunk/callflow/src/requestnode.cpp (original)
+++ sofaswitch/trunk/callflow/src/requestnode.cpp Mon Nov 6 22:09:32 2006
@@ -27,7 +27,7 @@
SetSize(newSize);
displayData[displayData.size()] =
- InformationSection(wxT("Request node from (Python code)"), wxT("voip"));
+ InformationSection(wxT("Request node from (Python code)"), wxT("\"voip\""));
displayData[displayData.size()] =
InformationSection(wxT("Timer period (seconds)"), wxT("1"));
@@ -47,7 +47,8 @@
{
DrawCompileError(dc);
dc.SetPen(*wxBLACK_PEN);
-
+ dc.SetBrush(wxBrush(*wxBLACK, wxSOLID));
+
wxPoint p1(m_rect.GetPosition());
wxPoint pA(p1.x + 25, p1.y + 0);
wxPoint pB(p1.x + 25, p1.y + 50);
@@ -79,9 +80,12 @@
file.AddLine(" eName = self.data[a][\"Timer label\"] ");
file.AddLine(" self.pendingEvents[eName] = a ");
file.AddLine(" reactor.callLater(self.data[a][\"Timer period\"], self.timerObjectExpired, eName)");
- file.AddLine(" rhost = self.data[a][\"Request node from (Python code)\"] ");
- file.AddLine(" rhost += \":REQUESTNEWID \" ");
- file.AddLine(" rhost += eval(self.data[a][\"Additional info (Python code)\"]) + \"\\0\" ");
+ file.AddLine(" rhost = self.data[a][\"Request node from\"] ");
+ file.AddLine(" rhost = eval(rhost) + \":REQUESTNEWID \" ");
+ file.AddLine(" additional = self.data[a][\"Additional info\"] ");
+ file.AddLine(" if len(additional) > 0: ");
+ file.AddLine(" rhost += eval(additional) ");
+ file.AddLine(" rhost += \"\\0\" ");
file.AddLine(" self.transport.write(rhost) ");
file.AddLine(" return self.data[a][\"Output\"] ");
file.AddLine("");
Modified: sofaswitch/trunk/callflow/src/shapelist.cpp
==============================================================================
--- sofaswitch/trunk/callflow/src/shapelist.cpp (original)
+++ sofaswitch/trunk/callflow/src/shapelist.cpp Mon Nov 6 22:09:32 2006
@@ -494,15 +494,22 @@
file.AddLine(" queue. On doing this, spark an event to drive queue processing. ");
file.AddLine(" Note that this method can only deal with certain predefined ");
file.AddLine(" types of messages ");
- file.AddLine(" \"\"\" ");
- file.AddLine(" thisMessage = thisMessage.strip() ");
- file.AddLine(" for msg in self.knownNetworkMessages: ");
- file.AddLine(" if thisMessage.find(msg) >= 0: ");
- file.AddLine(" pMsg = str(thisMessage).split(\" \") ");
- file.AddLine(" eName = pMsg[0].replace(\":\",\"\") ");
- file.AddLine(" self.networkEventData(eName, pMsg[1]) ");
- file.AddLine(" ");
- file.AddLine(" ");
+ file.AddLine(" \"\"\" ");
+ file.AddLine(" thisMessage = thisMessage.strip() ");
+ file.AddLine(" for msg in self.knownNetworkMessages: ");
+ file.AddLine(" if thisMessage.find(msg) >= 0: ");
+ file.AddLine(" idx = thisMessage.find(\":\") ");
+ file.AddLine(" msga = thisMessage[0:idx] + thisMessage[(idx+1):] ");
+ file.AddLine(" idx = thisMessage.find(\" \") ");
+ file.AddLine(" if idx < 0: ");
+ file.AddLine(" eName= msga ");
+ file.AddLine(" body=\"\" ");
+ file.AddLine(" else: ");
+ file.AddLine(" eName = msga[0:idx] ");
+ file.AddLine(" body = thisMessage[(idx+1):] ");
+ file.AddLine(" self.networkEventData(eName, body) ");
+ file.AddLine(" ");
+ file.AddLine(" ");
for (int i = 0; i < DndShape::KnownShapes; i++) {
DndShape *thisShape;
if (i == DndShape::None)
1
0
Author: derek
Date: Mon Nov 6 20:10:49 2006
New Revision: 159
Modified:
sofaswitch/trunk/mcu/member.cxx
sofaswitch/trunk/mcu/participant.cxx
sofaswitch/trunk/mcu/participant.h
Log:
Get the closedown of members and participants to work correctly.
Add PTRACE statements.
Modified: sofaswitch/trunk/mcu/member.cxx
==============================================================================
--- sofaswitch/trunk/mcu/member.cxx (original)
+++ sofaswitch/trunk/mcu/member.cxx Mon Nov 6 20:10:49 2006
@@ -302,10 +302,13 @@
}
}
+ PTRACE(3, "Member\tClear now empty partydict");
participants.EmptyParticipantDict();
+
+ PTRACE(3, "Member\tClear now wait for empty partydict");
participants.WaitForTotallyEmpty();
-
+ PTRACE(3, "Member\tClear now do OnReleaed.");
OnReleased();
PTRACE(3, "Member\tOnRelease thread completed for " << *this);
Modified: sofaswitch/trunk/mcu/participant.cxx
==============================================================================
--- sofaswitch/trunk/mcu/participant.cxx (original)
+++ sofaswitch/trunk/mcu/participant.cxx Mon Nov 6 20:10:49 2006
@@ -182,6 +182,7 @@
{
int loops = 0;
while (countEntries > 0) {
+ PTRACE(3, "ParticipantDict:: WaitForTotallyEmpty with a count of " << countEntries);
loops++;
PThread::Sleep(300);
if ((loops % 6) == 0)
Modified: sofaswitch/trunk/mcu/participant.h
==============================================================================
--- sofaswitch/trunk/mcu/participant.h (original)
+++ sofaswitch/trunk/mcu/participant.h Mon Nov 6 20:10:49 2006
@@ -120,7 +120,7 @@
/**A particpant calls this method when the participant is
deleted. This method is used to keep track of the number of
participant instances in this dictionary. */
- void ParticipantDestroyed() { ++countEntries; }
+ void ParticipantDestroyed() { --countEntries; }
/**A participant has gone through it's clear process, and now needs to
advise this dictionary that it has been released */
1
0
Author: derek
Date: Sun Nov 5 23:17:15 2006
New Revision: 158
Modified:
sofaswitch/trunk/mcu/participant.h
Log:
Add comment to one method.
Modified: sofaswitch/trunk/mcu/participant.h
==============================================================================
--- sofaswitch/trunk/mcu/participant.h (original)
+++ sofaswitch/trunk/mcu/participant.h Sun Nov 5 23:17:15 2006
@@ -258,6 +258,11 @@
Remember, this participant instance is from srcMemberId(this) to
dstMemberId;
+
+ This is a one line method, that was not easy to move into this method.
+ -that would have meanth including member.h into this file, and having a
+ weird double reverse include process. Further, we can now nicely put
+ comment generating code into the body of this method.
*/
void DestroyReverseLink();
1
0