可
可爱宝宝
Unregistered / Unconfirmed
GUEST, unregistred user!
程序的配置怎么从文本文件读入?
附一段配置
[Global]
ListenIP=3,14,172.19.100.168
ListenPort=2101
MobileConvert=2:13:86,2:5:86,2:8:86,2:16:86
//有效期
//DefaultValidityPeriod=8,+,1:0:0:0
DefaultValidityPeriod=NULL
ASP_SUPER_PASWORD=37e6d8
UniqueId_MsgId=ISCA
//have control start link timer;
SleepTimer=1000
OptionTag=0000
//0:SMPP;1:CIMD;
ProtocolFlag=0
//0:first bill code last addr; 1:first addr last bill code;
//0:4100-1100-1681100; 1:4100-1684100-1100
BillCodeAddressConvert=1
[Segment]
SegmentNumber=9
Segment1=13500000000,13599999999,111,0
Segment2=13600000000,13699999999,222,0
Segment3=13700000000,13799999999,333,0
Segment4=13800000000,13899999999,444,0
Segment5=13900000000,13999999999,555,0
Segment6=13000000000,13099999999,666,0
Segment7=13100000000,13199999999,777,0
Segment8=13200000000,13299999999,888,0
Segment9=13300000000,13399999999,999,0
[ServiceCode]
//!:非完全匹配;
//%:Smp协议发送;
CodeFrom=!PHB D,+XXTQ,168
CodeTo=%CPHB D,%TQ,169
SendUdpSmp=172.19.100.168,7912
[SMC]
//0:two link and the same user/pwd; 1:two link and different user/pwd;
GatewayMode=0
GatewayNumber=1
//control send is void
SendLinkNumber=1
Gateway1=3,14,172.19.100.168,2000,168,168,168,52,1
Gateway2=3,14,172.19.100.168,2201,DL802,P802,AGENT,52,2
GatewayNumberRX=1
GatewayNumberTX=1
Gateway1RX=3,14,172.19.100.168,2000,168,168,168,52,1
Gateway1TX=3,14,172.19.100.168,2000,168,168,168,52,1
Gateway2RX=3,14,172.19.100.168,2201,DL802,P802,AGENT,52,2
Gateway2TX=3,14,172.19.100.168,2201,DL802,P802,AGENT,52,2
TEST_SER_ALIVE=on
//1:1-trust 0-no trust;2:rsp_time;3:1-num msg rsp throw away;4:free busy;
//control send is void
TrustSend=0,300,2,1
RepeatNum=1
//0xFF-unchange
Priority=1
//0xFF-unchange
StatusReport=0
//0xFF-unchange; only use in smp;
SmpDcsCode=255
//send dest address len;
SendSmcAddressLen=11
//0:不动,1:替换,2:追加; ton; npi; 原地址;处理地址长度限制
OutSurceAddress=1,1,1,86168,11
//0:不动,1:追加; ton; npi; 86;
OutDestAddress=1,1,1,86
0:不动,1:尾部去掉,2:去86后留3位; 处理地址长度限制
InDestAddress=2,3,14
UnChangeAddr=166,169
//*转换
AddAddressNum=3
AddAddress1=31:4100,4101
AddAddress2=41:4104
AddAddress3=51:4109,4171
//转换FreeFee mobile
SendUdpSmp=0,172.19.100.168,7912
FreeMobileNumber=13971640801,13971272512,13971166457
TypeAddress=1860
TypeCode=0000
SendOutControl=0
LinkSmcClassNum=2
LinkSmcClass1=1:1,2,3,4,5
LinkSmcClass2=2:6,7,8,9
[CIMD]
UDPSMCIPAddr=172.19.100.168,2001
[ReportConfig]
//处理状态报告
StatusReportFlag=1
StatusReportAddressNum=2
//ip地址,ip端口号,权限(0:有效,255:无效)
StatusReportAddress1=172.19.100.168,2101,0
StatusReportAddress2=172.19.100.168,2101,0
EsmSriTag=32,4
[IED]
TEST_CLI_ALIVE=on
TCPIPTestFlag=0
ReadConfig=1
IedClientNum=4
//255:不下发,管理接入
IedClient1=000,BOSS,BOSS,MANAGE,52,255
IedClient2=901,ISPC901,P901,ISPC,52,0
IedClient3=902,ISPC902,P902,ISPC,52,0
IedClient4=903,DL802,P802,AGENT,52,0
[SMP]
UDPLocalSmcPort=2102
UDPLocalSmePort=2103
RemoteSendFromSmc=0
UDPRemoteIPAddr=172.19.100.168,2001
[Timer]
SEND_MSG_SER=10
SEND_MSG_CLI=13
PROCESS_SMPUDP=13
TRANS_CIMD=13
TRANS_SMGP=13
ALIVE_SER=15000
ALIVE_CLI=15000
RELINK_TIME=1000
RELINK_FLAG=on
SET_STATUS_TIME=1000
[BillCodeConver]
BillCodeNum=4
//业务类型:资费类型:资费代码-业务类型,业务类型......
BillCode1=4100:1:20-4100,4101,4102,4103
BillCode2=4200:1:20-4200,4201
BillCode3=4104:1:20-4300,4301,1010,4303
BillCode4=4999:1:20-4999
OtherCode=5000:1:20
[TraceTimeMobile]
MobileNumber=13971640801,13501370969
LinkAlertMobile=13791640801,13501370969
AlertEveryCount=10
BillCode=1010
[RemoteTrace]
ReTraceFlag=off
ReTraceRemoteIP=168.160.234.93,7310
ReTraceLocalIP=168.160.234.97,7910
ReTraceLocalName=InterFace
[Debug]
TestTag=TEST,XXPT
ReStart=off
ViewApplication=on
TraceApplication=on
DumpMessage=on
TraceTimeSpan=on
LogDirectory=C:/log
SaveLogTime=3
FileNameNum=9999
FileLineNum=10000
附一段配置
[Global]
ListenIP=3,14,172.19.100.168
ListenPort=2101
MobileConvert=2:13:86,2:5:86,2:8:86,2:16:86
//有效期
//DefaultValidityPeriod=8,+,1:0:0:0
DefaultValidityPeriod=NULL
ASP_SUPER_PASWORD=37e6d8
UniqueId_MsgId=ISCA
//have control start link timer;
SleepTimer=1000
OptionTag=0000
//0:SMPP;1:CIMD;
ProtocolFlag=0
//0:first bill code last addr; 1:first addr last bill code;
//0:4100-1100-1681100; 1:4100-1684100-1100
BillCodeAddressConvert=1
[Segment]
SegmentNumber=9
Segment1=13500000000,13599999999,111,0
Segment2=13600000000,13699999999,222,0
Segment3=13700000000,13799999999,333,0
Segment4=13800000000,13899999999,444,0
Segment5=13900000000,13999999999,555,0
Segment6=13000000000,13099999999,666,0
Segment7=13100000000,13199999999,777,0
Segment8=13200000000,13299999999,888,0
Segment9=13300000000,13399999999,999,0
[ServiceCode]
//!:非完全匹配;
//%:Smp协议发送;
CodeFrom=!PHB D,+XXTQ,168
CodeTo=%CPHB D,%TQ,169
SendUdpSmp=172.19.100.168,7912
[SMC]
//0:two link and the same user/pwd; 1:two link and different user/pwd;
GatewayMode=0
GatewayNumber=1
//control send is void
SendLinkNumber=1
Gateway1=3,14,172.19.100.168,2000,168,168,168,52,1
Gateway2=3,14,172.19.100.168,2201,DL802,P802,AGENT,52,2
GatewayNumberRX=1
GatewayNumberTX=1
Gateway1RX=3,14,172.19.100.168,2000,168,168,168,52,1
Gateway1TX=3,14,172.19.100.168,2000,168,168,168,52,1
Gateway2RX=3,14,172.19.100.168,2201,DL802,P802,AGENT,52,2
Gateway2TX=3,14,172.19.100.168,2201,DL802,P802,AGENT,52,2
TEST_SER_ALIVE=on
//1:1-trust 0-no trust;2:rsp_time;3:1-num msg rsp throw away;4:free busy;
//control send is void
TrustSend=0,300,2,1
RepeatNum=1
//0xFF-unchange
Priority=1
//0xFF-unchange
StatusReport=0
//0xFF-unchange; only use in smp;
SmpDcsCode=255
//send dest address len;
SendSmcAddressLen=11
//0:不动,1:替换,2:追加; ton; npi; 原地址;处理地址长度限制
OutSurceAddress=1,1,1,86168,11
//0:不动,1:追加; ton; npi; 86;
OutDestAddress=1,1,1,86
0:不动,1:尾部去掉,2:去86后留3位; 处理地址长度限制
InDestAddress=2,3,14
UnChangeAddr=166,169
//*转换
AddAddressNum=3
AddAddress1=31:4100,4101
AddAddress2=41:4104
AddAddress3=51:4109,4171
//转换FreeFee mobile
SendUdpSmp=0,172.19.100.168,7912
FreeMobileNumber=13971640801,13971272512,13971166457
TypeAddress=1860
TypeCode=0000
SendOutControl=0
LinkSmcClassNum=2
LinkSmcClass1=1:1,2,3,4,5
LinkSmcClass2=2:6,7,8,9
[CIMD]
UDPSMCIPAddr=172.19.100.168,2001
[ReportConfig]
//处理状态报告
StatusReportFlag=1
StatusReportAddressNum=2
//ip地址,ip端口号,权限(0:有效,255:无效)
StatusReportAddress1=172.19.100.168,2101,0
StatusReportAddress2=172.19.100.168,2101,0
EsmSriTag=32,4
[IED]
TEST_CLI_ALIVE=on
TCPIPTestFlag=0
ReadConfig=1
IedClientNum=4
//255:不下发,管理接入
IedClient1=000,BOSS,BOSS,MANAGE,52,255
IedClient2=901,ISPC901,P901,ISPC,52,0
IedClient3=902,ISPC902,P902,ISPC,52,0
IedClient4=903,DL802,P802,AGENT,52,0
[SMP]
UDPLocalSmcPort=2102
UDPLocalSmePort=2103
RemoteSendFromSmc=0
UDPRemoteIPAddr=172.19.100.168,2001
[Timer]
SEND_MSG_SER=10
SEND_MSG_CLI=13
PROCESS_SMPUDP=13
TRANS_CIMD=13
TRANS_SMGP=13
ALIVE_SER=15000
ALIVE_CLI=15000
RELINK_TIME=1000
RELINK_FLAG=on
SET_STATUS_TIME=1000
[BillCodeConver]
BillCodeNum=4
//业务类型:资费类型:资费代码-业务类型,业务类型......
BillCode1=4100:1:20-4100,4101,4102,4103
BillCode2=4200:1:20-4200,4201
BillCode3=4104:1:20-4300,4301,1010,4303
BillCode4=4999:1:20-4999
OtherCode=5000:1:20
[TraceTimeMobile]
MobileNumber=13971640801,13501370969
LinkAlertMobile=13791640801,13501370969
AlertEveryCount=10
BillCode=1010
[RemoteTrace]
ReTraceFlag=off
ReTraceRemoteIP=168.160.234.93,7310
ReTraceLocalIP=168.160.234.97,7910
ReTraceLocalName=InterFace
[Debug]
TestTag=TEST,XXPT
ReStart=off
ViewApplication=on
TraceApplication=on
DumpMessage=on
TraceTimeSpan=on
LogDirectory=C:/log
SaveLogTime=3
FileNameNum=9999
FileLineNum=10000