rendered paste bodynamespace eval Modules::Config {
proc addModuleConfig {ModuleID ModuleName FunctionNr Program} {
array set ::[namespace current]::ModuleDef$ModuleID {
ID $ModuleID
Name $ModuleName
FunctionNr $FunctionNr
}
}
proc addChannelConfig {ModuleID ChannelID ChannelName Prio SendBuf RecvBuf} {
array set [format "::%s::Module%dChannel%d" [namespace current] $ModuleID $ChannelID] {
Name $ChannelNanme
ID $ChannelID
SendBuf $SendBuf
RecvBuf $RecvBuf
Prio $Prio
}
}
proc createTestConfig {} {
set tmpModule [addModuleConfig 2 "GenApp" 7 "genapp.out"]
addChannelConfig 2 0 "Generic Channel" 16 40 40
addChannelConfig 2 1 "Devel Channel" 16 40 40
}