📄 showassignmentpropandrelationship.tcl
字号:
proc ShowAssignmentProp {id} { global fp puts $fp " <---- properties ----" puts $fp " npiType=[npi_get $id -npiType]" puts $fp " npiFile=[npi_get $id -npiFile]" puts $fp " npiLineNo=[npi_get $id -npiLineNo]" puts $fp " npiAssignmentType = [npi_get $id -npiAssignmentType]" puts $fp " npiIsBlocking = [npi_get $id -npiIsBlocking]" puts $fp " >---- properties ----"}proc ShowHandleProp {Handle type} { global fp puts $fp " <---$type --->" if {$Handle != "NULL"} { puts $fp " npiType = [npi_get $Handle -npiType]" puts $fp " npiFile = [npi_get $Handle -npiFile]" puts $fp " npiLineNo = [npi_get $Handle -npiLineNo]" } puts $fp " <---end of $type --->"}proc ShowAssignmentRelationship {id} { global fp puts $fp " <---relationship --->" set DelayCtrl [npi_handle $id -npiType npiDelayControl] ShowHandleProp $DelayCtrl "npi_handle \$id -npiType npiDelayControl" set EventCtrl [npi_handle $id -npiType npiEventControl] ShowHandleProp $EventCtrl "npi_handle \$id -npiType npiEventControl" set RepeatCtrl [npi_handle $id -npiType npiRepeatControl] ShowHandleProp $RepeatCtrl "npi_handle \$id -npiType npiRepeatControl" set left [npi_handle $id -npiType npiLhs] ShowHandleProp $left "npi_handle \$id -npiType npiLhs" set right [npi_handle $id -npiType npiRhs] ShowHandleProp $right "npi_handle \$id -npiType npiRhs" puts $fp " <---end of relationship --->"}proc ShowAssignmentPropAndRelationship {} { global g_Assignment global fp set var $g_Assignment puts $fp "<---begin showing Assignment information--->" ShowAssignmentProp $var ShowAssignmentRelationship $var puts $fp "<---end of showing Assignment information--->"} set log_file [file join [file dirname [info script]] [file tail [info script]].out]set fp [open $log_file w]fconfigure $fp -buffering nonenpi_register_cb -npiModuleBased Assignment ShowAssignmentPropAndRelationshipnpi_traverse_model -npiModuleBasedclose $fp
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -