OK, step by step:
$self <--- the object's own handle, in the form "_oXXX" [$self agent] <--- calls a proc named "agent" on the current class that returns the handle, in the form "_oXXX", of the agent associated to the current object. This proc can be located in several places: - an otcl proc of the current class - an otcl proc inherited from the parents of the current class - (possible, but not probable) something returned from C++ "command()" function [[$self agent] set node_ ] <--- returns the node handle, in the form "_oXXX" of the agent associated with the current object. ----------- I strongly suggest you and other NS users to use my otcl debugging facilities, especially the MASH otcl object inspector, to greatly ease this kind of debugging: http://inesc-0.tagus.ist.utl.pt/~pestrela/ns2/ns2_debugging2.html http://inesc-0.tagus.ist.utl.pt/~pestrela/ns2/ns2_with_tkcon_and_tcldebug_sc reenshot2.PNG Info about the type of addresses that a node can have http://inesc-0.tagus.ist.utl.pt/~pestrela/ns2/ns2_haddr_tips.html#_Toc121548 871 Pedro Vale Estrela > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf > Of Shafiq Hashmi > Sent: sexta-feira, 17 de Março de 2006 6:54 > To: [email protected] > Subject: [ns] What does this line means " [[$self agent] set node_ ] " > > > Hello all, > > I am always confused with this assignment statement > > [[$self agent] set node_ ] > > What does it exaclty means? What value it is assigning to which variable > ?? > Here 'agent' is a shadow instance, created in OTcl space, of an object in > C++. > > Can somebody help me understanding it. There are hundreds of statements > like > this in Leach code that I am unable to comprehend. > > Thanx > Shafiq >
