示例#1
0
 public virtual double imethod_8()
 {
     try
     {
         if (!this.method_2())
         {
             Class951.Enum41 enum41 = (Class951.Enum41) this.memoryStream_0.ReadByte();
             if (Class951.Enum41.const_6 == enum41)
             {
                 return(Class1045.smethod_8((Stream)this.memoryStream_0));
             }
             if (Class951.Enum41.const_18 == enum41)
             {
                 this.method_0();
             }
         }
         if (!this.method_2())
         {
             throw new Exception0("Broken double value!");
         }
         return(this.interface8_0.imethod_8());
     }
     catch (FormatException ex)
     {
         throw new Exception0("Broken double value!", (Exception)ex);
     }
 }
示例#2
0
 public virtual int imethod_12(string[] values, int[] indexes)
 {
     if (!this.method_2())
     {
         Class951.Enum41 enum41 = (Class951.Enum41) this.memoryStream_0.ReadByte();
         if (Class951.Enum41.const_18 == enum41)
         {
             this.method_0();
         }
         else if (Class951.Enum41.const_21 == enum41)
         {
             int num = Class1045.smethod_7((Stream)this.memoryStream_0);
             if (indexes != null)
             {
                 for (int index = indexes.Length - 1; index >= 0; --index)
                 {
                     if (num == indexes[index])
                     {
                         return(num);
                     }
                 }
             }
             else if (num >= 0 && num < values.Length)
             {
                 return(num);
             }
         }
     }
     if (!this.method_2())
     {
         throw new Exception0("Enum value broken");
     }
     return(this.interface8_0.imethod_12(values, indexes));
 }
示例#3
0
        public virtual Vector3D imethod_19()
        {
            Vector3D vector3D = new Vector3D();

            if (!this.method_2())
            {
                Class951.Enum41 enum41 = (Class951.Enum41) this.memoryStream_0.ReadByte();
                if (Class951.Enum41.const_20 == enum41)
                {
                    vector3D.X = Class1045.smethod_8((Stream)this.memoryStream_0);
                    vector3D.Y = Class1045.smethod_8((Stream)this.memoryStream_0);
                    vector3D.Z = Class1045.smethod_8((Stream)this.memoryStream_0);
                }
                else
                {
                    if (Class951.Enum41.const_18 != enum41)
                    {
                        throw new Exception0("Vector type requested");
                    }
                    this.method_0();
                }
            }
            if (this.method_2())
            {
                vector3D = this.interface8_0.imethod_19();
            }
            return(vector3D);
        }
示例#4
0
        public virtual Point3D imethod_18()
        {
            Point3D point3D = new Point3D();

            if (!this.method_2())
            {
                Class951.Enum41 enum41 = (Class951.Enum41) this.memoryStream_0.ReadByte();
                if (Class951.Enum41.const_19 == enum41)
                {
                    point3D.X = Class1045.smethod_8((Stream)this.memoryStream_0);
                    point3D.Y = Class1045.smethod_8((Stream)this.memoryStream_0);
                    point3D.Z = Class1045.smethod_8((Stream)this.memoryStream_0);
                }
                else
                {
                    if (Class951.Enum41.const_18 != enum41)
                    {
                        throw new Exception0("Position type requested");
                    }
                    this.method_0();
                }
            }
            if (this.method_2())
            {
                point3D = this.interface8_0.imethod_18();
            }
            return(point3D);
        }
示例#5
0
 public virtual void imethod_18(Vector3D vector)
 {
     this.memoryStream_0.WriteByte((byte)20);
     Class1045.smethod_16((Stream)this.memoryStream_0, vector.X);
     Class1045.smethod_16((Stream)this.memoryStream_0, vector.Y);
     Class1045.smethod_16((Stream)this.memoryStream_0, vector.Z);
 }
示例#6
0
 public virtual void imethod_17(Point3D position)
 {
     this.memoryStream_0.WriteByte((byte)19);
     Class1045.smethod_16((Stream)this.memoryStream_0, position.X);
     Class1045.smethod_16((Stream)this.memoryStream_0, position.Y);
     Class1045.smethod_16((Stream)this.memoryStream_0, position.Z);
 }
示例#7
0
 public virtual void imethod_6(ns9.Class80 entity)
 {
     this.memoryStream_0.WriteByte((byte)12);
     if (entity == null)
     {
         Class1045.smethod_9((Stream)this.memoryStream_0, -1);
     }
     else
     {
         Class1045.smethod_9((Stream)this.memoryStream_0, entity.Index);
     }
 }
示例#8
0
文件: Class886.cs 项目: 15831944/WW
        public void Write()
        {
            this.method_0();
            this.stream_0.Write(Class886.byte_0, 0, Class886.byte_0.Length);
            Stream1 stream1 = new Stream1(this.stream_0, (ushort)49345);

            Class1045.smethod_9((Stream)stream1, (int)this.memoryStream_0.Length);
            if (this.dxfHeader_0.AcadVersion > DxfVersion.Dxf21 && this.dxfHeader_0.AcadMaintenanceVersion > 3 || this.dxfHeader_0.AcadVersion > DxfVersion.Dxf27)
            {
                Class1045.smethod_9((Stream)stream1, 0);
            }
            stream1.Write(this.memoryStream_0.GetBuffer(), 0, (int)this.memoryStream_0.Length);
            Class1045.smethod_6(this.stream_0, stream1.Crc);
            this.stream_0.Write(Class886.byte_1, 0, Class886.byte_1.Length);
        }
示例#9
0
文件: Class794.cs 项目: 15831944/WW
 public static Interface8 smethod_4(
     Interface6 resolver,
     Interface7 subResolver,
     MemoryStream content)
 {
     try
     {
         int version = Class1045.smethod_7((Stream)content);
         return((Interface8) new Class951(resolver, subResolver, version, content));
     }
     catch (FormatException ex)
     {
         throw new Exception0("Failed to read SAT version number!", (Exception)ex);
     }
 }
示例#10
0
文件: Class794.cs 项目: 15831944/WW
 public static Interface9 smethod_6(
     Interface6 resolver,
     Interface7 subResolver,
     MemoryStream content,
     int version)
 {
     try
     {
         Class1045.smethod_9((Stream)content, version);
         return((Interface9) new Class950(resolver, subResolver, version, content));
     }
     catch (FormatException ex)
     {
         throw new Exception0("Failed to write SAT version number!", (Exception)ex);
     }
 }
示例#11
0
 public virtual void imethod_16(Class987 header)
 {
     Class1045.smethod_9((Stream)this.memoryStream_0, 0);
     Class1045.smethod_9((Stream)this.memoryStream_0, header.EntityCount);
     Class1045.smethod_9((Stream)this.memoryStream_0, this.int_0 != 21200 ? (this.int_0 != 21500 ? (this.int_0 != 21600 ? (this.int_0 != 21700 ? (this.int_0 != 21800 ? 0 : 12) : 4) : 8) : 24) : 26);
     if (this.int_0 < Class250.int_28)
     {
         return;
     }
     this.WriteString(header.Product);
     this.WriteString(header.AcisVersion);
     this.WriteString(header.method_1());
     this.imethod_7(header.MmPerUnit);
     this.imethod_7(header.AbsoluteResolution);
     this.imethod_7(header.NormalResolution);
 }
示例#12
0
文件: Class992.cs 项目: 15831944/WW
        public static ulong smethod_5(Stream stream)
        {
            int   num1 = 0;
            byte  num2 = Class1045.smethod_2(stream);
            ulong num3 = (ulong)((int)num2 & (int)sbyte.MaxValue);

            if (((int)num2 & 128) != 0)
            {
                byte num4;
                do
                {
                    num1 += 7;
                    num4  = Class1045.smethod_2(stream);
                    num3 |= (ulong)((int)num4 & (int)sbyte.MaxValue) << num1;
                }while (((int)num4 & 128) != 0);
            }
            return(num3);
        }
示例#13
0
        public virtual void imethod_17(Class987 header)
        {
            header.NumberOfRecords = Class1045.smethod_7((Stream)this.memoryStream_0);
            header.EntityCount     = Class1045.smethod_7((Stream)this.memoryStream_0);
            int num = Class1045.smethod_7((Stream)this.memoryStream_0);

            header.HistorySaved = num != 0;
            if (this.int_0 < Class250.int_28)
            {
                return;
            }
            header.Product     = this.ReadString();
            header.AcisVersion = this.ReadString();
            header.method_0(this.ReadString());
            header.MmPerUnit          = this.imethod_8();
            header.AbsoluteResolution = this.imethod_8();
            header.NormalResolution   = this.imethod_8();
        }
示例#14
0
文件: Class992.cs 项目: 15831944/WW
        public static int smethod_4(Stream stream)
        {
            int  num1 = 15;
            byte num2 = Class1045.smethod_2(stream);
            byte num3 = Class1045.smethod_2(stream);
            bool flag = ((int)num3 & 128) == 0;
            int  num4 = (int)num2 | ((int)num3 & (int)sbyte.MaxValue) << 8;

            while (!flag)
            {
                byte num5 = Class1045.smethod_2(stream);
                byte num6 = Class1045.smethod_2(stream);
                flag = ((int)num6 & 128) == 0;
                int num7 = num4 | (int)num5 << num1;
                int num8 = num1 + 8;
                num4 = num7 | ((int)num6 & (int)sbyte.MaxValue) << num8;
                num1 = num8 + 7;
            }
            return(num4);
        }
示例#15
0
 public virtual bool imethod_16(bool silentMode)
 {
     Class951.Enum41 enum41 = (Class951.Enum41) this.memoryStream_0.ReadByte();
     if (Class951.Enum41.const_17 != enum41)
     {
         if (!silentMode)
         {
             throw new Exception0("Broken terminator!");
         }
         if (enum41 == Class951.Enum41.const_12)
         {
             Class1045.smethod_7((Stream)this.memoryStream_0);
         }
         return(false);
     }
     if (this.method_2())
     {
         this.method_1();
     }
     return(true);
 }
示例#16
0
        public virtual void WriteString(string value)
        {
            int length = value.Length;

            if (length <= (int)byte.MaxValue)
            {
                this.memoryStream_0.WriteByte((byte)7);
                this.memoryStream_0.WriteByte((byte)length);
            }
            else if (length <= (int)ushort.MaxValue)
            {
                this.memoryStream_0.WriteByte((byte)8);
                Class1045.smethod_4((Stream)this.memoryStream_0, (short)length);
            }
            else
            {
                this.memoryStream_0.WriteByte((byte)9);
                Class1045.smethod_9((Stream)this.memoryStream_0, length);
            }
            this.memoryStream_0.Write(Encodings.Ascii.GetBytes(value), 0, value.Length);
        }
示例#17
0
文件: Class1033.cs 项目: 15831944/WW
        public void Write()
        {
            this.method_0();
            this.stream_0.Write(Class1033.byte_0, 0, Class1033.byte_0.Length);
            Stream1 stream1 = new Stream1(this.stream_0, (ushort)49345);

            Class1045.smethod_9((Stream)stream1, (int)this.memoryStream_0.Length);
            if (this.dxfModel_0.Header.AcadVersion > DxfVersion.Dxf21 && this.dxfModel_0.Header.AcadMaintenanceVersion > 3 || this.dxfModel_0.Header.AcadVersion > DxfVersion.Dxf27)
            {
                Class1045.smethod_9((Stream)stream1, 0);
            }
            byte[] buffer = this.memoryStream_0.GetBuffer();
            stream1.Write(buffer, 0, (int)this.memoryStream_0.Length);
            Class1045.smethod_6(this.stream_0, stream1.Crc);
            this.stream_0.Write(Class1033.byte_1, 0, Class1033.byte_1.Length);
            if (this.dxfModel_0.Header.AcadVersion < DxfVersion.Dxf18)
            {
                return;
            }
            Class1045.smethod_9(this.stream_0, 0);
            Class1045.smethod_9(this.stream_0, 0);
        }
示例#18
0
        private void method_10()
        {
            int          sectionStartPosition1 = (int)Class745.smethod_0(this.int_0);
            int          num1 = sectionStartPosition1 + (int)this.memoryStream_0.Length;
            int          sectionStartPosition2 = num1 + (int)this.memoryStream_4.Length;
            int          sectionStartPosition3 = sectionStartPosition2 + (int)this.memoryStream_1.Length;
            int          sectionStartPosition4 = sectionStartPosition3 + (int)this.memoryStream_2.Length + (int)this.memoryStream_5.Length;
            MemoryStream memoryStream          = new MemoryStream();
            Interface29  streamWriter          = Class724.Create(this.dxfVersion_0, (Stream)memoryStream, this.encoding_0);

            streamWriter.imethod_13(Encodings.Ascii.GetBytes(this.dxfModel_0.Header.AcadVersionString), 0, 6);
            Interface29 nterface29 = streamWriter;

            byte[] numArray = new byte[7];
            numArray[5] = (byte)15;
            numArray[6] = (byte)1;
            byte[] bytes = numArray;
            nterface29.imethod_12(bytes);
            streamWriter.imethod_19(num1);
            streamWriter.imethod_11((byte)0);
            streamWriter.imethod_11((byte)0);
            int num2 = (int)Class952.smethod_1(this.dxfModel_0.Header.DrawingCodePage);

            streamWriter.imethod_13(LittleEndianBitConverter.GetBytes((short)num2), 0, 2);
            streamWriter.imethod_13(LittleEndianBitConverter.GetBytes(this.int_0), 0, 4);
            long position = this.stream_0.Position;

            this.method_11(streamWriter, (byte)0, sectionStartPosition1, (int)this.memoryStream_0.Length);
            this.method_11(streamWriter, (byte)1, sectionStartPosition2, (int)this.memoryStream_1.Length);
            this.method_11(streamWriter, (byte)2, sectionStartPosition4, (int)this.memoryStream_6.Length);
            this.method_11(streamWriter, (byte)3, 0, 0);
            this.method_11(streamWriter, (byte)4, sectionStartPosition3, (int)this.memoryStream_2.Length);
            streamWriter.Flush();
            Stream1 stream1 = new Stream1(this.stream_0, (ushort)49345);

            stream1.Write(memoryStream.GetBuffer(), 0, (int)memoryStream.Length);
            Class1045.smethod_6(this.stream_0, stream1.Crc);
            this.stream_0.Write(Class800.byte_4, 0, Class800.byte_4.Length);
        }
示例#19
0
        public virtual string ReadString()
        {
            try
            {
                switch ((Class951.Enum41) this.memoryStream_0.ReadByte())
                {
                case Class951.Enum41.const_7:
                    byte   num1      = (byte)this.memoryStream_0.ReadByte();
                    byte[] numArray1 = new byte[(int)num1];
                    this.memoryStream_0.Read(numArray1, 0, (int)num1);
                    return(Encodings.Ascii.GetString(numArray1, 0, numArray1.Length));

                case Class951.Enum41.const_8:
                    short  num2      = Class1045.smethod_3((Stream)this.memoryStream_0);
                    byte[] numArray2 = new byte[(int)num2];
                    this.memoryStream_0.Read(numArray2, 0, (int)num2);
                    return(Encodings.Ascii.GetString(numArray2, 0, numArray2.Length));

                case Class951.Enum41.const_9:
                    int    count1    = Class1045.smethod_7((Stream)this.memoryStream_0);
                    byte[] numArray3 = new byte[count1];
                    this.memoryStream_0.Read(numArray3, 0, count1);
                    return(Encodings.Ascii.GetString(numArray3, 0, numArray3.Length));

                case Class951.Enum41.const_18:
                    int    count2    = Class1045.smethod_7((Stream)this.memoryStream_0);
                    byte[] numArray4 = new byte[count2];
                    this.memoryStream_0.Read(numArray4, 0, count2);
                    return(Encodings.Ascii.GetString(numArray4, 0, numArray4.Length));

                default:
                    throw new Exception0("String broken!");
                }
            }
            catch (FormatException ex)
            {
                throw new Exception0("String length broken!", (Exception)ex);
            }
        }
示例#20
0
        public void Write()
        {
            this.method_0();
            this.stream_0.Write(Class654.byte_0, 0, Class654.byte_0.Length);
            Stream1 stream1 = new Stream1(this.stream_0, (ushort)49345);
            int     num     = 4 + (int)this.interface29_0.Stream.Length + 2 + 8;

            Class1045.smethod_9((Stream)stream1, num);
            stream1.Write(this.memoryStream_0.GetBuffer(), 0, (int)this.memoryStream_0.Length);
            Class1045.smethod_6(this.stream_0, stream1.Crc);
            if (this.dxfModel_0.Header.AcadVersion >= DxfVersion.Dxf14)
            {
                this.stream_0.WriteByte((byte)147);
                this.stream_0.WriteByte((byte)134);
                this.stream_0.WriteByte((byte)187);
                this.stream_0.WriteByte((byte)0);
                this.stream_0.WriteByte((byte)208);
                this.stream_0.WriteByte((byte)56);
                this.stream_0.WriteByte((byte)131);
                this.stream_0.WriteByte((byte)87);
            }
            this.stream_0.Write(Class654.byte_1, 0, Class654.byte_1.Length);
        }
示例#21
0
 public virtual void imethod_13(Interface39 values)
 {
     if (!this.method_2())
     {
         Class951.Enum41 enum41 = (Class951.Enum41) this.memoryStream_0.ReadByte();
         if (Class951.Enum41.const_18 == enum41)
         {
             this.method_0();
         }
         else if (Class951.Enum41.const_4 == enum41)
         {
             int num = Class1045.smethod_7((Stream)this.memoryStream_0);
             if (num != 0 || num != 1)
             {
                 throw new Exception0("Logical value broken");
             }
             values.Value = num != 0;
         }
         else if (Class951.Enum41.const_10 == enum41)
         {
             values.Value = true;
         }
         else
         {
             if (Class951.Enum41.const_11 != enum41)
             {
                 throw new Exception0("Logical value broken");
             }
             values.Value = false;
         }
     }
     if (!this.method_2())
     {
         return;
     }
     this.interface8_0.imethod_13(values);
 }
示例#22
0
        private static Interface8 smethod_0(
            Interface6 resolver,
            Interface7 subResolver,
            int version,
            MemoryStream stream)
        {
            int    num   = Class1045.smethod_7((Stream)stream);
            string empty = string.Empty;

            for (int index = 0; index < num; ++index)
            {
                empty += (string)(object)(char)stream.ReadByte();
            }
            Class251.Class254 marker = new Class251.Class254(empty);
            if (version < Class250.int_7)
            {
                return((Interface8) new Class251(resolver, subResolver, version, marker));
            }
            if (version < Class250.int_63)
            {
                return((Interface8) new Class252(resolver, subResolver, version, marker));
            }
            return((Interface8) new Class253(resolver, subResolver, version, marker));
        }
示例#23
0
        internal bool method_13(Stream stream)
        {
            bool flag1    = false;
            long position = stream.Position;
            bool flag2    = true;

            for (int index = 0; index < DxfModelerGeometry.BinaryFilePrefix.Length; ++index)
            {
                int num = stream.ReadByte();
                if (num < 0 || (int)DxfModelerGeometry.BinaryFilePrefix[index] != num)
                {
                    flag2 = false;
                    break;
                }
            }
            if (flag2)
            {
                this.memoryStream_0 = new MemoryStream();
                int num = Class1045.smethod_7(stream);
                Class1045.smethod_9((Stream)this.memoryStream_0, num);
                bool     flag3     = false;
                byte[][] numArray1 = num < 21800 ? DxfModelerGeometry.byte_2 : DxfModelerGeometry.byte_3;
label_23:
                byte b;
                while (!flag3 && !DxfModelerGeometry.smethod_2(stream, out b))
                {
                    this.memoryStream_0.WriteByte(b);
                    if ((int)b == (int)numArray1[0][0])
                    {
                        int index1 = 0;
                        int index2 = 1;
                        while (true)
                        {
                            bool flag4 = true;
                            for (byte[] numArray2 = numArray1[index1]; index2 < numArray2.Length; ++index2)
                            {
                                if (!DxfModelerGeometry.smethod_2(stream, out b))
                                {
                                    this.memoryStream_0.WriteByte(b);
                                    if ((int)b != (int)numArray2[index2])
                                    {
                                        flag4 = false;
                                        break;
                                    }
                                }
                                else
                                {
                                    flag4 = false;
                                    break;
                                }
                            }
                            if (flag4)
                            {
                                ++index1;
                                index2 = 0;
                                if (index1 < numArray1.GetLength(0))
                                {
                                    if (!DxfModelerGeometry.smethod_2(stream, out b))
                                    {
                                        this.memoryStream_0.WriteByte(b);
                                        switch (b)
                                        {
                                        case 13:
                                        case 14:
                                            if (!DxfModelerGeometry.smethod_2(stream, out b))
                                            {
                                                this.memoryStream_0.WriteByte(b);
                                                continue;
                                            }
                                            goto label_23;

                                        case 45:
                                            continue;

                                        default:
                                            goto label_23;
                                        }
                                    }
                                    else
                                    {
                                        goto label_23;
                                    }
                                }
                                else
                                {
                                    break;
                                }
                            }
                            else
                            {
                                goto label_23;
                            }
                        }
                        flag3 = true;
                        flag1 = true;
                    }
                }
                this.memoryStream_0.Seek(0L, SeekOrigin.Begin);
            }
            else
            {
                stream.Seek(position, SeekOrigin.Begin);
                long   length   = stream.Length - position;
                byte[] numArray = new byte[length];
                stream.Read(numArray, 0, (int)length);
                this.string_1 = Encodings.Ascii.GetString(numArray, 0, (int)length);
                flag1         = true;
            }
            return(flag1);
        }
示例#24
0
文件: Class887.cs 项目: 15831944/WW
        public void method_0()
        {
            DxfHeader  header  = this.class374_0.Model.Header;
            DxfVersion version = this.class374_0.Version;

            this.interface30_0.imethod_19(16);
            this.interface30_0.imethod_3();
            int num1 = this.interface30_0.imethod_43();

            if (version > DxfVersion.Dxf21 && this.class374_0.Model.Header.AcadMaintenanceVersion > 3 || version > DxfVersion.Dxf27)
            {
                this.interface30_0.imethod_43();
            }
            long num2 = this.interface30_0.imethod_3();

            if (version >= DxfVersion.Dxf21)
            {
                int  num3 = this.interface30_0.imethod_43();
                long stringStreamEndBitPosition = num2 + (long)num3 - 1L;
                this.interface30_2 = Class444.Create(version, this.dwgReader_0, (Stream)Class1045.smethod_1(this.interface30_0.Stream, this.interface30_0.Stream.Length, this.dwgReader_0.MemoryPageCache), false);
                this.interface30_2.imethod_5(stringStreamEndBitPosition);
                this.list_0.Add((IDisposable)this.interface30_2.Stream);
                this.interface30_3 = Class444.Create(version, this.dwgReader_0, (Stream)Class1045.smethod_1(this.interface30_0.Stream, this.interface30_0.Stream.Length, this.dwgReader_0.MemoryPageCache), false);
                this.interface30_3.imethod_4(stringStreamEndBitPosition + 1L);
                this.list_0.Add((IDisposable)this.interface30_3.Stream);
                this.interface30_0 = (Interface30) new Class1048(this.interface30_0, this.interface30_2, this.interface30_3);
            }
            if (version > DxfVersion.Dxf24)
            {
                header.RequiredVersions = this.interface30_0.imethod_12();
            }
            this.interface30_0.imethod_8();
            this.interface30_0.imethod_8();
            this.interface30_0.imethod_8();
            this.interface30_0.imethod_8();
            this.interface30_0.ReadString();
            this.interface30_0.ReadString();
            this.interface30_0.ReadString();
            this.interface30_0.ReadString();
            this.interface30_0.imethod_11();
            this.interface30_0.imethod_11();
            if (this.class374_0.IsVersion13Or14)
            {
                int num4 = (int)this.interface30_0.imethod_14();
            }
            if (version < DxfVersion.Dxf18)
            {
                this.class374_0.CurrentViewportHandle = this.interface30_0.imethod_32(false);
            }
            header.AssociatedDimensions          = this.interface30_0.imethod_6();
            header.UpdateDimensionsWhileDragging = this.interface30_0.imethod_6();
            if (this.class374_0.IsVersion13Or14)
            {
                header.DimSav = this.interface30_0.imethod_6();
            }
            header.PolylineLineTypeGeneration = (PolylineLineTypeGeneration)this.interface30_0.imethod_7();
            header.OrthoMode                 = this.interface30_0.imethod_6();
            header.RegenerationMode          = this.interface30_0.imethod_6();
            header.FillMode                  = this.interface30_0.imethod_6();
            header.QuickTextMode             = this.interface30_0.imethod_6();
            header.PaperSpaceLineTypeScaling = (PaperSpaceLineTypeScaling)this.interface30_0.imethod_7();
            header.LimitCheckingOn           = this.interface30_0.imethod_6();
            if (this.class374_0.IsVersion13Or14)
            {
                this.interface30_0.imethod_6();
            }
            if (version >= DxfVersion.Dxf18)
            {
                this.interface30_0.imethod_6();
            }
            header.UserTimer               = this.interface30_0.imethod_6();
            header.SketchPolylines         = this.interface30_0.imethod_6();
            header.AngularDirection        = (AngularDirection)this.interface30_0.imethod_7();
            header.ShowSplineControlPoints = this.interface30_0.imethod_6();
            if (this.class374_0.IsVersion13Or14)
            {
                this.interface30_0.imethod_6();
                this.interface30_0.imethod_6();
            }
            header.MirrorText = this.interface30_0.imethod_6();
            header.WorldView  = this.interface30_0.imethod_6();
            if (this.class374_0.IsVersion13Or14)
            {
                this.interface30_0.imethod_6();
            }
            header.ShowModelSpace           = this.interface30_0.imethod_6();
            header.PaperSpaceLimitsChecking = this.interface30_0.imethod_6();
            header.RetainXRefDependentVisibilitySettings = this.interface30_0.imethod_6();
            if (this.class374_0.IsVersion13Or14)
            {
                this.interface30_0.imethod_6();
            }
            header.DisplaySilhouetteCurves = this.interface30_0.imethod_6();
            header.CreateEllipseAsPolyline = this.interface30_0.imethod_6();
            header.ProxyGraphics           = this.interface30_0.imethod_15();
            if (this.class374_0.IsVersion13Or14)
            {
                int num5 = (int)this.interface30_0.imethod_14();
            }
            header.SpatialIndexMaxTreeDepth = this.interface30_0.imethod_14();
            header.LinearUnitFormat         = (LinearUnitFormat)this.interface30_0.imethod_14();
            header.LinearUnitPrecision      = this.interface30_0.imethod_14();
            header.AngularUnit          = (AngularUnit)this.interface30_0.imethod_14();
            header.AngularUnitPrecision = this.interface30_0.imethod_14();
            if (this.class374_0.IsVersion13Or14)
            {
                header.ObjectSnapMode = (ObjectSnapMode)this.interface30_0.imethod_14();
            }
            header.AttributeVisibility = (AttributeVisibility)this.interface30_0.imethod_14();
            if (this.class374_0.IsVersion13Or14)
            {
                int num6 = (int)this.interface30_0.imethod_14();
            }
            header.PointDisplayMode = (PointDisplayMode)this.interface30_0.imethod_14();
            if (this.class374_0.IsVersion13Or14)
            {
                int num7 = (int)this.interface30_0.imethod_14();
            }
            if (version >= DxfVersion.Dxf18)
            {
                this.interface30_0.imethod_11();
                this.interface30_0.imethod_11();
                this.interface30_0.imethod_11();
            }
            header.UserShort1                  = this.interface30_0.imethod_14();
            header.UserShort2                  = this.interface30_0.imethod_14();
            header.UserShort3                  = this.interface30_0.imethod_14();
            header.UserShort4                  = this.interface30_0.imethod_14();
            header.UserShort5                  = this.interface30_0.imethod_14();
            header.NumberOfSplineSegments      = this.interface30_0.imethod_14();
            header.SurfaceDensityU             = this.interface30_0.imethod_14();
            header.SurfaceDensityV             = this.interface30_0.imethod_14();
            header.SurfaceType                 = this.interface30_0.imethod_14();
            header.SurfaceMeshTabulationCount1 = this.interface30_0.imethod_14();
            header.SurfaceMeshTabulationCount2 = this.interface30_0.imethod_14();
            header.SplineType                  = (SplineType)this.interface30_0.imethod_14();
            header.ShadeEdge = (ShadeEdge)this.interface30_0.imethod_14();
            header.ShadeDiffuseToAmbientPercentage = this.interface30_0.imethod_14();
            header.UnitMode                      = this.interface30_0.imethod_14();
            header.MaxViewportCount              = this.interface30_0.imethod_14();
            header.SurfaceIsolineCount           = this.interface30_0.imethod_14();
            header.CurrentMultilineJustification = (VerticalAlignment)this.interface30_0.imethod_14();
            header.TextQuality                   = this.interface30_0.imethod_14();
            header.LineTypeScale                 = this.interface30_0.imethod_8();
            header.TextHeightDefault             = this.interface30_0.imethod_8();
            header.TraceWidthDefault             = this.interface30_0.imethod_8();
            header.SketchIncrement               = this.interface30_0.imethod_8();
            header.FilletRadius                  = this.interface30_0.imethod_8();
            header.ThicknessDefault              = this.interface30_0.imethod_8();
            header.AngleBase                     = this.interface30_0.imethod_8();
            header.PointDisplaySize              = this.interface30_0.imethod_8();
            header.PolylineWidthDefault          = this.interface30_0.imethod_8();
            header.UserDouble1                   = this.interface30_0.imethod_8();
            header.UserDouble2                   = this.interface30_0.imethod_8();
            header.UserDouble3                   = this.interface30_0.imethod_8();
            header.UserDouble4                   = this.interface30_0.imethod_8();
            header.UserDouble5                   = this.interface30_0.imethod_8();
            header.ChamferDistance1              = this.interface30_0.imethod_8();
            header.ChamferDistance2              = this.interface30_0.imethod_8();
            header.ChamferLength                 = this.interface30_0.imethod_8();
            header.ChamferAngle                  = this.interface30_0.imethod_8();
            header.FacetResolution               = this.interface30_0.imethod_8();
            header.CurrentMultilineScale         = this.interface30_0.imethod_8();
            header.CurrentEntityLinetypeScale    = this.interface30_0.imethod_8();
            if (!this.class374_0.IsVersion21OrLater)
            {
                header.MenuFileName = this.interface30_0.ReadString();
            }
            header.CreateDateTime = this.interface30_0.imethod_28();
            header.UpdateDateTime = this.interface30_0.imethod_28();
            if (version >= DxfVersion.Dxf18)
            {
                this.interface30_0.imethod_11();
                this.interface30_0.imethod_11();
                this.interface30_0.imethod_11();
            }
            this.class374_0.Model.SummaryInfo.TotalEditingTime = this.interface30_0.imethod_48();
            header.UserElapsedTimeSpan                  = this.interface30_0.imethod_48();
            header.CurrentEntityColor                   = this.interface30_0.imethod_22();
            header.HandleSeed                           = this.interface30_1.imethod_32(false);
            this.class374_0.CurrentLayerHandle          = this.interface30_0.imethod_32(false);
            this.class374_0.TextStyleHandle             = this.interface30_0.imethod_32(false);
            this.class374_0.CurrentEntityLineTypeHandle = this.interface30_0.imethod_32(false);
            if (version >= DxfVersion.Dxf21)
            {
                long num8 = (long)this.interface30_0.imethod_32(false);
            }
            this.class374_0.CurrentDimensionStyleHandle = this.interface30_0.imethod_32(false);
            this.class374_0.CurrentMultilineStyleHandle = this.interface30_0.imethod_32(false);
            if (this.class374_0.IsVersion15OrLater)
            {
                header.ViewportDefaultViewScaleFactor = this.interface30_0.imethod_8();
            }
            header.PaperSpaceInsertionBase = this.interface30_0.imethod_39();
            header.PaperSpaceExtMin        = this.interface30_0.imethod_39();
            header.PaperSpaceExtMax        = this.interface30_0.imethod_39();
            header.PaperSpaceLimitsMin     = this.interface30_0.imethod_38();
            header.PaperSpaceLimitsMax     = this.interface30_0.imethod_38();
            header.PaperSpaceElevation     = this.interface30_0.imethod_8();
            header.PaperSpaceUcs.Origin    = this.interface30_0.imethod_39();
            header.PaperSpaceUcs.XAxis     = this.interface30_0.imethod_51();
            header.PaperSpaceUcs.YAxis     = this.interface30_0.imethod_51();
            if (!this.class374_0.IsVersion21OrLater)
            {
                this.class374_0.PaperSpaceUcsHandle = this.interface30_0.imethod_32(false);
            }
            if (this.class374_0.IsVersion15OrLater)
            {
                if (!this.class374_0.IsVersion21OrLater)
                {
                    long num3 = (long)this.interface30_0.imethod_32(false);
                }
                int num9 = (int)this.interface30_0.imethod_14();
                if (!this.class374_0.IsVersion21OrLater)
                {
                    long num10 = (long)this.interface30_0.imethod_32(false);
                }
                header.PaperSpaceUcs.OrthographicTopDOrigin    = this.interface30_0.imethod_51();
                header.PaperSpaceUcs.OrthographicBottomDOrigin = this.interface30_0.imethod_51();
                header.PaperSpaceUcs.OrthographicLeftDOrigin   = this.interface30_0.imethod_51();
                header.PaperSpaceUcs.OrthographicRightDOrigin  = this.interface30_0.imethod_51();
                header.PaperSpaceUcs.OrthographicFrontDOrigin  = this.interface30_0.imethod_51();
                header.PaperSpaceUcs.OrthographicBackDOrigin   = this.interface30_0.imethod_51();
            }
            header.InsertionBase = this.interface30_0.imethod_39();
            header.ExtMin        = this.interface30_0.imethod_39();
            header.ExtMax        = this.interface30_0.imethod_39();
            header.LimitsMin     = this.interface30_0.imethod_38();
            header.LimitsMax     = this.interface30_0.imethod_38();
            header.Elevation     = this.interface30_0.imethod_8();
            header.Ucs.Origin    = this.interface30_0.imethod_39();
            header.Ucs.XAxis     = this.interface30_0.imethod_51();
            header.Ucs.YAxis     = this.interface30_0.imethod_51();
            if (!this.class374_0.IsVersion21OrLater)
            {
                this.class374_0.UcsHandle = this.interface30_0.imethod_32(false);
            }
            if (this.class374_0.IsVersion15OrLater)
            {
                if (!this.class374_0.IsVersion21OrLater)
                {
                    long num3 = (long)this.interface30_0.imethod_32(false);
                }
                int num9 = (int)this.interface30_0.imethod_14();
                if (!this.class374_0.IsVersion21OrLater)
                {
                    long num10 = (long)this.interface30_0.imethod_32(false);
                }
                header.Ucs.OrthographicTopDOrigin    = this.interface30_0.imethod_51();
                header.Ucs.OrthographicBottomDOrigin = this.interface30_0.imethod_51();
                header.Ucs.OrthographicLeftDOrigin   = this.interface30_0.imethod_51();
                header.Ucs.OrthographicRightDOrigin  = this.interface30_0.imethod_51();
                header.Ucs.OrthographicFrontDOrigin  = this.interface30_0.imethod_51();
                header.Ucs.OrthographicBackDOrigin   = this.interface30_0.imethod_51();
                if (!this.class374_0.IsVersion21OrLater)
                {
                    header.DimensionStyleOverrides.PostFix = this.interface30_0.ReadString();
                    header.DimensionStyleOverrides.AlternateDimensioningSuffix = this.interface30_0.ReadString();
                }
            }
            if (this.class374_0.IsVersion13Or14)
            {
                header.DimensionStyleOverrides.GenerateTolerances          = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.LimitsGeneration            = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextInsideHorizontal        = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextOutsideHorizontal       = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressFirstDimensionLine  = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressSecondDimensionLine = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.AlternateUnitDimensioning   = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextOutsideExtensions       = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SeparateArrowBlocks         = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextInsideExtensions        = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressOutsideExtensions   = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.AlternateUnitDecimalPlaces  = (short)this.interface30_0.imethod_18();
                header.DimensionStyleOverrides.ZeroHandling = (ZeroHandling)this.interface30_0.imethod_18();
                header.DimensionStyleOverrides.SuppressFirstDimensionLine  = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressSecondDimensionLine = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.ToleranceAlignment          = (ToleranceAlignment)this.interface30_0.imethod_18();
                header.DimensionStyleOverrides.TextHorizontalAlignment     = (DimensionTextHorizontalAlignment)this.interface30_0.imethod_18();
                int num3 = (int)this.interface30_0.imethod_18();
                header.DimensionStyleOverrides.CursorUpdate                       = (CursorUpdate)this.interface30_0.imethod_7();
                header.DimensionStyleOverrides.ToleranceZeroHandling              = (ZeroHandling)this.interface30_0.imethod_18();
                header.DimensionStyleOverrides.AlternateUnitZeroHandling          = (ZeroHandling)this.interface30_0.imethod_18();
                header.DimensionStyleOverrides.AlternateUnitToleranceZeroHandling = (ZeroHandling)this.interface30_0.imethod_18();
                header.DimensionStyleOverrides.TextVerticalAlignment              = (DimensionTextVerticalAlignment)this.interface30_0.imethod_18();
                int num9 = (int)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AngularDimensionDecimalPlaces = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.DecimalPlaces          = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.ToleranceDecimalPlaces = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AlternateUnitFormat    = (AlternateUnitFormat)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AlternateUnitToleranceDecimalPlaces = this.interface30_0.imethod_14();
                this.class374_0.DimensionStyleTextStyleHandle = this.interface30_0.imethod_32(false);
            }
            header.DimensionStyleOverrides.ScaleFactor            = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.ArrowSize              = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.ExtensionLineOffset    = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.DimensionLineIncrement = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.ExtensionLineExtension = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.Rounding = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.DimensionLineExtension = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.PlusTolerance          = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.MinusTolerance         = this.interface30_0.imethod_8();
            if (version >= DxfVersion.Dxf21)
            {
                header.DimensionStyleOverrides.FixedExtensionLineLength = this.interface30_0.imethod_8();
                header.DimensionStyleOverrides.JoggedRadiusDimensionTransverseSegmentAngle = this.interface30_0.imethod_8();
                header.DimensionStyleOverrides.TextBackgroundFillMode = (DimensionTextBackgroundFillMode)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.TextBackgroundColor    = this.interface30_0.imethod_22();
            }
            if (this.class374_0.IsVersion15OrLater)
            {
                header.DimensionStyleOverrides.GenerateTolerances          = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.LimitsGeneration            = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextInsideHorizontal        = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextOutsideHorizontal       = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressFirstExtensionLine  = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressSecondExtensionLine = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextVerticalAlignment       = (DimensionTextVerticalAlignment)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.ZeroHandling        = (ZeroHandling)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AngularZeroHandling = (ZeroHandling)this.interface30_0.imethod_14();
            }
            if (version >= DxfVersion.Dxf21)
            {
                header.DimensionStyleOverrides.ArcLengthSymbolPosition = (ArcLengthSymbolPosition)this.interface30_0.imethod_14();
            }
            header.DimensionStyleOverrides.TextHeight               = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.CenterMarkSize           = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.TickSize                 = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.AlternateUnitScaleFactor = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.LinearScaleFactor        = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.TextVerticalPosition     = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.ToleranceScaleFactor     = this.interface30_0.imethod_8();
            header.DimensionStyleOverrides.DimensionLineGap         = this.interface30_0.imethod_8();
            if (this.class374_0.IsVersion13Or14)
            {
                header.DimensionStyleOverrides.PostFix = this.interface30_0.ReadString();
                header.DimensionStyleOverrides.AlternateDimensioningSuffix = this.interface30_0.ReadString();
                this.class374_0.DimensionStyleArrowBlockName       = this.interface30_0.ReadString();
                this.class374_0.DimensionStyleFirstArrowBlockName  = this.interface30_0.ReadString();
                this.class374_0.DimensionStyleSecondArrowBlockName = this.interface30_0.ReadString();
            }
            if (this.class374_0.IsVersion15OrLater)
            {
                header.DimensionStyleOverrides.AlternateUnitRounding      = this.interface30_0.imethod_8();
                header.DimensionStyleOverrides.AlternateUnitDimensioning  = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.AlternateUnitDecimalPlaces = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.TextOutsideExtensions      = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SeparateArrowBlocks        = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.TextInsideExtensions       = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressOutsideExtensions  = this.interface30_0.imethod_6();
            }
            header.DimensionStyleOverrides.DimensionLineColor = this.interface30_0.imethod_22();
            header.DimensionStyleOverrides.ExtensionLineColor = this.interface30_0.imethod_22();
            header.DimensionStyleOverrides.TextColor          = this.interface30_0.imethod_22();
            if (this.class374_0.IsVersion15OrLater)
            {
                header.DimensionStyleOverrides.AngularDimensionDecimalPlaces = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.DecimalPlaces          = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.ToleranceDecimalPlaces = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AlternateUnitFormat    = (AlternateUnitFormat)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AlternateUnitToleranceDecimalPlaces = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AngularDimensionDecimalPlaces       = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.FractionFormat                     = (FractionFormat)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.LinearUnitFormat                   = (LinearUnitFormat)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.DecimalSeparator                   = (char)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.TextMovement                       = (TextMovement)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.TextHorizontalAlignment            = (DimensionTextHorizontalAlignment)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.SuppressFirstDimensionLine         = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.SuppressSecondDimensionLine        = this.interface30_0.imethod_6();
                header.DimensionStyleOverrides.ToleranceAlignment                 = (ToleranceAlignment)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.ToleranceZeroHandling              = (ZeroHandling)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AlternateUnitZeroHandling          = (ZeroHandling)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.AlternateUnitToleranceZeroHandling = (ZeroHandling)this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.CursorUpdate                       = (CursorUpdate)this.interface30_0.imethod_7();
                int num3 = (int)this.interface30_0.imethod_14();
            }
            if (version >= DxfVersion.Dxf21)
            {
                header.DimensionStyleOverrides.IsExtensionLineLengthFixed = this.interface30_0.imethod_6();
            }
            if (version >= DxfVersion.Dxf24)
            {
                header.DimensionStyleOverrides.TextDirection = this.interface30_0.imethod_6() ? TextDirection.RightToLeft : TextDirection.LeftToRight;
                header.DimensionStyleOverrides.AltMzf        = this.interface30_0.imethod_8();
                header.DimensionStyleOverrides.Mzf           = this.interface30_0.imethod_8();
            }
            if (this.class374_0.Version >= DxfVersion.Dxf15 && this.class374_0.Version <= DxfVersion.Dxf18)
            {
                this.class374_0.DimensionStyleTextStyleHandle        = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleLeaderArrowBlockHandle = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleArrowBlockHandle       = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleFirstArrowBlockHandle  = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleSecondArrowBlockHandle = this.interface30_0.imethod_32(false);
            }
            if (this.class374_0.IsVersion15OrLater)
            {
                header.DimensionStyleOverrides.DimensionLineWeight = this.interface30_0.imethod_14();
                header.DimensionStyleOverrides.ExtensionLineWeight = this.interface30_0.imethod_14();
            }
            if (!this.class374_0.IsVersion21OrLater)
            {
                long num3  = (long)this.method_1();
                long num9  = (long)this.method_1();
                long num10 = (long)this.method_1();
                long num11 = (long)this.method_1();
                long num12 = (long)this.method_1();
                long num13 = (long)this.method_1();
                long num14 = (long)this.method_1();
                long num15 = (long)this.method_1();
                long num16 = (long)this.method_1();
                if (version >= DxfVersion.Dxf13 && version <= DxfVersion.Dxf15)
                {
                    long num17 = (long)this.method_1();
                }
                long num18 = (long)this.interface30_0.imethod_32(false);
                long num19 = (long)this.interface30_0.imethod_32(false);
                long num20 = (long)this.method_1();
            }
            if (this.class374_0.IsVersion15OrLater)
            {
                header.StackedTextAlignment      = (VerticalAlignment)(2 - (int)this.interface30_0.imethod_14());
                header.StackedTextSizePercentage = this.interface30_0.imethod_14();
                if (!this.class374_0.IsVersion21OrLater)
                {
                    this.class374_0.Model.SummaryInfo.HyperLinkBase = this.interface30_0.ReadString();
                    this.interface30_0.ReadString();
                    this.class374_0.LayoutsDictionaryHandle = this.interface30_0.imethod_32(false);
                    long num3 = (long)this.interface30_0.imethod_32(false);
                    long num9 = (long)this.interface30_0.imethod_32(false);
                }
            }
            if (!this.class374_0.IsVersion21OrLater)
            {
                if (version > DxfVersion.Dxf15)
                {
                    long num3 = (long)this.interface30_0.imethod_32(false);
                    long num9 = (long)this.interface30_0.imethod_32(false);
                }
                if (version > DxfVersion.Dxf18)
                {
                    long num10 = (long)this.interface30_0.imethod_32(false);
                }
            }
            if (this.class374_0.IsVersion15OrLater)
            {
                int num3 = this.interface30_0.imethod_11();
                header.CurrentEntityLineWeight = (short)(num3 & 31);
                header.EndCaps                    = (EndCaps)((num3 & 96) >> 5);
                header.JoinStyle                  = (JoinStyle)((num3 & 384) >> 7);
                header.DisplayLineWeight          = (num3 & 512) == 0;
                header.XEdit                      = (num3 & 1024) == 0;
                header.ExtendedNames              = (num3 & 2048) == 2048;
                header.PlotStyleMode              = (num3 & 8192) == 8192 ? PlotStyleMode.ColorDependent : PlotStyleMode.Named;
                header.InsUnits                   = (DrawingUnits)this.interface30_0.imethod_14();
                header.CurrentEntityPlotStyleType = (PlotStyleType)this.interface30_0.imethod_14();
                if (!this.class374_0.IsVersion21OrLater)
                {
                    if (header.CurrentEntityPlotStyleType == PlotStyleType.ByObjectId)
                    {
                        long num9 = (long)this.interface30_0.imethod_32(false);
                    }
                    header.FingerPrintGuid = this.interface30_0.ReadString();
                    header.VersionGuid     = this.interface30_0.ReadString();
                }
            }
            if (version >= DxfVersion.Dxf18)
            {
                header.EntitySortingFlags = (ObjectSortingFlags)this.interface30_0.imethod_18();
                header.IndexCreationFlags = (IndexCreationFlags)this.interface30_0.imethod_18();
                int num3 = (int)this.interface30_0.imethod_18();
                header.ExternalReferenceClippingBoundaryType = (SimpleLineType)this.interface30_0.imethod_18();
                header.DimensionAssociativity = (DimensionAssociativity)this.interface30_0.imethod_18();
                header.HaloGapPercentage      = this.interface30_0.imethod_18();
                short colorIndex1 = this.interface30_0.imethod_14();
                header.ObscuredColor = Color.CreateFromColorIndex(colorIndex1);
                short colorIndex2 = this.interface30_0.imethod_14();
                header.InterfereColor = Color.CreateFromColorIndex(colorIndex2);
                int num9 = (int)this.interface30_0.imethod_18();
                header.IntersectionDisplay = this.interface30_0.imethod_18() != (byte)0;
                if (!this.class374_0.IsVersion21OrLater)
                {
                    header.ProjectName = this.interface30_0.ReadString();
                }
            }
            if (!this.class374_0.IsVersion21OrLater)
            {
                this.class374_0.PaperSpaceBlockRecordHandle = this.interface30_0.imethod_32(false);
                this.class374_0.ModelSpaceBlockRecordHandle = this.interface30_0.imethod_32(false);
                this.class374_0.ByLayerLineTypeHandle       = this.interface30_0.imethod_32(false);
                this.class374_0.ByBlockLineTypeHandle       = this.interface30_0.imethod_32(false);
                this.class374_0.ContinuousLineTypeHandle    = this.interface30_0.imethod_32(false);
            }
            if (version >= DxfVersion.Dxf21)
            {
                this.interface30_0.imethod_6();
                this.interface30_0.imethod_11();
                this.interface30_0.imethod_11();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                int num3 = (int)this.interface30_0.imethod_18();
                int num9 = (int)this.interface30_0.imethod_18();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                int num10 = (int)this.interface30_0.imethod_14();
                int num11 = (int)this.interface30_0.imethod_18();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_8();
                this.interface30_0.imethod_11();
                int num12 = (int)this.interface30_0.imethod_18();
                int num13 = (int)this.interface30_0.imethod_18();
                int num14 = (int)this.interface30_0.imethod_18();
                int num15 = (int)this.interface30_0.imethod_18();
                this.interface30_0.imethod_6();
                header.InterfereColor = this.interface30_0.imethod_22();
                if (!this.class374_0.IsVersion21OrLater)
                {
                    long num16 = (long)this.interface30_0.imethod_32(false);
                    long num17 = (long)this.interface30_0.imethod_32(false);
                    long num18 = (long)this.interface30_0.imethod_32(false);
                }
                header.ShadowMode          = (ShadowMode)this.interface30_0.imethod_18();
                header.ShadowPlaneLocation = this.interface30_0.imethod_8();
            }
            if (this.class374_0.IsVersion21OrLater)
            {
                header.MenuFileName = this.interface30_0.ReadString();
                header.DimensionStyleOverrides.PostFix = this.interface30_0.ReadString();
                header.DimensionStyleOverrides.AlternateDimensioningSuffix = this.interface30_0.ReadString();
                if (this.class374_0.Version > DxfVersion.Dxf21)
                {
                    header.DimensionStyleOverrides.AltMzs = this.interface30_0.ReadString();
                    header.DimensionStyleOverrides.Mzs    = this.interface30_0.ReadString();
                }
                this.class374_0.Model.SummaryInfo.HyperLinkBase = this.interface30_0.ReadString();
                this.interface30_0.ReadString();
                header.FingerPrintGuid = this.interface30_0.ReadString();
                header.VersionGuid     = this.interface30_0.ReadString();
                this.interface30_0.ReadString();
                this.class374_0.PaperSpaceUcsHandle = this.interface30_0.imethod_32(false);
                long num3 = (long)this.interface30_0.imethod_32(false);
                long num9 = (long)this.interface30_0.imethod_32(false);
                this.class374_0.UcsHandle = this.interface30_0.imethod_32(false);
                long num10 = (long)this.interface30_0.imethod_32(false);
                long num11 = (long)this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleTextStyleHandle             = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleLeaderArrowBlockHandle      = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleArrowBlockHandle            = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleFirstArrowBlockHandle       = this.interface30_0.imethod_32(false);
                this.class374_0.DimensionStyleSecondArrowBlockHandle      = this.interface30_0.imethod_32(false);
                this.class374_0.DimStyleDimensionLineLineTypeHandle       = this.interface30_0.imethod_32(false);
                this.class374_0.DimStyleFirstExtensionLineLineTypeHandle  = this.interface30_0.imethod_32(false);
                this.class374_0.DimStyleSecondExtensionLineLineTypeHandle = this.interface30_0.imethod_32(false);
                long num12 = (long)this.method_1();
                long num13 = (long)this.method_1();
                long num14 = (long)this.method_1();
                long num15 = (long)this.method_1();
                long num16 = (long)this.method_1();
                long num17 = (long)this.method_1();
                long num18 = (long)this.method_1();
                long num19 = (long)this.method_1();
                long num20 = (long)this.method_1();
                long num21 = (long)this.interface30_0.imethod_32(false);
                long num22 = (long)this.interface30_0.imethod_32(false);
                long num23 = (long)this.method_1();
                this.class374_0.LayoutsDictionaryHandle = this.interface30_0.imethod_32(false);
                long num24 = (long)this.interface30_0.imethod_32(false);
                long num25 = (long)this.interface30_0.imethod_32(false);
                long num26 = (long)this.interface30_0.imethod_32(false);
                long num27 = (long)this.interface30_0.imethod_32(false);
                long num28 = (long)this.interface30_0.imethod_32(false);
                if (version > DxfVersion.Dxf24)
                {
                    long num29 = (long)this.interface30_0.imethod_32(false);
                }
                if (header.CurrentEntityPlotStyleType == PlotStyleType.ByObjectId)
                {
                    long num30 = (long)this.interface30_0.imethod_32(false);
                }
                this.class374_0.PaperSpaceBlockRecordHandle = this.interface30_0.imethod_32(false);
                this.class374_0.ModelSpaceBlockRecordHandle = this.interface30_0.imethod_32(false);
                this.class374_0.ByLayerLineTypeHandle       = this.interface30_0.imethod_32(false);
                this.class374_0.ByBlockLineTypeHandle       = this.interface30_0.imethod_32(false);
                this.class374_0.ContinuousLineTypeHandle    = this.interface30_0.imethod_32(false);
                long num31 = (long)this.interface30_0.imethod_32(false);
                long num32 = (long)this.interface30_0.imethod_32(false);
                long num33 = (long)this.interface30_0.imethod_32(false);
            }
            this.interface30_0 = this.interface30_3;
            if (header.AcadVersion >= DxfVersion.Dxf14)
            {
                try
                {
                    int num3  = (int)this.interface30_0.imethod_14();
                    int num9  = (int)this.interface30_0.imethod_14();
                    int num10 = (int)this.interface30_0.imethod_14();
                    int num11 = (int)this.interface30_0.imethod_14();
                    if (header.AcadVersion >= DxfVersion.Dxf18)
                    {
                        this.interface30_0.imethod_11();
                        this.interface30_0.imethod_11();
                        this.interface30_0.imethod_6();
                    }
                }
                catch (DxfException ex)
                {
                }
            }
            if (this.interface30_0.BitIndex > 0)
            {
                for (int bitIndex = this.interface30_0.BitIndex; bitIndex < 8; ++bitIndex)
                {
                    this.interface30_0.imethod_6();
                }
            }
            this.interface30_0.imethod_3();
            this.interface30_0.imethod_4(num2 + (long)(num1 * 8));
            int num34 = (int)this.interface30_0.imethod_27();

            this.interface30_0.imethod_52(16);
            foreach (IDisposable disposable in this.list_0)
            {
                disposable.Dispose();
            }
        }
示例#25
0
 public virtual void imethod_5(int value)
 {
     this.memoryStream_0.WriteByte((byte)12);
     Class1045.smethod_9((Stream)this.memoryStream_0, value);
 }
示例#26
0
        public virtual bool imethod_15(ref List <Class561> unknownData)
        {
            Class951.Enum41 type;
            do
            {
                long position = this.memoryStream_0.Position;
                type = (Class951.Enum41) this.memoryStream_0.ReadByte();
                this.memoryStream_0.Seek(position, SeekOrigin.Begin);
                switch (type)
                {
                case Class951.Enum41.const_0:
                    this.memoryStream_0.ReadByte();
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_1:
                case Class951.Enum41.const_2:
                case Class951.Enum41.const_3:
                case Class951.Enum41.const_5:
                case Class951.Enum41.const_15:
                case Class951.Enum41.const_16:
                    goto label_13;

                case Class951.Enum41.const_4:
                    unknownData.Add((Class561) new Class562 <long>(type, (long)this.imethod_5()));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_6:
                    unknownData.Add((Class561) new Class562 <double>(type, this.imethod_8()));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_7:
                case Class951.Enum41.const_8:
                case Class951.Enum41.const_9:
                case Class951.Enum41.const_18:
                    unknownData.Add((Class561) new Class562 <string>(type, this.ReadString()));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_10:
                case Class951.Enum41.const_11:
                    unknownData.Add((Class561) new Class562 <int>(type, this.memoryStream_0.ReadByte()));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_12:
                    unknownData.Add((Class561) new Class562 <int>(type, this.imethod_7()));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_13:
                case Class951.Enum41.const_14:
                    StringBuilder stringBuilder = new StringBuilder((int)byte.MaxValue);
                    byte          num           = (byte)this.memoryStream_0.ReadByte();
                    byte[]        numArray      = new byte[(int)num];
                    this.memoryStream_0.Read(numArray, 0, (int)num);
                    unknownData.Add((Class561) new Class562 <string>(type, Encodings.Ascii.GetString(numArray, 0, (int)num)));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_17:
                    continue;

                case Class951.Enum41.const_19:
                    unknownData.Add((Class561) new Class562 <Point3D>(type, this.imethod_18()));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_20:
                    unknownData.Add((Class561) new Class562 <Vector3D>(type, this.imethod_19()));
                    goto case Class951.Enum41.const_17;

                case Class951.Enum41.const_21:
                    this.memoryStream_0.ReadByte();
                    unknownData.Add((Class561) new Class562 <int>(type, Class1045.smethod_7((Stream)this.memoryStream_0)));
                    goto case Class951.Enum41.const_17;

                default:
                    goto label_12;
                }
            }while (type != Class951.Enum41.const_17);
            goto label_14;
label_12:
            throw new Exception0("Unknown entity format broken");
label_13:
            throw new Exception0("Reading of unknown entities isn't implemented yet");
label_14:
            return(false);
        }
示例#27
0
 public virtual void imethod_11(string[] values, int[] indexes, int value)
 {
     this.memoryStream_0.WriteByte((byte)21);
     Class1045.smethod_9((Stream)this.memoryStream_0, value);
 }
示例#28
0
 public virtual void imethod_7(double value)
 {
     this.memoryStream_0.WriteByte((byte)6);
     Class1045.smethod_16((Stream)this.memoryStream_0, value);
 }