Beispiel #1
0
        private void runImport(ITransactionCommitter transactionComitter, string filename, int impNr, importType type)
        {
            if (type == importType.Full)
            {
                CleanAchskopieTables(transactionComitter);
            }
            {
                AxisImportDataHandler dataHandler = getImportDataHandler(transactionComitter, axisImportMonitor,
                                                                         impNr, AxisImportPass.Achsen, type);
                AxisReader2 axisReader = new AxisReader2(filename, dataHandler);
                axisReader.Parse();

                Statistics += dataHandler.Statistics;
            }
            if (type == importType.Full)
            {
                transactionComitter.ForceNext();
            }
            {
                AxisImportDataHandler dataHandler = getImportDataHandler(transactionComitter, axisImportMonitor,
                                                                         impNr, AxisImportPass.Segmente, type);

                AxisReader2 axisReader = new AxisReader2(filename, dataHandler);
                axisReader.Parse();

                Statistics += dataHandler.Statistics;
            }
            if (type == importType.Full)
            {
                transactionComitter.ForceNext();
            }
            {
                AxisImportDataHandler dataHandler = getImportDataHandler(transactionComitter, axisImportMonitor,
                                                                         impNr, AxisImportPass.Sektoren, type);

                AxisReader2 axisReader = new AxisReader2(filename, dataHandler);
                axisReader.Parse();

                Statistics += dataHandler.Statistics;
            }
            if (type == importType.Full)
            {
                transactionComitter.ForceNext();
            }
        }
Beispiel #2
0
        public void ParseFullAxisFileTestGS()
        {
            AchsenCollectedData dataIncr;

            {
                String filename = @"C:\temp\emsg_achsen\Achsdaten_full_2011_09_01\20111219135120_Axis_GS_Full_2011_09_01.xtf";

                AchsenCollectedData data = new AchsenCollectedData();

                AxisReader2 axisReader = new AxisReader2(filename, data);

                axisReader.Parse();

                dataIncr = data;
            }

            Debug.WriteLine("Statistics: " + dataIncr.Statistics());
        }
Beispiel #3
0
        public void ParseAxisFileTest()
        {
            AchsenCollectedData dataIncr;

            {
                String filename = @"InterlisParser\TestData\2012_01_04_export_Achsen_CH_incr_1.09.2011_19.12.2011.xtf";

                AchsenCollectedData data = new AchsenCollectedData();

                AxisReader2 axisReader = new AxisReader2(filename, data);

                axisReader.Parse();

                dataIncr = data;
            }

            Debug.WriteLine("Statistics: " + dataIncr.Statistics());

            Assert.AreEqual(29, dataIncr.achsenDict.Count);
            Assert.AreEqual(57, dataIncr.achsenSegmentDict.Count);


            var ai = dataIncr.achsenToSegmentDict[new Guid("b96a78e8-2b24-6a43-b23b-55e2b6d269ca")];
        }