public void Test2()
        {
            JT808FormatterFactory jT808FormatterFactory = new JT808FormatterFactory();

            jT808FormatterFactory.SetMap <JT808_0x9999>();
            Assert.Contains(jT808FormatterFactory.FormatterDict, f => f.Key == typeof(JT808_0x9999).GUID);
        }
示例#2
0
 public JT808GlobalConfig()
 {
     Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
     MsgSNDistributed     = new DefaultMsgSNDistributedImpl();
     Compress             = new JT808GZipCompressImpl();
     SplitPackageStrategy = new DefaultSplitPackageStrategyImpl();
     SkipCRCCode          = false;
     MsgIdFactory         = new JT808MsgIdFactory();
     Encoding             = Encoding.GetEncoding("GBK");
     FormatterFactory     = new JT808FormatterFactory();
 }
示例#3
0
 protected GlobalConfigBase()
 {
     Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
     MsgSNDistributed            = new DefaultMsgSNDistributedImpl();
     Compress                    = new JT808GZipCompressImpl();
     SplitPackageStrategy        = new DefaultSplitPackageStrategyImpl();
     SkipCRCCode                 = false;
     MsgIdFactory                = new JT808MsgIdFactory();
     Encoding                    = Encoding.GetEncoding("GBK");
     FormatterFactory            = new JT808FormatterFactory();
     JT808_0X0200_Custom_Factory = new JT808_0x0200_Custom_Factory();
     JT808_0X8103_Custom_Factory = new JT808_0x8103_Custom_Factory();
     TerminalPhoneNoLength       = 12;
 }
        public void Test1()
        {
            JT808FormatterFactory jT808FormatterFactory = new JT808FormatterFactory();

            Assert.Contains(jT808FormatterFactory.FormatterDict, f => f.Key == typeof(JT808Package).GUID);
        }