freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

ns的網(wǎng)絡(luò)功能實(shí)體結(jié)構(gòu)及類結(jié)構(gòu)(留存版)

2024-12-11 15:19上一頁面

下一頁面
  

【正文】 iled to be allocated. delete $o return } global errorInfo error class $className: constructor failed: $msg $errorInfo } return $o } ―Simulator create 4‖ 該操作創(chuàng)建一個(gè)Simulator對(duì)象,并調(diào)用它的 init函數(shù)進(jìn)行初始化 啟動(dòng)過程 1 ? Simulator instproc init args {…} tcl/lib/ Simulator instproc init args { …… $self create_packetformat $self usescheduler Calendar $self set nullAgent_ [new Agent/Null] $self setaddressformat def if {[lindex $args 0] == multicast} { $self multicast $args } eval $self next $args } 這個(gè)還未找到代碼位置 (找到了 ),可以猜想是創(chuàng)建數(shù)據(jù)包的頭標(biāo)對(duì)應(yīng)的數(shù)據(jù)結(jié)構(gòu),創(chuàng)建對(duì)象 _o5,類型為 PacketHeaderManager 創(chuàng)建對(duì)象 _o6,類型為Scheduler/Calender,一個(gè)非常重要的類,單線程的 ns能模擬多節(jié)點(diǎn)的網(wǎng)絡(luò),就是通過它來調(diào)度。是否應(yīng)該是dmux_的映射表? RtModule instproc attach { agent port } { $agent target [[$self node] entry] [[$self node] demux] install $port $agent } RtModule instproc addroute { dst target } { $self instvar next_rtm_ [$self set classifier_] install $dst $target if {$next_rtm_ != } { $next_rtm_ addroute $dst $target }} Node instproc addroute { dst target } { $self instvar rtnotif_ if {$rtnotif_ != } { $rtnotif_ addroute $dst $target } $self incrrtgtablesize } Classifier instproc install {slot val} { $self set slots_($slot) $val $self cmd install $slot $val } 進(jìn)入 classifier的 c++代碼 有兩個(gè)變量要引起注意: rtnotif_和前面提到的ptnotif_;我覺得 rtnotif_是路由模塊, ptnotif_是端口映射模塊。 NsObject* nullagent = (NsObject*)TclObject::lookup(argv[2])。但是用起來簡單,只需要知道“我的一個(gè)事件,給定一個(gè)時(shí)間,交給它,到時(shí)候它就會(huì)處理”就行了 創(chuàng)建對(duì)象 _o7,類型為Agent/Null,一個(gè)黑洞 tcl/lib/ Simulator instproc usescheduler type { $self instvar scheduler_ if [info exists scheduler_] { if { [$scheduler_ info class] == Scheduler/$type } { return } else { delete $scheduler_ } } set scheduler_ [new Scheduler/$type] $scheduler_ now } _o4 info class Simulator _o5 info class PacketHeaderManager _o6 info class Scheduler/Calendar _o7 info class Agent/Null _o8 info class AllocAddrBits _o9 info class AllocAddr _o10 info class Address _o11 info class invalid mand name _o11 while executing _o11 info class 目前為止已經(jīng)產(chǎn)生了 10個(gè)對(duì)象了 啟動(dòng)過程 2☆ ? set n0 [$ns node] ? set n1 [$ns node] tcl/lib/ Simulator instproc node args { $self instvar Node_ routingAgent_ wiredRouting_ satNodeType_ …… Enablemcast is now done automatically inside Node::init{} XXX node_factory_ is deprecated, HOWEVER, since it39。有相關(guān)函數(shù) (類似 routenotify函數(shù) )portnotify,但沒有看到調(diào)用的地方(在 RtModule的 register函數(shù)中調(diào)用了,也就是說在路由模塊既負(fù)責(zé)尋路又負(fù)責(zé)端口的對(duì)應(yīng),后者只是一個(gè)虛名,還是由 Classifier/Port自己完成的 )。s routing entry to itself at the port demuxer (if there is one) $self addroute $address_ $dmux_把到自己的路由加入進(jìn)去 } if { $port == ―‖ } {會(huì)進(jìn)入,因?yàn)橐话悴恢付ǘ丝? set port [$dmux_ allocport [[Simulator instance] nullagent]] } $agent set agent_port_ $port $self addtarget $agent $port } 把該 agent加到node的 agent列表 插敘: Ns的 IP地址 //cla
點(diǎn)擊復(fù)制文檔內(nèi)容
教學(xué)課件相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1