Exemplo n.º 1
0
 // Token: 0x06000E46 RID: 3654
 // RVA: 0x0004E3A4 File Offset: 0x0004C5A4
 public int method_1(Enum2 enum2_0, Class31 class31_0)
 {
     if (this.bool_0)
     {
         byte[] array = this.byte_0[(int)enum2_0];
         if (array != null)
         {
             if (array.Length > 0)
             {
                 class31_0.Seek(0, SeekOrigin.Begin);
                 class31_0.BaseStream.Write(array, 0, array.Length);
             }
             return array.Length;
         }
     }
     int num;
     switch (enum2_0)
     {
     case Enum2.const_0:
         IL_47:
         num = this.method_2(class31_0);
         goto IL_59;
     case Enum2.const_1:
         num = this.method_3(class31_0);
         goto IL_59;
     }
     goto IL_47;
     IL_59:
     if (this.bool_0)
     {
         byte[] array2 = new byte[num];
         if (num > 0)
         {
             class31_0.Seek(0, SeekOrigin.Begin);
             class31_0.BaseStream.Read(array2, 0, num);
         }
         this.byte_0[(int)enum2_0] = array2;
     }
     return num;
 }
Exemplo n.º 2
0
 // Token: 0x06000E47 RID: 3655
 // RVA: 0x0004E440 File Offset: 0x0004C640
 private int method_2(Class31 class31_0)
 {
     bSerializable bSerializable = this.object_0 as bSerializable;
     if (this.enum3_0 == Enum3.const_84)
     {
         return 0;
     }
     MemoryStream memoryStream = (MemoryStream)class31_0.BaseStream;
     class31_0.Seek(7, SeekOrigin.Begin);
     int num = 0;
     if (bSerializable != null)
     {
         bSerializable.WriteToStream(class31_0);
         num = (int)memoryStream.Position - 7;
     }
     class31_0.Seek(0, SeekOrigin.Begin);
     class31_0.Write((ushort)this.enum3_0);
     class31_0.Write(0);
     class31_0.Write((uint)num);
     return 7 + num;
 }