Example #1
0
 public override void Parse(ActionParser parser)
 {
     if (_hasUnits)
     {
         Units = parser.ReadFourByteString();
     }
     Value = parser.ReadDouble();
 }
Example #2
0
        public override void Parse(ActionParser parser)
        {
            if (parser.PreSix)
            {
                _classID2 = parser.ReadTokenOrString();
                DebugOutput.Dump("ClassID2: " + _classID2);

                int numberOfItems = parser.ReadInt32();
                DebugOutput.Dump("NumberOfItems: " + numberOfItems);
            }
            else
            {
                int numberOfItems = parser.ReadInt32();
                DebugOutput.Dump("NumberOfItems: " + numberOfItems);

                _classID = parser.ReadUnicodeString();
                DebugOutput.Dump("ClassID: " + _classID);

                _classID2 = parser.ReadTokenOrString();
                DebugOutput.Dump("ClassID2: " + _classID2);
            }

            int numberOfFields = parser.ReadInt32();

            DebugOutput.Dump("NumberOfFields: " + numberOfFields);

            for (int i = 0; i < numberOfFields; i++)
            {
                string key  = parser.ReadTokenOrString();
                string type = parser.ReadFourByteString();
                _units = parser.ReadFourByteString();

                DebugOutput.Dump("key: {0} ({1}) {2}", key, type, _units);

                int numberOfItems = parser.ReadInt32();
                DebugOutput.Dump("NumberOfItems2: " + numberOfItems);

                switch (type)
                {
                case "UnFl":
                    for (int j = 0; j < numberOfItems; j++)
                    {
                        double val = parser.ReadDouble();

                        Coordinate <double> c;
                        if (i == 0)
                        {
                            c = new Coordinate <double>();
                            _value.Add(c);
                            c.X = val;
                        }
                        else
                        {
                            _value[j].Y = val;
                        }
                    }
                    break;

                default:
                    Console.WriteLine("ObAr:Unknown type: " + type);
                    break;
                }
            }
        }
Example #3
0
 public override void Parse(ActionParser parser)
 {
     if (_hasUnits)
     {
       Units = parser.ReadFourByteString();
     }
       Value = parser.ReadDouble();
 }
Example #4
0
        public override void Parse(ActionParser parser)
        {
            if (parser.PreSix)
            {
              _classID2 = parser.ReadTokenOrString();
              DebugOutput.Dump("ClassID2: " + _classID2);

              int numberOfItems = parser.ReadInt32();
              DebugOutput.Dump("NumberOfItems: " + numberOfItems);
            }
              else
            {
              int numberOfItems = parser.ReadInt32();
              DebugOutput.Dump("NumberOfItems: " + numberOfItems);

              _classID = parser.ReadUnicodeString();
              DebugOutput.Dump("ClassID: " + _classID);

              _classID2 = parser.ReadTokenOrString();
              DebugOutput.Dump("ClassID2: " + _classID2);
            }

              int numberOfFields = parser.ReadInt32();
              DebugOutput.Dump("NumberOfFields: " + numberOfFields);

              for (int i = 0; i < numberOfFields; i++)
            {
              string key = parser.ReadTokenOrString();
              string type = parser.ReadFourByteString();
              _units = parser.ReadFourByteString();

              DebugOutput.Dump("key: {0} ({1}) {2}", key, type, _units);

              int numberOfItems = parser.ReadInt32();
              DebugOutput.Dump("NumberOfItems2: " + numberOfItems);

              switch (type)
            {
            case "UnFl":
              for (int j = 0; j < numberOfItems; j++)
            {
              double val = parser.ReadDouble();

              Coordinate<double> c;
              if (i == 0)
            {
              c = new Coordinate<double>();
              _value.Add(c);
              c.X = val;
            }
              else
            {
              _value[j].Y = val;
            }
            }
              break;
            default:
              Console.WriteLine("ObAr:Unknown type: " + type);
              break;
            }
            }
        }