Thanks for the answer.
But in the example,the MTC could be replaced by PTC?
and the map is the same?
Best Regards,
Pan
Original Message
From: "Stephan Tobies" <This email address is being protected from spambots. You need JavaScript enabled to view it.>
To: <This email address is being protected from spambots. You need JavaScript enabled to view it.>
Sent: Tuesday, June 29, 2004 4:20 PM
Subject: Re: question about map and connect
> ext Pan Yuanming wrote:
>
> > Hi,
> > I am new to TTCN.I have a question about connect/map.
> > That is:
> > there are 3 components, in the component1 could do the conection as :
> > connect(component2:port1,component3:port1)? or
> > map(component2:port1,component3:port1)?
>
>
> Yes, it is possible to use map/connect from 'outside' of the components.
> For example, in your MTC you may create two PTCs and connect their ports
> before starting them:
>
> type port CoordinationPort message {
> inout CoordinationMsg
> };
>
> type component PTC {
> port CoordinationPort P_coord
> };
>
> testcase tc() ... {
> var PTC ptc1 := PTC.create;
> var PTC ptc2 := PTC.create;
>
> connect(ptc1:P_coord, ptc2:P_coord);
> ...
> }
>
> Best regards
>
> Stephan Tobies
>
> --
> Stephan Tobies Sr. Research Engineer, Nokia Research Center
> ~ Mobile Networks Lab, Protocol Engineering Group
> E-Mail: This email address is being protected from spambots. You need JavaScript enabled to view it.
> Work Phone: +49-234-9842262
> Mobile: +49-163-9842405
> Fax: +49-234-9843491
> Address: NRC Bochum, Meesmannstr. 103, 44807 Bochum, Germany