diff --git a/modeling/SysMLSec/at_zeuszitmo.xml b/modeling/SysMLSec/at_zeuszitmo.xml index d33361aad38c18554281556729a9c647018cde9c..f0feeacf2eef0a609e426d5569a8bf112a5c424e 100644 --- a/modeling/SysMLSec/at_zeuszitmo.xml +++ b/modeling/SysMLSec/at_zeuszitmo.xml @@ -4,54 +4,54 @@ <Modeling type="AttackTree" nameTab="Attack Trees" > <AttackTreeDiagramPanel name="Attack Tree" minX="10" maxX="1900" minY="10" maxY="1900" zoom="1.0000000000000016" > -<CONNECTOR type="133" id="587" > +<CONNECTOR type="133" id="2" > <cdparam x="645" y="785" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector" value="" /> -<TGConnectingPoint num="0" id="588" /> -<P1 x="645" y="785" id="231" /> +<TGConnectingPoint num="0" id="1" /> +<P1 x="663" y="785" id="231" /> <P2 x="757" y="658" id="167" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="2" > +<CONNECTOR type="133" id="4" > <cdparam x="262" y="1202" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="1" /> -<P1 x="288" y="937" id="53" /> +<TGConnectingPoint num="0" id="3" /> +<P1 x="290" y="937" id="53" /> <P2 x="280" y="906" id="180" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="4" > +<CONNECTOR type="133" id="6" > <cdparam x="415" y="453" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="3" /> -<P1 x="568" y="361" id="98" /> +<TGConnectingPoint num="0" id="5" /> +<P1 x="581" y="361" id="98" /> <P2 x="757" y="623" id="164" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="6" > +<CONNECTOR type="133" id="8" > <cdparam x="1033" y="642" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="5" /> -<P1 x="910" y="416" id="459" /> -<P2 x="943" y="381" id="449" /> +<TGConnectingPoint num="0" id="7" /> +<P1 x="938" y="416" id="459" /> +<P2 x="937" y="382" id="449" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="10" > +<CONNECTOR type="133" id="12" > <cdparam x="1016" y="560" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="2" /> -<TGConnectingPoint num="0" id="8" /> -<TGConnectingPoint num="1" id="9" /> -<P1 x="943" y="346" id="446" /> -<P2 x="915" y="314" id="483" /> +<TGConnectingPoint num="0" id="10" /> +<TGConnectingPoint num="1" id="11" /> +<P1 x="937" y="347" id="446" /> +<P2 x="892" y="314" id="483" /> <Point x="931" y="331" /> <AutomaticDrawing data="true" /> -</CONNECTOR><SUBCOMPONENT type="-1" id="7" > -<father id="10" num="0" /> +</CONNECTOR><SUBCOMPONENT type="-1" id="9" > +<father id="12" num="0" /> <cdparam x="931" y="331" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> @@ -59,120 +59,120 @@ <infoparam name="point " value="null" /> </SUBCOMPONENT> -<CONNECTOR type="133" id="12" > +<CONNECTOR type="133" id="14" > <cdparam x="916" y="476" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="11" /> -<P1 x="884" y="279" id="472" /> -<P2 x="831" y="250" id="423" /> +<TGConnectingPoint num="0" id="13" /> +<P1 x="861" y="279" id="472" /> +<P2 x="821" y="250" id="423" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="14" > +<CONNECTOR type="133" id="16" > <cdparam x="831" y="1116" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="1" /> -<TGConnectingPoint num="0" id="13" /> -<P1 x="659" y="840" id="192" /> +<TGConnectingPoint num="0" id="15" /> +<P1 x="663" y="840" id="192" /> <P2 x="726" y="814" id="161" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="16" > +<CONNECTOR type="133" id="18" > <cdparam x="1122" y="893" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="15" /> -<P1 x="903" y="783" id="297" /> +<TGConnectingPoint num="0" id="17" /> +<P1 x="893" y="783" id="297" /> <P2 x="917" y="682" id="148" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="18" > +<CONNECTOR type="133" id="20" > <cdparam x="1138" y="973" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="17" /> +<TGConnectingPoint num="0" id="19" /> <P1 x="819" y="805" id="160" /> -<P2 x="852" y="800" id="294" /> +<P2 x="838" y="800" id="294" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="20" > +<CONNECTOR type="133" id="22" > <cdparam x="1098" y="980" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="19" /> +<TGConnectingPoint num="0" id="21" /> <P1 x="948" y="647" id="138" /> -<P2 x="950" y="613" id="283" /> +<P2 x="955" y="613" id="283" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="22" > +<CONNECTOR type="133" id="24" > <cdparam x="1239" y="878" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="21" /> -<P1 x="972" y="720" id="272" /> +<TGConnectingPoint num="0" id="23" /> +<P1 x="983" y="720" id="272" /> <P2 x="979" y="682" id="149" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="24" > +<CONNECTOR type="133" id="26" > <cdparam x="484" y="806" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="0" /> -<TGConnectingPoint num="0" id="23" /> +<TGConnectingPoint num="0" id="25" /> <P1 x="788" y="658" id="175" /> <P2 x="788" y="779" id="156" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="26" > +<CONNECTOR type="133" id="28" > <cdparam x="919" y="515" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="1" /> -<TGConnectingPoint num="0" id="25" /> -<P1 x="731" y="347" id="437" /> -<P2 x="853" y="314" id="482" /> +<TGConnectingPoint num="0" id="27" /> +<P1 x="711" y="347" id="437" /> +<P2 x="830" y="314" id="482" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="28" > +<CONNECTOR type="133" id="30" > <cdparam x="1010" y="578" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="0" /> -<TGConnectingPoint num="0" id="27" /> -<P1 x="821" y="435" id="487" /> -<P2 x="849" y="433" id="460" /> +<TGConnectingPoint num="0" id="29" /> +<P1 x="805" y="435" id="487" /> +<P2 x="877" y="433" id="460" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="30" > +<CONNECTOR type="133" id="32" > <cdparam x="296" y="769" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="29" /> -<P1 x="283" y="643" id="387" /> +<TGConnectingPoint num="0" id="31" /> +<P1 x="289" y="643" id="387" /> <P2 x="491" y="589" id="531" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="32" > +<CONNECTOR type="133" id="34" > <cdparam x="1291" y="918" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="1" /> -<TGConnectingPoint num="0" id="31" /> -<P1 x="950" y="578" id="280" /> -<P2 x="910" y="451" id="462" /> +<TGConnectingPoint num="0" id="33" /> +<P1 x="955" y="578" id="280" /> +<P2 x="938" y="451" id="462" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="34" > +<CONNECTOR type="133" id="36" > <cdparam x="540" y="630" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="33" /> -<P1 x="641" y="563" id="528" /> -<P2 x="699" y="373" id="441" /> +<TGConnectingPoint num="0" id="35" /> +<P1 x="653" y="563" id="528" /> +<P2 x="676" y="373" id="441" /> <AutomaticDrawing data="true" /> </CONNECTOR> -<CONNECTOR type="133" id="36" > +<CONNECTOR type="133" id="38" > <cdparam x="622" y="860" /> <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> -<TGConnectingPoint num="0" id="35" /> -<P1 x="661" y="648" id="127" /> +<TGConnectingPoint num="0" id="37" /> +<P1 x="671" y="648" id="127" /> <P2 x="696" y="649" id="172" /> <AutomaticDrawing data="true" /> </CONNECTOR> @@ -181,7 +181,7 @@ <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> <TGConnectingPoint num="0" id="39" /> -<P1 x="587" y="733" id="218" /> +<P1 x="600" y="733" id="218" /> <P2 x="726" y="658" id="174" /> <AutomaticDrawing data="true" /> </CONNECTOR> @@ -199,7 +199,7 @@ <sizeparam width="0" height="0" minWidth="0" minHeight="0" maxWidth="1000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <infoparam name="connector from TGComponent to TGComponent" value="" /> <TGConnectingPoint num="0" id="43" /> -<P1 x="241" y="830" id="334" /> +<P1 x="244" y="830" id="334" /> <P2 x="249" y="871" id="181" /> <AutomaticDrawing data="true" /> </CONNECTOR> @@ -218,7 +218,7 @@ <infoparam name="connector from TGComponent to TGComponent" value="" /> <TGConnectingPoint num="0" id="47" /> <P1 x="249" y="747" id="344" /> -<P2 x="255" y="678" id="385" /> +<P2 x="259" y="678" id="385" /> <AutomaticDrawing data="true" /> </CONNECTOR> <COMPONENT type="1400" id="86" > @@ -255,10 +255,10 @@ <SUBCOMPONENT type="1401" id="61" > <father id="86" num="0" /> <cdparam x="256" y="937" /> -<sizeparam width="130" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="137" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="117" minY="0" maxY="48" /> +<cdrectangleparam minX="0" maxX="110" minY="0" maxY="48" /> <infoparam name="TGComponent" value="ExploitVulnerability" /> <TGConnectingPoint num="0" id="49" /> <TGConnectingPoint num="1" id="50" /> @@ -311,10 +311,10 @@ <SUBCOMPONENT type="1401" id="99" > <father id="124" num="0" /> <cdparam x="439" y="326" /> -<sizeparam width="173" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="190" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="74" minY="0" maxY="73" /> +<cdrectangleparam minX="0" maxX="57" minY="0" maxY="73" /> <infoparam name="TGComponent" value="GenerateFakeBankWebsite" /> <TGConnectingPoint num="0" id="87" /> <TGConnectingPoint num="1" id="88" /> @@ -335,7 +335,7 @@ <COMPONENT type="1401" id="137" > <cdparam x="491" y="631" /> -<sizeparam width="170" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="180" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> <cdrectangleparam minX="10" maxX="1901" minY="10" maxY="1901" /> @@ -399,7 +399,7 @@ <TGConnectingPoint num="10" id="161" /> <TGConnectingPoint num="11" id="162" /> <extraparam> -<info equation="t(a1)<t(a2)" /> +<info equation="" /> </extraparam> </COMPONENT> @@ -482,11 +482,11 @@ </COMPONENT> <SUBCOMPONENT type="1401" id="202" > <father id="266" num="0" /> -<cdparam x="361" y="823" /> -<sizeparam width="298" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="340" y="823" /> +<sizeparam width="323" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="5" minY="0" maxY="205" /> +<cdrectangleparam minX="0" maxX="-20" minY="0" maxY="205" /> <infoparam name="TGComponent" value="RequestUserToInstallMobileFakeBankApplication" /> <TGConnectingPoint num="0" id="190" /> <TGConnectingPoint num="1" id="191" /> @@ -507,10 +507,10 @@ <SUBCOMPONENT type="1401" id="215" > <father id="266" num="1" /> <cdparam x="395" y="871" /> -<sizeparam width="127" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="134" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="176" minY="0" maxY="205" /> +<cdrectangleparam minX="0" maxX="169" minY="0" maxY="205" /> <infoparam name="TGComponent" value="ExploitVunerability" /> <TGConnectingPoint num="0" id="203" /> <TGConnectingPoint num="1" id="204" /> @@ -531,10 +531,10 @@ <SUBCOMPONENT type="1401" id="228" > <father id="266" num="2" /> <cdparam x="448" y="716" /> -<sizeparam width="139" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="152" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="164" minY="0" maxY="205" /> +<cdrectangleparam minX="0" maxX="151" minY="0" maxY="205" /> <infoparam name="TGComponent" value="InstallMaliciousPlugin" /> <TGConnectingPoint num="0" id="216" /> <TGConnectingPoint num="1" id="217" /> @@ -554,11 +554,11 @@ </SUBCOMPONENT> <SUBCOMPONENT type="1401" id="241" > <father id="266" num="3" /> -<cdparam x="371" y="768" /> -<sizeparam width="274" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="370" y="768" /> +<sizeparam width="293" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="29" minY="0" maxY="205" /> +<cdrectangleparam minX="0" maxX="10" minY="0" maxY="205" /> <infoparam name="TGComponent" value="RedirectHTTPRequestFromBankToFakeBank" /> <TGConnectingPoint num="0" id="229" /> <TGConnectingPoint num="1" id="230" /> @@ -611,10 +611,10 @@ <SUBCOMPONENT type="1401" id="279" > <father id="330" num="0" /> <cdparam x="873" y="720" /> -<sizeparam width="132" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="147" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="92" minY="0" maxY="296" /> +<cdrectangleparam minX="0" maxX="77" minY="0" maxY="296" /> <infoparam name="TGComponent" value="SilentlyInterceptSMS" /> <TGConnectingPoint num="0" id="267" /> <TGConnectingPoint num="1" id="268" /> @@ -635,10 +635,10 @@ <SUBCOMPONENT type="1401" id="292" > <father id="330" num="1" /> <cdparam x="871" y="578" /> -<sizeparam width="159" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="169" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="65" minY="0" maxY="296" /> +<cdrectangleparam minX="0" maxX="55" minY="0" maxY="296" /> <infoparam name="TGComponent" value="RetrieveTransactionTAN" /> <TGConnectingPoint num="0" id="280" /> <TGConnectingPoint num="1" id="281" /> @@ -658,11 +658,11 @@ </SUBCOMPONENT> <SUBCOMPONENT type="1401" id="305" > <father id="330" num="2" /> -<cdparam x="852" y="783" /> -<sizeparam width="204" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="838" y="783" /> +<sizeparam width="223" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="20" minY="0" maxY="296" /> +<cdrectangleparam minX="0" maxX="1" minY="0" maxY="296" /> <infoparam name="TGComponent" value="UserInstallsFakeBankApplication" /> <TGConnectingPoint num="0" id="293" /> <TGConnectingPoint num="1" id="294" /> @@ -715,10 +715,10 @@ <SUBCOMPONENT type="1401" id="343" > <father id="381" num="0" /> <cdparam x="176" y="795" /> -<sizeparam width="130" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="137" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="14" minY="0" maxY="93" /> +<cdrectangleparam minX="0" maxX="7" minY="0" maxY="93" /> <infoparam name="TGComponent" value="ExploitVulnerability" /> <TGConnectingPoint num="0" id="331" /> <TGConnectingPoint num="1" id="332" /> @@ -795,10 +795,10 @@ <SUBCOMPONENT type="1401" id="394" > <father id="419" num="0" /> <cdparam x="199" y="643" /> -<sizeparam width="113" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="121" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="390" minY="0" maxY="383" /> +<cdrectangleparam minX="0" maxX="382" minY="0" maxY="383" /> <infoparam name="TGComponent" value="InstallKeyLogger" /> <TGConnectingPoint num="0" id="382" /> <TGConnectingPoint num="1" id="383" /> @@ -818,8 +818,8 @@ </SUBCOMPONENT> <COMPONENT type="1400" id="522" > -<cdparam x="688" y="176" /> -<sizeparam width="368" height="299" minWidth="5" minHeight="2" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="665" y="176" /> +<sizeparam width="391" height="299" minWidth="5" minHeight="2" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <cdrectangleparam minX="10" maxX="1901" minY="10" maxY="1901" /> <infoparam name="Block5" value="AttackerPC" /> @@ -850,11 +850,11 @@ </COMPONENT> <SUBCOMPONENT type="1401" id="432" > <father id="522" num="0" /> -<cdparam x="691" y="215" /> -<sizeparam width="280" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="668" y="215" /> +<sizeparam width="306" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="88" minY="0" maxY="264" /> +<cdrectangleparam minX="0" maxX="85" minY="0" maxY="264" /> <infoparam name="TGComponent" value="IllegalBankAccountTransactionBasedOnToken" /> <TGConnectingPoint num="0" id="420" /> <TGConnectingPoint num="1" id="421" /> @@ -874,11 +874,11 @@ </SUBCOMPONENT> <SUBCOMPONENT type="1401" id="445" > <father id="522" num="1" /> -<cdparam x="699" y="347" /> -<sizeparam width="129" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="676" y="347" /> +<sizeparam width="141" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="239" minY="0" maxY="264" /> +<cdrectangleparam minX="0" maxX="250" minY="0" maxY="264" /> <infoparam name="TGComponent" value="LogOnBankAccount" /> <TGConnectingPoint num="0" id="433" /> <TGConnectingPoint num="1" id="434" /> @@ -898,11 +898,11 @@ </SUBCOMPONENT> <SUBCOMPONENT type="1401" id="458" > <father id="522" num="2" /> -<cdparam x="834" y="346" /> -<sizeparam width="218" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="818" y="347" /> +<sizeparam width="238" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="150" minY="0" maxY="264" /> +<cdrectangleparam minX="0" maxX="153" minY="0" maxY="264" /> <infoparam name="TGComponent" value="PerformTokenBasedAuthentication" /> <TGConnectingPoint num="0" id="446" /> <TGConnectingPoint num="1" id="447" /> @@ -916,13 +916,14 @@ <TGConnectingPoint num="9" id="455" /> <TGConnectingPoint num="10" id="456" /> <TGConnectingPoint num="11" id="457" /> +<latencyCheck /> <extraparam> <info description="blah blah blah" root="false" /> </extraparam> </SUBCOMPONENT> <SUBCOMPONENT type="1402" id="471" > <father id="522" num="3" /> -<cdparam x="849" y="416" /> +<cdparam x="877" y="416" /> <sizeparam width="123" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <cdrectangleparam minX="0" maxX="245" minY="0" maxY="264" /> @@ -945,7 +946,7 @@ </SUBCOMPONENT> <SUBCOMPONENT type="1402" id="484" > <father id="522" num="4" /> -<cdparam x="823" y="279" /> +<cdparam x="800" y="279" /> <sizeparam width="123" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <cdrectangleparam minX="0" maxX="245" minY="0" maxY="264" /> @@ -963,16 +964,16 @@ <TGConnectingPoint num="10" id="482" /> <TGConnectingPoint num="11" id="483" /> <extraparam> -<info equation="t(a1)<t(a2)" /> +<info equation="" /> </extraparam> </SUBCOMPONENT> <SUBCOMPONENT type="1401" id="497" > <father id="522" num="5" /> -<cdparam x="697" y="418" /> -<sizeparam width="124" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<cdparam x="674" y="418" /> +<sizeparam width="131" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="244" minY="0" maxY="264" /> +<cdrectangleparam minX="0" maxX="260" minY="0" maxY="264" /> <infoparam name="TGComponent" value="SendTANToServer" /> <TGConnectingPoint num="0" id="485" /> <TGConnectingPoint num="1" id="486" /> @@ -1025,10 +1026,10 @@ <SUBCOMPONENT type="1401" id="535" > <father id="560" num="0" /> <cdparam x="491" y="563" /> -<sizeparam width="201" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> +<sizeparam width="217" height="35" minWidth="100" minHeight="0" maxWidth="2000" maxHeight="2000" minDesiredWidth="0" minDesiredHeight="0" /> <hidden value="false" /> <enabled value="true" /> -<cdrectangleparam minX="0" maxX="711" minY="0" maxY="493" /> +<cdrectangleparam minX="0" maxX="695" minY="0" maxY="493" /> <infoparam name="TGComponent" value="RetrieveUserLoginAndPassword" /> <TGConnectingPoint num="0" id="523" /> <TGConnectingPoint num="1" id="524" /> diff --git a/src/myutil/BoolExpressionEvaluator.java b/src/myutil/BoolExpressionEvaluator.java index 9d149d7ebdf9cc0476d9a5c1919978e1040b18e8..81fde0d221a638ae1ee9feaf4fd52541e8b6aaa1 100755 --- a/src/myutil/BoolExpressionEvaluator.java +++ b/src/myutil/BoolExpressionEvaluator.java @@ -219,6 +219,8 @@ public class BoolExpressionEvaluator { } } + TraceManager.addDev("**************** Considering targetF=" + targetF); + if (targetF == null) { newE.left = top; top.father = newE; @@ -232,8 +234,9 @@ public class BoolExpressionEvaluator { targetF.father = newE; return newE; } else { - newE.right = targetF.right; - targetF.right = newE; + TraceManager.addDev("Unaryoperator"); + newE.left = targetF.left; + targetF.left = newE; newE.father = targetF; return newE; } @@ -1566,7 +1569,7 @@ public class BoolExpressionEvaluator { ID = 0; IntBoolRes newElt; - TraceManager.addDev("Dealing with token=" + token + " with current=" + current); + TraceManager.addDev("<><><><><><> Dealing with token:" + token); char c1 = token.charAt(0); diff --git a/src/ui/ADDPanel.java b/src/ui/ADDPanel.java index e4f99484a478d62ffc879a26fc6ab3ee5891b9f4..2007521124e7343687ca3497631e76f741136c18 100755 --- a/src/ui/ADDPanel.java +++ b/src/ui/ADDPanel.java @@ -98,8 +98,11 @@ public class ADDPanel extends TURTLEPanel { return true; } - public String saveHeaderInXml() { - return "<Modeling type=\"ADD\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"ADD\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"ADD\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/AnalysisPanel.java b/src/ui/AnalysisPanel.java index e1c337f714ab5ad7a3bc0bc427b5e7ba6cf6f9d2..d8400451a4bfca79c326eb9f02ee51c7ada44231 100755 --- a/src/ui/AnalysisPanel.java +++ b/src/ui/AnalysisPanel.java @@ -245,8 +245,11 @@ public class AnalysisPanel extends TURTLEPanel { }*/ - public String saveHeaderInXml() { - return "<Modeling type=\"Analysis\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Analysis\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Analysis\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/AttackTreePanel.java b/src/ui/AttackTreePanel.java index 3825bfe93e7a82ad3dff9d2a64a1267267dbbe44..8243a898e81d21e1735c4c3722282a8dd6eeb545 100755 --- a/src/ui/AttackTreePanel.java +++ b/src/ui/AttackTreePanel.java @@ -112,9 +112,11 @@ public class AttackTreePanel extends TURTLEPanel { return true; } - - public String saveHeaderInXml() { - return "<Modeling type=\"AttackTree\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"AttackTree\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"AttackTree\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/AvatarAnalysisPanel.java b/src/ui/AvatarAnalysisPanel.java index a286eb445bc674f285daf58ab507f93357b01af2..d71622d6469a52b51f319a0ccfe71f6730293087 100755 --- a/src/ui/AvatarAnalysisPanel.java +++ b/src/ui/AvatarAnalysisPanel.java @@ -199,8 +199,12 @@ public class AvatarAnalysisPanel extends TURTLEPanel { } - public String saveHeaderInXml() { - return "<Modeling type=\"Avatar Analysis\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Avatar Analysis\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Avatar Analysis\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; + } public String saveTailInXml() { diff --git a/src/ui/AvatarDesignPanel.java b/src/ui/AvatarDesignPanel.java index 825fbd3ac8daa88e0da77238ca4238a47da5b443..daa5a61fb0fae5c60eb45c9e1dbd8fcfad4b85b7 100644 --- a/src/ui/AvatarDesignPanel.java +++ b/src/ui/AvatarDesignPanel.java @@ -202,9 +202,12 @@ public class AvatarDesignPanel extends TURTLEPanel { public LinkedList<String> getAllTimers(String _name) { return abdp.getAllTimersOfBlock(_name); } - - public String saveHeaderInXml() { - return "<Modeling type=\"AVATAR Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"AVATAR Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"AVATAR Design\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/AvatarMADsPanel.java b/src/ui/AvatarMADsPanel.java index 3be35dd185385be7ffb2ceaf2717eed5195f124d..f3591db9c5a0ec5444460020142d60e606008b6d 100644 --- a/src/ui/AvatarMADsPanel.java +++ b/src/ui/AvatarMADsPanel.java @@ -132,9 +132,12 @@ public class AvatarMADsPanel extends TURTLEPanel { } - - public String saveHeaderInXml() { - return "<Modeling type=\"Avatar MAD\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Avatar MAD\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Avatar MAD\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/AvatarMethodologyPanel.java b/src/ui/AvatarMethodologyPanel.java index ec1eb3e178d828792f0d0dbcc0e27b1a9a75cfff..b1de004ee3c4512b0d6e99b56240945d1ef2510f 100755 --- a/src/ui/AvatarMethodologyPanel.java +++ b/src/ui/AvatarMethodologyPanel.java @@ -1,48 +1,48 @@ /**Copyright or (C) or Copr. GET / ENST, Telecom-Paris, Ludovic Apvrille -ludovic.apvrille AT enst.fr - -This software is a computer program whose purpose is to allow the -edition of TURTLE analysis, design and deployment diagrams, to -allow the generation of RT-LOTOS or Java code from this diagram, -and at last to allow the analysis of formal validation traces -obtained from external tools, e.g. RTL from LAAS-CNRS and CADP -from INRIA Rhone-Alpes. - -This software is governed by the CeCILL license under French law and -abiding by the rules of distribution of free software. You can use, -modify and/ or redistribute the software under the terms of the CeCILL -license as circulated by CEA, CNRS and INRIA at the following URL -"http://www.cecill.info". - -As a counterpart to the access to the source code and rights to copy, -modify and redistribute granted by the license, users are provided only -with a limited warranty and the software's author, the holder of the -economic rights, and the successive licensors have only limited -liability. - -In this respect, the user's attention is drawn to the risks associated -with loading, using, modifying and/or developing or reproducing the -software by the user in light of its specific status of free software, -that may mean that it is complicated to manipulate, and that also -therefore means that it is reserved for developers and experienced -professionals having in-depth computer knowledge. Users are therefore -encouraged to load and test the software's suitability as regards their -requirements in conditions enabling the security of their systems and/or -data to be ensured and, more generally, to use and operate it in the -same conditions as regards security. - -The fact that you are presently reading this means that you have had -knowledge of the CeCILL license and that you accept its terms. - -/** - * Class AvatarMethodologyPanel - * Managenemt of the avatar methodology panels - * Creation: 27/08/2014 - * @version 1.1 27/08/2014 - * @author Ludovic APVRILLE - * @see MainGUI - */ + ludovic.apvrille AT enst.fr + + This software is a computer program whose purpose is to allow the + edition of TURTLE analysis, design and deployment diagrams, to + allow the generation of RT-LOTOS or Java code from this diagram, + and at last to allow the analysis of formal validation traces + obtained from external tools, e.g. RTL from LAAS-CNRS and CADP + from INRIA Rhone-Alpes. + + This software is governed by the CeCILL license under French law and + abiding by the rules of distribution of free software. You can use, + modify and/ or redistribute the software under the terms of the CeCILL + license as circulated by CEA, CNRS and INRIA at the following URL + "http://www.cecill.info". + + As a counterpart to the access to the source code and rights to copy, + modify and redistribute granted by the license, users are provided only + with a limited warranty and the software's author, the holder of the + economic rights, and the successive licensors have only limited + liability. + + In this respect, the user's attention is drawn to the risks associated + with loading, using, modifying and/or developing or reproducing the + software by the user in light of its specific status of free software, + that may mean that it is complicated to manipulate, and that also + therefore means that it is reserved for developers and experienced + professionals having in-depth computer knowledge. Users are therefore + encouraged to load and test the software's suitability as regards their + requirements in conditions enabling the security of their systems and/or + data to be ensured and, more generally, to use and operate it in the + same conditions as regards security. + + The fact that you are presently reading this means that you have had + knowledge of the CeCILL license and that you accept its terms. + + /** + * Class AvatarMethodologyPanel + * Managenemt of the avatar methodology panels + * Creation: 27/08/2014 + * @version 1.1 27/08/2014 + * @author Ludovic APVRILLE + * @see MainGUI + */ package ui; @@ -56,174 +56,176 @@ import java.util.*; public class AvatarMethodologyPanel extends TURTLEPanel { public AvatarMethodologyDiagramPanel dmd; - + public AvatarMethodologyPanel(MainGUI _mgui) { super(_mgui); - + tabbedPane = new JTabbedPane(); - UIManager.put("TabbedPane.tabAreaBackground", _mgui.BACK_COLOR); - UIManager.put("TabbedPane.selected", _mgui.BACK_COLOR); - SwingUtilities.updateComponentTreeUI(tabbedPane); - //tabbedPane.setOpaque(true); - + UIManager.put("TabbedPane.tabAreaBackground", _mgui.BACK_COLOR); + UIManager.put("TabbedPane.selected", _mgui.BACK_COLOR); + SwingUtilities.updateComponentTreeUI(tabbedPane); + //tabbedPane.setOpaque(true); + cl = new ChangeListener() { - public void stateChanged(ChangeEvent e){ - mgui.paneDiplodocusMethodologyAction(e); - } - }; + public void stateChanged(ChangeEvent e){ + mgui.paneDiplodocusMethodologyAction(e); + } + }; tabbedPane.addChangeListener(cl); tabbedPane.addMouseListener(new TURTLEPanelPopupListener(this, mgui)); - + } - + // Put the methodology public void initElements() { - TGComponent tgc1 = dmd.addComponent(150, 100, TGComponentManager.AVATARMETHODOLOGY_REF_ASSUMPTIONS, false); - TGComponent tgc2 = dmd.addComponent(250, 200, TGComponentManager.AVATARMETHODOLOGY_REF_REQUIREMENT, false); - TGComponent tgc3 = dmd.addComponent(350, 300, TGComponentManager.AVATARMETHODOLOGY_REF_ANALYSIS, false); - TGComponent tgc4 = dmd.addComponent(450, 400, TGComponentManager.AVATARMETHODOLOGY_REF_DESIGN, false); - TGComponent tgc5 = dmd.addComponent(550, 500, TGComponentManager.AVATARMETHODOLOGY_REF_PROTOTYPE, false); - TGComponent tgc6 = dmd.addComponent(200, 400, TGComponentManager.AVATARMETHODOLOGY_REF_PROPERTIES, false); - - - //Connectors - - // Assumptions -> reqs - TGConnectingPoint p1, p2; - p1 = tgc1.getTGConnectingPointAtIndex(0); - p2 = tgc2.getTGConnectingPointAtIndex(0); - Vector listPoint = new Vector(); - Point p = new Point(210, 235); - listPoint.add(p); - TGConnector tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); - p1.setFree(false); - p2.setFree(false); - dmd.getComponentList().add(0, tgco); - - // Reqs -> Analysis - p1 = tgc2.getTGConnectingPointAtIndex(1); - p2 = tgc3.getTGConnectingPointAtIndex(0); - listPoint = new Vector(); - p = new Point(310, 335); - listPoint.add(p); - tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); - p1.setFree(false); - p2.setFree(false); - dmd.getComponentList().add(0, tgco); - - // Analysis -> Design - p1 = tgc3.getTGConnectingPointAtIndex(1); - p2 = tgc4.getTGConnectingPointAtIndex(0); - listPoint = new Vector(); - p = new Point(410, 435); - listPoint.add(p); - tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); - p1.setFree(false); - p2.setFree(false); - dmd.getComponentList().add(0, tgco); - - // Design -> Prototyping - p1 = tgc4.getTGConnectingPointAtIndex(1); - p2 = tgc5.getTGConnectingPointAtIndex(0); - listPoint = new Vector(); - p = new Point(510, 535); - listPoint.add(p); - tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); - p1.setFree(false); - p2.setFree(false); - dmd.getComponentList().add(0, tgco); - - // Reqs -> Prop - p1 = tgc2.getTGConnectingPointAtIndex(2); - p2 = tgc6.getTGConnectingPointAtIndex(0); - listPoint = new Vector(); - tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); - p1.setFree(false); - p2.setFree(false); - dmd.getComponentList().add(0, tgco); - - + TGComponent tgc1 = dmd.addComponent(150, 100, TGComponentManager.AVATARMETHODOLOGY_REF_ASSUMPTIONS, false); + TGComponent tgc2 = dmd.addComponent(250, 200, TGComponentManager.AVATARMETHODOLOGY_REF_REQUIREMENT, false); + TGComponent tgc3 = dmd.addComponent(350, 300, TGComponentManager.AVATARMETHODOLOGY_REF_ANALYSIS, false); + TGComponent tgc4 = dmd.addComponent(450, 400, TGComponentManager.AVATARMETHODOLOGY_REF_DESIGN, false); + TGComponent tgc5 = dmd.addComponent(550, 500, TGComponentManager.AVATARMETHODOLOGY_REF_PROTOTYPE, false); + TGComponent tgc6 = dmd.addComponent(200, 400, TGComponentManager.AVATARMETHODOLOGY_REF_PROPERTIES, false); + + + //Connectors + + // Assumptions -> reqs + TGConnectingPoint p1, p2; + p1 = tgc1.getTGConnectingPointAtIndex(0); + p2 = tgc2.getTGConnectingPointAtIndex(0); + Vector listPoint = new Vector(); + Point p = new Point(210, 235); + listPoint.add(p); + TGConnector tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); + p1.setFree(false); + p2.setFree(false); + dmd.getComponentList().add(0, tgco); + + // Reqs -> Analysis + p1 = tgc2.getTGConnectingPointAtIndex(1); + p2 = tgc3.getTGConnectingPointAtIndex(0); + listPoint = new Vector(); + p = new Point(310, 335); + listPoint.add(p); + tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); + p1.setFree(false); + p2.setFree(false); + dmd.getComponentList().add(0, tgco); + + // Analysis -> Design + p1 = tgc3.getTGConnectingPointAtIndex(1); + p2 = tgc4.getTGConnectingPointAtIndex(0); + listPoint = new Vector(); + p = new Point(410, 435); + listPoint.add(p); + tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); + p1.setFree(false); + p2.setFree(false); + dmd.getComponentList().add(0, tgco); + + // Design -> Prototyping + p1 = tgc4.getTGConnectingPointAtIndex(1); + p2 = tgc5.getTGConnectingPointAtIndex(0); + listPoint = new Vector(); + p = new Point(510, 535); + listPoint.add(p); + tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); + p1.setFree(false); + p2.setFree(false); + dmd.getComponentList().add(0, tgco); + + // Reqs -> Prop + p1 = tgc2.getTGConnectingPointAtIndex(2); + p2 = tgc6.getTGConnectingPointAtIndex(0); + listPoint = new Vector(); + tgco = TGComponentManager.addConnector(p1.getX(), p1.getY(), TGComponentManager.AVATARMETHODOLOGY_CONNECTOR, dmd, p1, p2, listPoint); + p1.setFree(false); + p2.setFree(false); + dmd.getComponentList().add(0, tgco); + + } - + public void init() { - init("Avatar methodology"); + init("Avatar methodology"); } - + public void init(String name) { addAvatarMethodologyDiagram(name); - + // Requirement Diagram toolbar //addRequirementDiagram("Requirement Diagram"); - + //jsp.setVisible(true); } - + public boolean addAvatarMethodologyDiagram(String s) { AvatarMethodologyDiagramToolbar dmdt = new AvatarMethodologyDiagramToolbar(mgui); toolbars.add(dmdt); - + toolBarPanel = new JPanel(); - //toolBarPanel.setBackground(Color.red); + //toolBarPanel.setBackground(Color.red); toolBarPanel.setLayout(new BorderLayout()); - //toolBarPanel.setBackground(ColorManager.MainTabbedPaneSelect); - - //Class diagram + //toolBarPanel.setBackground(ColorManager.MainTabbedPaneSelect); + + //Class diagram dmd = new AvatarMethodologyDiagramPanel(mgui, dmdt); dmd.setName(s); dmd.tp = this; tdp = dmd; panels.add(dmd); - JScrollDiagramPanel jsp = new JScrollDiagramPanel(dmd); + JScrollDiagramPanel jsp = new JScrollDiagramPanel(dmd); dmd.jsp = jsp; jsp.setWheelScrollingEnabled(true); jsp.getVerticalScrollBar().setUnitIncrement(mgui.INCREMENT); toolBarPanel.add(dmdt, BorderLayout.NORTH); toolBarPanel.add(jsp, BorderLayout.CENTER); tabbedPane.addTab(s, IconManager.imgic99, toolBarPanel, "Opens avatar methodology"); - tabbedPane.setSelectedIndex(0); + tabbedPane.setSelectedIndex(0); JPanel toolBarPanel = new JPanel(); toolBarPanel.setLayout(new BorderLayout()); - + //TGComponent tgc = TGComponentManager.addComponent(100, 100, TGComponentManager.DIPLODODUSMETHODOLOGY_REF_APPLICATION, dmd); mgui.changeMade(dmd, TDiagramPanel.NEW_COMPONENT); - + return true; } - - - public String saveHeaderInXml() { - return "<Modeling type=\"Avatar Methodology\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Avatar Methodology\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Avatar Methodology\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } - + public String saveTailInXml() { return "</Modeling>\n\n\n"; } - + public String toString() { return mgui.getTitleAt(this) + " (Avatar Methodology)"; } - + public boolean removeEnabled(int index) { if (panels.size() > 1) { return true; } return false; } - + public boolean renameEnabled(int index) { if (panels.size() == 0) { return false; } - - + + return true; } - - public boolean isAvatarMethodologyEnabled() { - return true; - } - -} \ No newline at end of file + public boolean isAvatarMethodologyEnabled() { + return true; + } + + +} diff --git a/src/ui/AvatarRequirementPanel.java b/src/ui/AvatarRequirementPanel.java index 74d76a28a627078d439a7976190dd105f0e20c80..7bdd7d2f82de589ddad5b66810bf1874a1bae47e 100755 --- a/src/ui/AvatarRequirementPanel.java +++ b/src/ui/AvatarRequirementPanel.java @@ -145,9 +145,11 @@ public class AvatarRequirementPanel extends TURTLEPanel { return true; } - - public String saveHeaderInXml() { - return "<Modeling type=\"Avatar Requirement\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Avatar Requirement\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Avatar Requirement\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/DeploymentPanel.java b/src/ui/DeploymentPanel.java index 71998c44abd1e11c9f40898b705a9ad925a917e0..5da70b25339270387a19248a3de6d3615450ef67 100755 --- a/src/ui/DeploymentPanel.java +++ b/src/ui/DeploymentPanel.java @@ -97,8 +97,12 @@ public class DeploymentPanel extends TURTLEPanel { } - public String saveHeaderInXml() { - return "<Modeling type=\"Deployment\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Deployment\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Deployment\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; + } public String saveTailInXml() { diff --git a/src/ui/DesignPanel.java b/src/ui/DesignPanel.java index 054630708d2e2a439e62c3158ee5dc9e32ff69ca..2378089435aa561f8fa783ca121ad3abefa932c8 100755 --- a/src/ui/DesignPanel.java +++ b/src/ui/DesignPanel.java @@ -141,9 +141,13 @@ public class DesignPanel extends TURTLEPanel implements TURTLEDesignPanelInterfa //jsp.setVisible(true); } - - public String saveHeaderInXml() { - return "<Modeling type=\"Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Design\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; + } public String saveTailInXml() { diff --git a/src/ui/DiplodocusMethodologyPanel.java b/src/ui/DiplodocusMethodologyPanel.java index 80d1507cada225c4f8ad0f24afe512f127ad8410..323b0d7cccbddb1ced632de9b32a34be4edc6a06 100755 --- a/src/ui/DiplodocusMethodologyPanel.java +++ b/src/ui/DiplodocusMethodologyPanel.java @@ -163,9 +163,11 @@ public class DiplodocusMethodologyPanel extends TURTLEPanel { - - public String saveHeaderInXml() { - return "<Modeling type=\"Diplodocus Methodology\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Diplodocus Methodology\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Diplodocus Methodology\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/GTURTLEModeling.java b/src/ui/GTURTLEModeling.java index b24f1dee0be0c877821c282e3b2a1bea91c49e9a..85a5a2f8823efa3410d54f010d4fa5e73c906f66 100755 --- a/src/ui/GTURTLEModeling.java +++ b/src/ui/GTURTLEModeling.java @@ -4301,6 +4301,10 @@ public class GTURTLEModeling { } public String makeXMLFromTurtleModeling(int index) { + return makeXMLFromTurtleModeling(index, null); + } + + public String makeXMLFromTurtleModeling(int index, String extensionToName) { StringBuffer sb = new StringBuffer(); //sb.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n\n<TURTLEGMODELING>\n\n"); sb.append("<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>\n\n<TURTLEGMODELING version=\"" + DefaultText.getVersion() + "\">\n\n"); @@ -4314,7 +4318,7 @@ public class GTURTLEModeling { for(i=0; i<panels.size(); i++) { if ((index == -1) || (i == index)) { tp = (TURTLEPanel)(panels.elementAt(i)); - s = tp.saveInXML(); + s = tp.saveInXML(extensionToName); if (s == null) { return null; } diff --git a/src/ui/MainGUI.java b/src/ui/MainGUI.java index ac8e18d0a97f06e98fd023e7ca0d2b2c92355b29..d3493dd68213b88523dc75739d76eae515ead21b 100644 --- a/src/ui/MainGUI.java +++ b/src/ui/MainGUI.java @@ -7130,7 +7130,7 @@ public class MainGUI implements ActionListener, WindowListener, KeyListener, Pe } public void cloneTab(int index) { - String s = gtm.makeXMLFromTurtleModeling(index); + String s = gtm.makeXMLFromTurtleModeling(index, "_cloned"); try { gtm.loadModelingFromXML(s); changeMade(null, -1); diff --git a/src/ui/NCPanel.java b/src/ui/NCPanel.java index af50c3ac41462aba03ebe7c12b84cd57da045e1a..611f0ddb3c4441ce9bc6ea51e9d0d6ffe571ea12 100755 --- a/src/ui/NCPanel.java +++ b/src/ui/NCPanel.java @@ -1,49 +1,49 @@ /**Copyright or (C) or Copr. GET / ENST, Telecom-Paris, Ludovic Apvrille -ludovic.apvrille AT enst.fr - -This software is a computer program whose purpose is to allow the -edition of TURTLE analysis, design and deployment diagrams, to -allow the generation of RT-LOTOS or Java code from this diagram, -and at last to allow the analysis of formal validation traces -obtained from external tools, e.g. RTL from LAAS-CNRS and CADP -from INRIA Rhone-Alpes. - -This software is governed by the CeCILL license under French law and -abiding by the rules of distribution of free software. You can use, -modify and/ or redistribute the software under the terms of the CeCILL -license as circulated by CEA, CNRS and INRIA at the following URL -"http://www.cecill.info". - -As a counterpart to the access to the source code and rights to copy, -modify and redistribute granted by the license, users are provided only -with a limited warranty and the software's author, the holder of the -economic rights, and the successive licensors have only limited -liability. - -In this respect, the user's attention is drawn to the risks associated -with loading, using, modifying and/or developing or reproducing the -software by the user in light of its specific status of free software, -that may mean that it is complicated to manipulate, and that also -therefore means that it is reserved for developers and experienced -professionals having in-depth computer knowledge. Users are therefore -encouraged to load and test the software's suitability as regards their -requirements in conditions enabling the security of their systems and/or -data to be ensured and, more generally, to use and operate it in the -same conditions as regards security. - -The fact that you are presently reading this means that you have had -knowledge of the CeCILL license and that you accept its terms. - -/** - * Class NCPanel - * Managenemt of NC panels - * Creation: 18/11/2008 - * @version 1.0 18/11/2008 - * @author Ludovic APVRILLE - * @see MainGUI - */ - + ludovic.apvrille AT enst.fr + + This software is a computer program whose purpose is to allow the + edition of TURTLE analysis, design and deployment diagrams, to + allow the generation of RT-LOTOS or Java code from this diagram, + and at last to allow the analysis of formal validation traces + obtained from external tools, e.g. RTL from LAAS-CNRS and CADP + from INRIA Rhone-Alpes. + + This software is governed by the CeCILL license under French law and + abiding by the rules of distribution of free software. You can use, + modify and/ or redistribute the software under the terms of the CeCILL + license as circulated by CEA, CNRS and INRIA at the following URL + "http://www.cecill.info". + + As a counterpart to the access to the source code and rights to copy, + modify and redistribute granted by the license, users are provided only + with a limited warranty and the software's author, the holder of the + economic rights, and the successive licensors have only limited + liability. + + In this respect, the user's attention is drawn to the risks associated + with loading, using, modifying and/or developing or reproducing the + software by the user in light of its specific status of free software, + that may mean that it is complicated to manipulate, and that also + therefore means that it is reserved for developers and experienced + professionals having in-depth computer knowledge. Users are therefore + encouraged to load and test the software's suitability as regards their + requirements in conditions enabling the security of their systems and/or + data to be ensured and, more generally, to use and operate it in the + same conditions as regards security. + + The fact that you are presently reading this means that you have had + knowledge of the CeCILL license and that you accept its terms. + + /** + * Class NCPanel + * Managenemt of NC panels + * Creation: 18/11/2008 + * @version 1.0 18/11/2008 + * @author Ludovic APVRILLE + * @see MainGUI + */ + package ui; import java.awt.*; @@ -53,37 +53,37 @@ import java.util.*; import ui.ncdd.*; public class NCPanel extends TURTLEPanel { - public NCDiagramPanel ncdp; + public NCDiagramPanel ncdp; public Vector validated, ignored; - + public NCPanel(MainGUI _mgui) { super(_mgui); tabbedPane = new JTabbedPane(); cl = new ChangeListener() { - public void stateChanged(ChangeEvent e){ - mgui.paneDesignAction(e); - } - }; + public void stateChanged(ChangeEvent e){ + mgui.paneDesignAction(e); + } + }; tabbedPane.addChangeListener(cl); tabbedPane.addMouseListener(new TURTLEPanelPopupListener(this, mgui)); } - + public void init() { - + // Class Diagram toolbar NCDiagramToolBar toolBarNC = new NCDiagramToolBar(mgui); toolbars.add(toolBarNC); - + toolBarPanel = new JPanel(); toolBarPanel.setLayout(new BorderLayout()); - - //Class diagram + + //Class diagram ncdp = new NCDiagramPanel(mgui, toolBarNC); ncdp.setName("Network Calculus Diagram"); //tmlap.tp = this; tdp = ncdp; panels.add(ncdp); // Always first in list - JScrollDiagramPanel jsp = new JScrollDiagramPanel(ncdp); + JScrollDiagramPanel jsp = new JScrollDiagramPanel(ncdp); ncdp.jsp = jsp; jsp.setWheelScrollingEnabled(true); jsp.getVerticalScrollBar().setUnitIncrement(mgui.INCREMENT); @@ -91,27 +91,30 @@ public class NCPanel extends TURTLEPanel { toolBarPanel.add(jsp, BorderLayout.CENTER); tabbedPane.addTab("Network Calculus Diagram", IconManager.imgic60, toolBarPanel, "Opens network calculus diagram"); tabbedPane.setSelectedIndex(0); - + //jsp.setVisible(true); - + } - public String saveHeaderInXml() { - return "<Modeling type=\"NC diagram\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"NC diagram\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"NC diagram\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } - + public String saveTailInXml() { return "</Modeling>\n\n\n"; } - + public String toString() { return "NC diagram: " + mgui.getTitleAt(this); } - - /*public void renameMapping(String oldName, String newName) { - if (tmlap != null) { - tmlap.renameMapping(oldName, newName); - } - }*/ - -} \ No newline at end of file + + /*public void renameMapping(String oldName, String newName) { + if (tmlap != null) { + tmlap.renameMapping(oldName, newName); + } + }*/ + +} diff --git a/src/ui/ProactiveDesignPanel.java b/src/ui/ProactiveDesignPanel.java index c7585822c9d84f129fe5f3a8fa8ba4851a741dd7..20665e5275fad93f4fc9a11b7bd6c23ff80f8b8f 100755 --- a/src/ui/ProactiveDesignPanel.java +++ b/src/ui/ProactiveDesignPanel.java @@ -190,8 +190,12 @@ public class ProactiveDesignPanel extends TURTLEPanel { } - public String saveHeaderInXml() { - return "<Modeling type=\"ProActive Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"ProActive Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"ProActive Design\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; + } public String saveTailInXml() { @@ -301,4 +305,4 @@ public class ProactiveDesignPanel extends TURTLEPanel { -} \ No newline at end of file +} diff --git a/src/ui/RequirementPanel.java b/src/ui/RequirementPanel.java index 7e7bb27beb3bce46b3042ad356184261ac97732a..8f685a8ba4a0badc4b1022aba2ae4a363aee58a2 100755 --- a/src/ui/RequirementPanel.java +++ b/src/ui/RequirementPanel.java @@ -1,48 +1,48 @@ /**Copyright or (C) or Copr. GET / ENST, Telecom-Paris, Ludovic Apvrille -ludovic.apvrille AT enst.fr - -This software is a computer program whose purpose is to allow the -edition of TURTLE analysis, design and deployment diagrams, to -allow the generation of RT-LOTOS or Java code from this diagram, -and at last to allow the analysis of formal validation traces -obtained from external tools, e.g. RTL from LAAS-CNRS and CADP -from INRIA Rhone-Alpes. - -This software is governed by the CeCILL license under French law and -abiding by the rules of distribution of free software. You can use, -modify and/ or redistribute the software under the terms of the CeCILL -license as circulated by CEA, CNRS and INRIA at the following URL -"http://www.cecill.info". - -As a counterpart to the access to the source code and rights to copy, -modify and redistribute granted by the license, users are provided only -with a limited warranty and the software's author, the holder of the -economic rights, and the successive licensors have only limited -liability. - -In this respect, the user's attention is drawn to the risks associated -with loading, using, modifying and/or developing or reproducing the -software by the user in light of its specific status of free software, -that may mean that it is complicated to manipulate, and that also -therefore means that it is reserved for developers and experienced -professionals having in-depth computer knowledge. Users are therefore -encouraged to load and test the software's suitability as regards their -requirements in conditions enabling the security of their systems and/or -data to be ensured and, more generally, to use and operate it in the -same conditions as regards security. - -The fact that you are presently reading this means that you have had -knowledge of the CeCILL license and that you accept its terms. - -/** - * Class RequirementPanel - * Managenemt of requirement panels - * Creation: 15/05/2006 - * @version 1.1 08/09/2009 - * @author Ludovic APVRILLE - * @see MainGUI - */ + ludovic.apvrille AT enst.fr + + This software is a computer program whose purpose is to allow the + edition of TURTLE analysis, design and deployment diagrams, to + allow the generation of RT-LOTOS or Java code from this diagram, + and at last to allow the analysis of formal validation traces + obtained from external tools, e.g. RTL from LAAS-CNRS and CADP + from INRIA Rhone-Alpes. + + This software is governed by the CeCILL license under French law and + abiding by the rules of distribution of free software. You can use, + modify and/ or redistribute the software under the terms of the CeCILL + license as circulated by CEA, CNRS and INRIA at the following URL + "http://www.cecill.info". + + As a counterpart to the access to the source code and rights to copy, + modify and redistribute granted by the license, users are provided only + with a limited warranty and the software's author, the holder of the + economic rights, and the successive licensors have only limited + liability. + + In this respect, the user's attention is drawn to the risks associated + with loading, using, modifying and/or developing or reproducing the + software by the user in light of its specific status of free software, + that may mean that it is complicated to manipulate, and that also + therefore means that it is reserved for developers and experienced + professionals having in-depth computer knowledge. Users are therefore + encouraged to load and test the software's suitability as regards their + requirements in conditions enabling the security of their systems and/or + data to be ensured and, more generally, to use and operate it in the + same conditions as regards security. + + The fact that you are presently reading this means that you have had + knowledge of the CeCILL license and that you accept its terms. + + /** + * Class RequirementPanel + * Managenemt of requirement panels + * Creation: 15/05/2006 + * @version 1.1 08/09/2009 + * @author Ludovic APVRILLE + * @see MainGUI + */ package ui; @@ -56,113 +56,116 @@ import java.util.*; public class RequirementPanel extends TURTLEPanel { public RequirementDiagramPanel rdp; - public EBRDDPanel ebrdd; - + public EBRDDPanel ebrdd; + public RequirementPanel(MainGUI _mgui) { super(_mgui); - + tabbedPane = new JTabbedPane(); - UIManager.put("TabbedPane.tabAreaBackground", _mgui.BACK_COLOR); - UIManager.put("TabbedPane.selected", _mgui.BACK_COLOR); - SwingUtilities.updateComponentTreeUI(tabbedPane); - //tabbedPane.setOpaque(true); - + UIManager.put("TabbedPane.tabAreaBackground", _mgui.BACK_COLOR); + UIManager.put("TabbedPane.selected", _mgui.BACK_COLOR); + SwingUtilities.updateComponentTreeUI(tabbedPane); + //tabbedPane.setOpaque(true); + cl = new ChangeListener() { - public void stateChanged(ChangeEvent e){ - mgui.paneRequirementAction(e); - } - }; + public void stateChanged(ChangeEvent e){ + mgui.paneRequirementAction(e); + } + }; tabbedPane.addChangeListener(cl); tabbedPane.addMouseListener(new TURTLEPanelPopupListener(this, mgui)); - + } - + public void init() { - + // Requirement Diagram toolbar //addRequirementDiagram("Requirement Diagram"); - + //jsp.setVisible(true); } - + public boolean addRequirementDiagram(String s) { RequirementDiagramToolBar toolBarReq = new RequirementDiagramToolBar(mgui); toolbars.add(toolBarReq); - + toolBarPanel = new JPanel(); - //toolBarPanel.setBackground(Color.red); + //toolBarPanel.setBackground(Color.red); toolBarPanel.setLayout(new BorderLayout()); - //toolBarPanel.setBackground(ColorManager.MainTabbedPaneSelect); - - //Class diagram + //toolBarPanel.setBackground(ColorManager.MainTabbedPaneSelect); + + //Class diagram rdp = new RequirementDiagramPanel(mgui, toolBarReq); rdp.setName(s); rdp.tp = this; tdp = rdp; panels.add(rdp); - JScrollDiagramPanel jsp = new JScrollDiagramPanel(rdp); + JScrollDiagramPanel jsp = new JScrollDiagramPanel(rdp); rdp.jsp = jsp; jsp.setWheelScrollingEnabled(true); jsp.getVerticalScrollBar().setUnitIncrement(mgui.INCREMENT); toolBarPanel.add(toolBarReq, BorderLayout.NORTH); toolBarPanel.add(jsp, BorderLayout.CENTER); tabbedPane.addTab(s, IconManager.imgic1000, toolBarPanel, "Opens requirement diagram"); - tabbedPane.setSelectedIndex(0); + tabbedPane.setSelectedIndex(0); JPanel toolBarPanel = new JPanel(); toolBarPanel.setLayout(new BorderLayout()); - + return true; } - - public boolean addEBRDD(String s) { + + public boolean addEBRDD(String s) { EBRDDToolBar toolBarEBRDD = new EBRDDToolBar(mgui); toolbars.add(toolBarEBRDD); - + toolBarPanel = new JPanel(); - //toolBarPanel.setBackground(Color.red); + //toolBarPanel.setBackground(Color.red); toolBarPanel.setLayout(new BorderLayout()); - //toolBarPanel.setBackground(ColorManager.MainTabbedPaneSelect); - - // diagram + //toolBarPanel.setBackground(ColorManager.MainTabbedPaneSelect); + + // diagram ebrdd = new EBRDDPanel(mgui, toolBarEBRDD); ebrdd.setName(s); ebrdd.tp = this; //tdp = rdp; panels.add(ebrdd); - JScrollDiagramPanel jsp = new JScrollDiagramPanel(ebrdd); + JScrollDiagramPanel jsp = new JScrollDiagramPanel(ebrdd); ebrdd.jsp = jsp; jsp.setWheelScrollingEnabled(true); jsp.getVerticalScrollBar().setUnitIncrement(mgui.INCREMENT); toolBarPanel.add(toolBarEBRDD, BorderLayout.NORTH); toolBarPanel.add(jsp, BorderLayout.CENTER); tabbedPane.addTab(s, IconManager.imgic1058, toolBarPanel, "Opens EBRDD"); - tabbedPane.setSelectedIndex(0); + tabbedPane.setSelectedIndex(0); JPanel toolBarPanel = new JPanel(); toolBarPanel.setLayout(new BorderLayout()); - + return true; } - - public String saveHeaderInXml() { - return "<Modeling type=\"Requirement\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Requirement\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Requirement\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } - + public String saveTailInXml() { return "</Modeling>\n\n\n"; } - + public String toString() { return mgui.getTitleAt(this) + " (SysML Requirement Diagrams)"; } - + public boolean removeEnabled(int index) { if (panels.size() > 1) { return true; } return false; } - + public boolean renameEnabled(int index) { if (panels.size() == 0) { return false; @@ -170,26 +173,26 @@ public class RequirementPanel extends TURTLEPanel { if ((panels.elementAt(index) instanceof RequirementDiagramPanel)){ return true; } - - if ((panels.elementAt(index) instanceof EBRDDPanel)){ + + if ((panels.elementAt(index) instanceof EBRDDPanel)){ return true; } - - + + return false; } - - public boolean isReqEnabled() { + + public boolean isReqEnabled() { return true; } - - public void addAllEBRDDPanels(ArrayList<EBRDDPanel> _al) { - for(int i=0; i<panels.size(); i++) { - if (panelAt(i) instanceof EBRDDPanel) { - _al.add(((EBRDDPanel)panelAt(i))); - } - } - } - -} \ No newline at end of file + public void addAllEBRDDPanels(ArrayList<EBRDDPanel> _al) { + for(int i=0; i<panels.size(); i++) { + if (panelAt(i) instanceof EBRDDPanel) { + _al.add(((EBRDDPanel)panelAt(i))); + } + } + } + + +} diff --git a/src/ui/SysmlsecMethodologyPanel.java b/src/ui/SysmlsecMethodologyPanel.java index 6e412c5f392c4e45ea8ed3ca952b1ee25a7fb430..78b01c4e2e710d6f59cf0eac9f1dab9efa04d079 100755 --- a/src/ui/SysmlsecMethodologyPanel.java +++ b/src/ui/SysmlsecMethodologyPanel.java @@ -38,7 +38,7 @@ /** * Class SysmlsecMethodologyPanel * Managenemt of the sysmlsec methodology panels - * Creation: 26/0&/2016 + * Creation: 26/01/2016 * @version 1.1 26/01/2016 * @author Ludovic APVRILLE * @see MainGUI @@ -280,9 +280,11 @@ public class SysmlsecMethodologyPanel extends TURTLEPanel { - - public String saveHeaderInXml() { - return "<Modeling type=\"Sysmlsec Methodology\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"Sysmlsec Methodology\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"Sysmlsec Methodology\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/TMLArchiPanel.java b/src/ui/TMLArchiPanel.java index 50c3cd5d029f661a4515fd0ed4eb618c538b95a9..0302cf8d7d8df95a5fd17dfc91542c03ff981193 100755 --- a/src/ui/TMLArchiPanel.java +++ b/src/ui/TMLArchiPanel.java @@ -101,8 +101,11 @@ public class TMLArchiPanel extends TURTLEPanel { } - public String saveHeaderInXml() { - return "<Modeling type=\"TML Architecture\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"TML Architecture\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"TML Architecture\" nameTab=\"" + mgui.getTabName(this) + extensionToName +"\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/TMLCommunicationPatternPanel.java b/src/ui/TMLCommunicationPatternPanel.java index d468db0f4b42e0cf2e2528dbd05b6bf3e0851235..5faf2ad58353d7e5620caf181d4cbc34473dbe01 100755 --- a/src/ui/TMLCommunicationPatternPanel.java +++ b/src/ui/TMLCommunicationPatternPanel.java @@ -163,8 +163,12 @@ public class TMLCommunicationPatternPanel extends TURTLEPanel { } - public String saveHeaderInXml() { - return "<Modeling type=\"TML CP\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"TML CP\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"TML CP\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { diff --git a/src/ui/TMLComponentDesignPanel.java b/src/ui/TMLComponentDesignPanel.java index c5eaab940e3ded609e8160d0156ce40a86235200..f11f05c999c39f2d4eb6a07aa10d99ffbf00b80b 100755 --- a/src/ui/TMLComponentDesignPanel.java +++ b/src/ui/TMLComponentDesignPanel.java @@ -147,8 +147,12 @@ public class TMLComponentDesignPanel extends TURTLEPanel { } - public String saveHeaderInXml() { - return "<Modeling type=\"TML Component Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"TML Component Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"TML Component Design\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; + } public String saveTailInXml() { diff --git a/src/ui/TMLDesignPanel.java b/src/ui/TMLDesignPanel.java index f841c483cfa85807f74141c3eafd87f8ae1fce82..38705e3b00c6da96cf0b6eaa19c36584bc0fff4a 100755 --- a/src/ui/TMLDesignPanel.java +++ b/src/ui/TMLDesignPanel.java @@ -1,50 +1,50 @@ /**Copyright or (C) or Copr. GET / ENST, Telecom-Paris, Ludovic Apvrille, Andrea Enrici -ludovic.apvrille AT enst.fr -andrea.enrici AT enst.fr - -This software is a computer program whose purpose is to allow the -edition of TURTLE analysis, design and deployment diagrams, to -allow the generation of RT-LOTOS or Java code from this diagram, -and at last to allow the analysis of formal validation traces -obtained from external tools, e.g. RTL from LAAS-CNRS and CADP -from INRIA Rhone-Alpes. - -This software is governed by the CeCILL license under French law and -abiding by the rules of distribution of free software. You can use, -modify and/ or redistribute the software under the terms of the CeCILL -license as circulated by CEA, CNRS and INRIA at the following URL -"http://www.cecill.info". - -As a counterpart to the access to the source code and rights to copy, -modify and redistribute granted by the license, users are provided only -with a limited warranty and the software's author, the holder of the -economic rights, and the successive licensors have only limited -liability. - -In this respect, the user's attention is drawn to the risks associated -with loading, using, modifying and/or developing or reproducing the -software by the user in light of its specific status of free software, -that may mean that it is complicated to manipulate, and that also -therefore means that it is reserved for developers and experienced -professionals having in-depth computer knowledge. Users are therefore -encouraged to load and test the software's suitability as regards their -requirements in conditions enabling the security of their systems and/or -data to be ensured and, more generally, to use and operate it in the -same conditions as regards security. - -The fact that you are presently reading this means that you have had -knowledge of the CeCILL license and that you accept its terms. - -/** - * Class TMLDesignPanel - * Managenemt of TML design panels - * Creation: 27/10/2006 - * @version 1.0 28/05/2014 - * @author Ludovic APVRILLE, Andrea ENRICI - * @see MainGUI - */ - + ludovic.apvrille AT enst.fr + andrea.enrici AT enst.fr + + This software is a computer program whose purpose is to allow the + edition of TURTLE analysis, design and deployment diagrams, to + allow the generation of RT-LOTOS or Java code from this diagram, + and at last to allow the analysis of formal validation traces + obtained from external tools, e.g. RTL from LAAS-CNRS and CADP + from INRIA Rhone-Alpes. + + This software is governed by the CeCILL license under French law and + abiding by the rules of distribution of free software. You can use, + modify and/ or redistribute the software under the terms of the CeCILL + license as circulated by CEA, CNRS and INRIA at the following URL + "http://www.cecill.info". + + As a counterpart to the access to the source code and rights to copy, + modify and redistribute granted by the license, users are provided only + with a limited warranty and the software's author, the holder of the + economic rights, and the successive licensors have only limited + liability. + + In this respect, the user's attention is drawn to the risks associated + with loading, using, modifying and/or developing or reproducing the + software by the user in light of its specific status of free software, + that may mean that it is complicated to manipulate, and that also + therefore means that it is reserved for developers and experienced + professionals having in-depth computer knowledge. Users are therefore + encouraged to load and test the software's suitability as regards their + requirements in conditions enabling the security of their systems and/or + data to be ensured and, more generally, to use and operate it in the + same conditions as regards security. + + The fact that you are presently reading this means that you have had + knowledge of the CeCILL license and that you accept its terms. + + /** + * Class TMLDesignPanel + * Managenemt of TML design panels + * Creation: 27/10/2006 + * @version 1.0 28/05/2014 + * @author Ludovic APVRILLE, Andrea ENRICI + * @see MainGUI + */ + package ui; import java.awt.*; @@ -56,22 +56,22 @@ import ui.tmlad.*; import ui.tmldd.*; public class TMLDesignPanel extends TURTLEPanel { - public TMLTaskDiagramPanel tmltdp; + public TMLTaskDiagramPanel tmltdp; public Vector<TGComponent> validated, ignored; - + public TMLDesignPanel(MainGUI _mgui) { super(_mgui); tabbedPane = new JTabbedPane(); cl = new ChangeListener() { - public void stateChanged(ChangeEvent e){ - mgui.paneDesignAction(e); - } - }; + public void stateChanged(ChangeEvent e){ + mgui.paneDesignAction(e); + } + }; tabbedPane.addChangeListener(cl); tabbedPane.addMouseListener(new TURTLEPanelPopupListener(this, mgui)); } - - public TMLActivityDiagramPanel getTMLActivityDiagramPanel(String name) { + + public TMLActivityDiagramPanel getTMLActivityDiagramPanel(String name) { TMLActivityDiagramPanel tmladp; for(int i=1; i<panels.size(); i++) { tmladp = (TMLActivityDiagramPanel)(panels.elementAt(i)); @@ -84,14 +84,14 @@ public class TMLDesignPanel extends TURTLEPanel { public void addTMLActivityDiagram(String s) { JPanel toolBarPanel = new JPanel(); toolBarPanel.setLayout(new BorderLayout()); - - TMLActivityDiagramToolBar toolBarActivity = new TMLActivityDiagramToolBar(mgui); + + TMLActivityDiagramToolBar toolBarActivity = new TMLActivityDiagramToolBar(mgui); toolbars.add(toolBarActivity); - + TMLActivityDiagramPanel tmladp = new TMLActivityDiagramPanel(mgui, toolBarActivity); tmladp.tp = this; tmladp.setName(s); - JScrollDiagramPanel jsp = new JScrollDiagramPanel(tmladp); + JScrollDiagramPanel jsp = new JScrollDiagramPanel(tmladp); tmladp.jsp = jsp; jsp.setWheelScrollingEnabled(true); jsp.getVerticalScrollBar().setUnitIncrement( MainGUI.INCREMENT ); @@ -99,26 +99,26 @@ public class TMLDesignPanel extends TURTLEPanel { toolBarPanel.add(jsp, BorderLayout.CENTER); panels.add(tmladp); tabbedPane.addTab(s, IconManager.imgic63, toolBarPanel, "Opens the activity diagram of " + s); - + return; } - + public void init() { - + // Class Diagram toolbar TMLTaskDiagramToolBar toolBarTML = new TMLTaskDiagramToolBar(mgui); toolbars.add(toolBarTML); - + toolBarPanel = new JPanel(); toolBarPanel.setLayout(new BorderLayout()); - - //Class diagram + + //Class diagram tmltdp = new TMLTaskDiagramPanel(mgui, toolBarTML); tmltdp.setName("TML Task Diagram"); tmltdp.tp = this; tdp = tmltdp; panels.add(tmltdp); // Always first in list - JScrollDiagramPanel jsp = new JScrollDiagramPanel(tmltdp); + JScrollDiagramPanel jsp = new JScrollDiagramPanel(tmltdp); tmltdp.jsp = jsp; jsp.setWheelScrollingEnabled(true); jsp.getVerticalScrollBar().setUnitIncrement( MainGUI.INCREMENT ); @@ -126,62 +126,65 @@ public class TMLDesignPanel extends TURTLEPanel { toolBarPanel.add(jsp, BorderLayout.CENTER); tabbedPane.addTab("TML Task Diagram", IconManager.imgic62, toolBarPanel, "Opens TML task diagram"); tabbedPane.setSelectedIndex(0); - + mgui.changeMade(tmltdp, TDiagramPanel.NEW_COMPONENT); - + //jsp.setVisible(true); - + } - - public String saveHeaderInXml() { - return "<Modeling type=\"TML Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"TML Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"TML Design\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } - + public String saveTailInXml() { return "</Modeling>\n\n\n"; } - + public String toString() { return mgui.getTitleAt(this) + " (TML Functional View)"; } - - public ArrayList<String> getAllTMLTaskNames(String _name) { - return tmltdp.getAllTMLTaskNames(_name); - } - public ArrayList<String> getAllTMLCommunicationNames(String _name) { - return tmltdp.getAllTMLCommunicationNames(_name); - } - - public ArrayList<String> getAllTMLEventNames( String _name ) { - return tmltdp.getAllTMLEventNames( _name ); - } + public ArrayList<String> getAllTMLTaskNames(String _name) { + return tmltdp.getAllTMLTaskNames(_name); + } + + public ArrayList<String> getAllTMLCommunicationNames(String _name) { + return tmltdp.getAllTMLCommunicationNames(_name); + } + + public ArrayList<String> getAllTMLEventNames( String _name ) { + return tmltdp.getAllTMLEventNames( _name ); + } + + public java.util.List<String> getAllNonMappedTMLTaskNames(String _name, TMLArchiDiagramPanel _tadp, boolean ref, String name) { + return tmltdp.getAllNonMappedTMLTaskNames(_name, _tadp, ref, name); + } + + public TMLTaskOperator getTaskByName(String _name) { + return tmltdp.getTaskByName(_name); + } + + public void getListOfBreakPoints(ArrayList<Point> points) { + TGComponent tgc; + Iterator<TGComponent> iterator = tmltdp.getComponentList().listIterator(); + TMLTaskOperator tmlto; + TMLActivityDiagramPanel tmladp; - public java.util.List<String> getAllNonMappedTMLTaskNames(String _name, TMLArchiDiagramPanel _tadp, boolean ref, String name) { - return tmltdp.getAllNonMappedTMLTaskNames(_name, _tadp, ref, name); - } - - public TMLTaskOperator getTaskByName(String _name) { - return tmltdp.getTaskByName(_name); - } - - public void getListOfBreakPoints(ArrayList<Point> points) { - TGComponent tgc; - Iterator<TGComponent> iterator = tmltdp.getComponentList().listIterator(); - TMLTaskOperator tmlto; - TMLActivityDiagramPanel tmladp; - while(iterator.hasNext()) { tgc = iterator.next(); - + if (tgc instanceof TMLTaskOperator) { tmlto = (TMLTaskOperator)tgc; - + if (tmlto.getDIPLOID() != -1) { - tmladp = getTMLActivityDiagramPanel(tmlto.getValue()); - tmladp.getListOfBreakPoints(points, tmlto.getDIPLOID()); - } - } - } - } + tmladp = getTMLActivityDiagramPanel(tmlto.getValue()); + tmladp.getListOfBreakPoints(points, tmlto.getDIPLOID()); + } + } + } + } } diff --git a/src/ui/TURTLEOSDesignPanel.java b/src/ui/TURTLEOSDesignPanel.java index 53a23b173ec105062699064fcc4a934a9f78cab9..e8125f1925a44eafbeb35cfc1c7c927cbe481719 100755 --- a/src/ui/TURTLEOSDesignPanel.java +++ b/src/ui/TURTLEOSDesignPanel.java @@ -135,8 +135,11 @@ public class TURTLEOSDesignPanel extends TURTLEPanel implements TURTLEDesignPane tabbedPane.setSelectedIndex(0); } - public String saveHeaderInXml() { - return "<Modeling type=\"TURTLE-OS Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + public String saveHeaderInXml(String extensionToName) { + if (extensionToName == null) { + return "<Modeling type=\"TURTLE-OS Design\" nameTab=\"" + mgui.getTabName(this) + "\" >\n"; + } + return "<Modeling type=\"TURTLE-OS Design\" nameTab=\"" + mgui.getTabName(this) + extensionToName + "\" >\n"; } public String saveTailInXml() { @@ -147,4 +150,4 @@ public class TURTLEOSDesignPanel extends TURTLEPanel implements TURTLEDesignPane return "TURTLE-OS: " + mgui.getTitleAt(this); } -} \ No newline at end of file +} diff --git a/src/ui/TURTLEPanel.java b/src/ui/TURTLEPanel.java index 4cf9dd39acd13034cf9ac7c6a19441be375f38e1..3c0f39bd6bfe5737f80d56518128f4e6df9ce662 100755 --- a/src/ui/TURTLEPanel.java +++ b/src/ui/TURTLEPanel.java @@ -68,7 +68,7 @@ public abstract class TURTLEPanel implements GenericTree { } public abstract void init(); - public abstract String saveHeaderInXml(); + public abstract String saveHeaderInXml(String extensionToName); public abstract String saveTailInXml(); public TDiagramPanel panelAt(int index) { @@ -97,16 +97,20 @@ public abstract class TURTLEPanel implements GenericTree { } public StringBuffer saveInXML() { + return saveInXML(null); + } + + public StringBuffer saveInXML(String extensionToName) { TDiagramPanel tdp; StringBuffer sb = new StringBuffer(); - sb.append(saveHeaderInXml()); + sb.append(saveHeaderInXml(extensionToName)); StringBuffer s; for(int i=0; i<panels.size(); i++) { tdp = (TDiagramPanel)(panels.elementAt(i)); s = tdp.saveInXML(); if (s == null) { - System.out.println("Null diagram"); + //System.out.println("Null diagram"); return null; } sb.append(s); @@ -120,13 +124,13 @@ public abstract class TURTLEPanel implements GenericTree { TDiagramPanel tdp; StringBuffer sb = new StringBuffer(); - sb.append(saveHeaderInXml()); + sb.append(saveHeaderInXml(null)); StringBuffer s; tdp = (TDiagramPanel)(panels.elementAt(indexOfDiagram)); s = tdp.saveInXML(); if (s == null) { - System.out.println("Null diagram"); + //System.out.println("Null diagram"); return null; } sb.append(s); @@ -327,7 +331,7 @@ public abstract class TURTLEPanel implements GenericTree { public void searchForText(String text, Vector<Object> elements) { if (panelAt(0) != null) { - String s = saveHeaderInXml().toLowerCase(); + String s = saveHeaderInXml(null).toLowerCase(); if (s.indexOf(text) >= 0) { elements.add(this); /*CheckingError ce = new CheckingError(CheckingError.INFO, "Diagram");