ReadInt32() приватный Метод

private ReadInt32 ( ) : Int32
Результат System.Int32
 public void Read(__BinaryParser input)
 {
     this.objectId = input.ReadInt32();
     this.name = input.ReadString();
     this.numMembers = input.ReadInt32();
     this.memberNames = new string[this.numMembers];
     this.binaryTypeEnumA = new BinaryTypeEnum[this.numMembers];
     this.typeInformationA = new object[this.numMembers];
     this.memberAssemIds = new int[this.numMembers];
     for (int i = 0; i < this.numMembers; i++)
     {
         this.memberNames[i] = input.ReadString();
     }
     for (int j = 0; j < this.numMembers; j++)
     {
         this.binaryTypeEnumA[j] = (BinaryTypeEnum) input.ReadByte();
     }
     for (int k = 0; k < this.numMembers; k++)
     {
         if ((this.binaryTypeEnumA[k] != BinaryTypeEnum.ObjectUrt) && (this.binaryTypeEnumA[k] != BinaryTypeEnum.ObjectUser))
         {
             this.typeInformationA[k] = BinaryConverter.ReadTypeInfo(this.binaryTypeEnumA[k], input, out this.memberAssemIds[k]);
         }
         else
         {
             BinaryConverter.ReadTypeInfo(this.binaryTypeEnumA[k], input, out this.memberAssemIds[k]);
         }
     }
     if (this.binaryHeaderEnum == BinaryHeaderEnum.ObjectWithMapTypedAssemId)
     {
         this.assemId = input.ReadInt32();
     }
 }
Пример #2
0
 public void Read(__BinaryParser input)
 {
     this.objectId         = input.ReadInt32();
     this.name             = input.ReadString();
     this.numMembers       = input.ReadInt32();
     this.memberNames      = new string[this.numMembers];
     this.binaryTypeEnumA  = new BinaryTypeEnum[this.numMembers];
     this.typeInformationA = new object[this.numMembers];
     this.memberAssemIds   = new int[this.numMembers];
     for (int index = 0; index < this.numMembers; ++index)
     {
         this.memberNames[index] = input.ReadString();
     }
     for (int index = 0; index < this.numMembers; ++index)
     {
         this.binaryTypeEnumA[index] = (BinaryTypeEnum)input.ReadByte();
     }
     for (int index = 0; index < this.numMembers; ++index)
     {
         if (this.binaryTypeEnumA[index] != BinaryTypeEnum.ObjectUrt && this.binaryTypeEnumA[index] != BinaryTypeEnum.ObjectUser)
         {
             this.typeInformationA[index] = BinaryConverter.ReadTypeInfo(this.binaryTypeEnumA[index], input, out this.memberAssemIds[index]);
         }
         else
         {
             BinaryConverter.ReadTypeInfo(this.binaryTypeEnumA[index], input, out this.memberAssemIds[index]);
         }
     }
     if (this.binaryHeaderEnum != BinaryHeaderEnum.ObjectWithMapTypedAssemId)
     {
         return;
     }
     this.assemId = input.ReadInt32();
 }
 public void Read(__BinaryParser input)
 {
     this.objectId         = input.ReadInt32();
     this.name             = input.ReadString();
     this.numMembers       = input.ReadInt32();
     this.memberNames      = new string[this.numMembers];
     this.binaryTypeEnumA  = new BinaryTypeEnum[this.numMembers];
     this.typeInformationA = new object[this.numMembers];
     this.memberAssemIds   = new int[this.numMembers];
     for (int i = 0; i < this.numMembers; i++)
     {
         this.memberNames[i] = input.ReadString();
     }
     for (int j = 0; j < this.numMembers; j++)
     {
         this.binaryTypeEnumA[j] = (BinaryTypeEnum)input.ReadByte();
     }
     for (int k = 0; k < this.numMembers; k++)
     {
         if (this.binaryTypeEnumA[k] != BinaryTypeEnum.ObjectUrt && this.binaryTypeEnumA[k] != BinaryTypeEnum.ObjectUser)
         {
             this.typeInformationA[k] = BinaryConverter.ReadTypeInfo(this.binaryTypeEnumA[k], input, out this.memberAssemIds[k]);
         }
         else
         {
             BinaryConverter.ReadTypeInfo(this.binaryTypeEnumA[k], input, out this.memberAssemIds[k]);
         }
     }
     if (this.binaryHeaderEnum == BinaryHeaderEnum.ObjectWithMapTypedAssemId)
     {
         this.assemId = input.ReadInt32();
     }
 }
        public void Read(__BinaryParser input)
        {
            switch (this.binaryHeaderEnum)
            {
            case BinaryHeaderEnum.ArraySinglePrimitive:
                this.objectId            = input.ReadInt32();
                this.lengthA             = new int[1];
                this.lengthA[0]          = input.ReadInt32();
                this.binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
                this.rank            = 1;
                this.lowerBoundA     = new int[this.rank];
                this.binaryTypeEnum  = BinaryTypeEnum.Primitive;
                this.typeInformation = (InternalPrimitiveTypeE)input.ReadByte();
                return;

            case BinaryHeaderEnum.ArraySingleObject:
                this.objectId            = input.ReadInt32();
                this.lengthA             = new int[1];
                this.lengthA[0]          = input.ReadInt32();
                this.binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
                this.rank            = 1;
                this.lowerBoundA     = new int[this.rank];
                this.binaryTypeEnum  = BinaryTypeEnum.Object;
                this.typeInformation = null;
                return;

            case BinaryHeaderEnum.ArraySingleString:
                this.objectId            = input.ReadInt32();
                this.lengthA             = new int[1];
                this.lengthA[0]          = input.ReadInt32();
                this.binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
                this.rank            = 1;
                this.lowerBoundA     = new int[this.rank];
                this.binaryTypeEnum  = BinaryTypeEnum.String;
                this.typeInformation = null;
                return;

            default:
                this.objectId            = input.ReadInt32();
                this.binaryArrayTypeEnum = (BinaryArrayTypeEnum)input.ReadByte();
                this.rank        = input.ReadInt32();
                this.lengthA     = new int[this.rank];
                this.lowerBoundA = new int[this.rank];
                for (int i = 0; i < this.rank; i++)
                {
                    this.lengthA[i] = input.ReadInt32();
                }
                if (this.binaryArrayTypeEnum == BinaryArrayTypeEnum.SingleOffset || this.binaryArrayTypeEnum == BinaryArrayTypeEnum.JaggedOffset || this.binaryArrayTypeEnum == BinaryArrayTypeEnum.RectangularOffset)
                {
                    for (int j = 0; j < this.rank; j++)
                    {
                        this.lowerBoundA[j] = input.ReadInt32();
                    }
                }
                this.binaryTypeEnum  = (BinaryTypeEnum)input.ReadByte();
                this.typeInformation = BinaryConverter.ReadTypeInfo(this.binaryTypeEnum, input, out this.assemId);
                return;
            }
        }
        public void Read(__BinaryParser input)
        {
            switch (this.binaryHeaderEnum)
            {
                case BinaryHeaderEnum.ArraySinglePrimitive:
                    this.objectId = input.ReadInt32();
                    this.lengthA = new int[] { input.ReadInt32() };
                    this.binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
                    this.rank = 1;
                    this.lowerBoundA = new int[this.rank];
                    this.binaryTypeEnum = BinaryTypeEnum.Primitive;
                    this.typeInformation = (InternalPrimitiveTypeE) input.ReadByte();
                    return;

                case BinaryHeaderEnum.ArraySingleObject:
                    this.objectId = input.ReadInt32();
                    this.lengthA = new int[] { input.ReadInt32() };
                    this.binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
                    this.rank = 1;
                    this.lowerBoundA = new int[this.rank];
                    this.binaryTypeEnum = BinaryTypeEnum.Object;
                    this.typeInformation = null;
                    return;

                case BinaryHeaderEnum.ArraySingleString:
                    this.objectId = input.ReadInt32();
                    this.lengthA = new int[] { input.ReadInt32() };
                    this.binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
                    this.rank = 1;
                    this.lowerBoundA = new int[this.rank];
                    this.binaryTypeEnum = BinaryTypeEnum.String;
                    this.typeInformation = null;
                    return;
            }
            this.objectId = input.ReadInt32();
            this.binaryArrayTypeEnum = (BinaryArrayTypeEnum) input.ReadByte();
            this.rank = input.ReadInt32();
            this.lengthA = new int[this.rank];
            this.lowerBoundA = new int[this.rank];
            for (int i = 0; i < this.rank; i++)
            {
                this.lengthA[i] = input.ReadInt32();
            }
            if (((this.binaryArrayTypeEnum == BinaryArrayTypeEnum.SingleOffset) || (this.binaryArrayTypeEnum == BinaryArrayTypeEnum.JaggedOffset)) || (this.binaryArrayTypeEnum == BinaryArrayTypeEnum.RectangularOffset))
            {
                for (int j = 0; j < this.rank; j++)
                {
                    this.lowerBoundA[j] = input.ReadInt32();
                }
            }
            this.binaryTypeEnum = (BinaryTypeEnum) input.ReadByte();
            this.typeInformation = BinaryConverter.ReadTypeInfo(this.binaryTypeEnum, input, out this.assemId);
        }
 public void Read(__BinaryParser input)
 {
     this.objectId    = input.ReadInt32();
     this.name        = input.ReadString();
     this.numMembers  = input.ReadInt32();
     this.memberNames = new string[this.numMembers];
     for (int i = 0; i < this.numMembers; i++)
     {
         this.memberNames[i] = input.ReadString();
     }
     if (this.binaryHeaderEnum == BinaryHeaderEnum.ObjectWithMapAssemId)
     {
         this.assemId = input.ReadInt32();
     }
 }
 public void Read(__BinaryParser input)
 {
     this.objectId = input.ReadInt32();
     this.name = input.ReadString();
     this.numMembers = input.ReadInt32();
     this.memberNames = new string[this.numMembers];
     for (int i = 0; i < this.numMembers; i++)
     {
         this.memberNames[i] = input.ReadString();
     }
     if (this.binaryHeaderEnum == BinaryHeaderEnum.ObjectWithMapAssemId)
     {
         this.assemId = input.ReadInt32();
     }
 }
Пример #8
0
 public void Read(__BinaryParser input)
 {
     this.objectId    = input.ReadInt32();
     this.name        = input.ReadString();
     this.numMembers  = input.ReadInt32();
     this.memberNames = new string[this.numMembers];
     for (int index = 0; index < this.numMembers; ++index)
     {
         this.memberNames[index] = input.ReadString();
     }
     if (this.binaryHeaderEnum != BinaryHeaderEnum.ObjectWithMapAssemId)
     {
         return;
     }
     this.assemId = input.ReadInt32();
 }
Пример #9
0
 public void Read(__BinaryParser input)
 {
     this.messageEnum = (MessageEnum)input.ReadInt32();
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.NoReturnValue))
     {
         this.returnValue = null;
     }
     else if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ReturnValueVoid))
     {
         this.returnValue = BinaryMethodReturn.instanceOfVoid;
     }
     else if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ReturnValueInline))
     {
         this.returnValue = IOUtil.ReadWithCode(input);
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ContextInline))
     {
         this.scallContext = (string)IOUtil.ReadWithCode(input);
         this.callContext  = new LogicalCallContext
         {
             RemotingData =
             {
                 LogicalCallID = this.scallContext
             }
         };
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ArgsInline))
     {
         this.args = IOUtil.ReadArgs(input);
     }
 }
 public void Read(__BinaryParser input)
 {
     this.messageEnum = (MessageEnum) input.ReadInt32();
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.NoReturnValue))
     {
         this.returnValue = null;
     }
     else if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ReturnValueVoid))
     {
         this.returnValue = instanceOfVoid;
     }
     else if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ReturnValueInline))
     {
         this.returnValue = IOUtil.ReadWithCode(input);
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ContextInline))
     {
         this.scallContext = (string) IOUtil.ReadWithCode(input);
         LogicalCallContext context = new LogicalCallContext {
             RemotingData = { LogicalCallID = this.scallContext }
         };
         this.callContext = context;
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ArgsInline))
     {
         this.args = IOUtil.ReadArgs(input);
     }
 }
Пример #11
0
        internal static object ReadTypeInfo(BinaryTypeEnum binaryTypeEnum, __BinaryParser input, out int assemId)
        {
            object obj = (object)null;
            int    num = 0;

            switch (binaryTypeEnum)
            {
            case BinaryTypeEnum.Primitive:
            case BinaryTypeEnum.PrimitiveArray:
                obj = (object)(InternalPrimitiveTypeE)input.ReadByte();
                goto case BinaryTypeEnum.String;

            case BinaryTypeEnum.String:
            case BinaryTypeEnum.Object:
            case BinaryTypeEnum.ObjectArray:
            case BinaryTypeEnum.StringArray:
                assemId = num;
                return(obj);

            case BinaryTypeEnum.ObjectUrt:
                obj = (object)input.ReadString();
                goto case BinaryTypeEnum.String;

            case BinaryTypeEnum.ObjectUser:
                obj = (object)input.ReadString();
                num = input.ReadInt32();
                goto case BinaryTypeEnum.String;

            default:
                throw new SerializationException(Environment.GetResourceString("Serialization_TypeRead", (object)binaryTypeEnum.ToString()));
            }
        }
 internal static object[] ReadArgs(__BinaryParser input)
 {
     int num = input.ReadInt32();
     object[] objArray = new object[num];
     for (int i = 0; i < num; i++)
     {
         objArray[i] = ReadWithCode(input);
     }
     return objArray;
 }
Пример #13
0
        internal static object[] ReadArgs(__BinaryParser input)
        {
            int num = input.ReadInt32();

            object[] objArray = new object[num];
            for (int i = 0; i < num; i++)
            {
                objArray[i] = ReadWithCode(input);
            }
            return(objArray);
        }
Пример #14
0
        public void Read(__BinaryParser input, BinaryHeaderEnum binaryHeaderEnum)
        {
            switch (binaryHeaderEnum)
            {
            case BinaryHeaderEnum.ObjectNull:
                this.nullCount = 1;
                break;

            case BinaryHeaderEnum.ObjectNullMultiple256:
                this.nullCount = (int)input.ReadByte();
                break;

            case BinaryHeaderEnum.ObjectNullMultiple:
                this.nullCount = input.ReadInt32();
                break;
            }
        }
 internal void Read(__BinaryParser input)
 {
     this.messageEnum = (MessageEnum) input.ReadInt32();
     this.methodName = (string) IOUtil.ReadWithCode(input);
     this.typeName = (string) IOUtil.ReadWithCode(input);
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ContextInline))
     {
         this.scallContext = (string) IOUtil.ReadWithCode(input);
         LogicalCallContext context = new LogicalCallContext {
             RemotingData = { LogicalCallID = this.scallContext }
         };
         this.callContext = context;
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ArgsInline))
     {
         this.args = IOUtil.ReadArgs(input);
     }
 }
Пример #16
0
 internal void Read(__BinaryParser input)
 {
     this.messageEnum = (MessageEnum)input.ReadInt32();
     this.methodName  = (string)IOUtil.ReadWithCode(input);
     this.typeName    = (string)IOUtil.ReadWithCode(input);
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ContextInline))
     {
         this.scallContext = (string)IOUtil.ReadWithCode(input);
         LogicalCallContext context = new LogicalCallContext {
             RemotingData = { LogicalCallID = this.scallContext }
         };
         this.callContext = context;
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ArgsInline))
     {
         this.args = IOUtil.ReadArgs(input);
     }
 }
        public void Read(__BinaryParser input, BinaryHeaderEnum binaryHeaderEnum)
        {
            switch (binaryHeaderEnum)
            {
                case BinaryHeaderEnum.ObjectNull:
                    this.nullCount = 1;
                    return;

                case BinaryHeaderEnum.MessageEnd:
                case BinaryHeaderEnum.Assembly:
                    break;

                case BinaryHeaderEnum.ObjectNullMultiple256:
                    this.nullCount = input.ReadByte();
                    return;

                case BinaryHeaderEnum.ObjectNullMultiple:
                    this.nullCount = input.ReadInt32();
                    break;

                default:
                    return;
            }
        }
        // Token: 0x06005305 RID: 21253 RVA: 0x00123C70 File Offset: 0x00121E70
        public void Read(__BinaryParser input, BinaryHeaderEnum binaryHeaderEnum)
        {
            switch (binaryHeaderEnum)
            {
            case BinaryHeaderEnum.ObjectNull:
                this.nullCount = 1;
                return;

            case BinaryHeaderEnum.MessageEnd:
            case BinaryHeaderEnum.Assembly:
                break;

            case BinaryHeaderEnum.ObjectNullMultiple256:
                this.nullCount = (int)input.ReadByte();
                return;

            case BinaryHeaderEnum.ObjectNullMultiple:
                this.nullCount = input.ReadInt32();
                break;

            default:
                return;
            }
        }
        // Token: 0x06005298 RID: 21144 RVA: 0x001220F8 File Offset: 0x001202F8
        internal static object ReadTypeInfo(BinaryTypeEnum binaryTypeEnum, __BinaryParser input, out int assemId)
        {
            object result = null;
            int    num    = 0;

            switch (binaryTypeEnum)
            {
            case BinaryTypeEnum.Primitive:
            case BinaryTypeEnum.PrimitiveArray:
                result = (InternalPrimitiveTypeE)input.ReadByte();
                break;

            case BinaryTypeEnum.String:
            case BinaryTypeEnum.Object:
            case BinaryTypeEnum.ObjectArray:
            case BinaryTypeEnum.StringArray:
                break;

            case BinaryTypeEnum.ObjectUrt:
                result = input.ReadString();
                break;

            case BinaryTypeEnum.ObjectUser:
                result = input.ReadString();
                num    = input.ReadInt32();
                break;

            default:
                throw new SerializationException(Environment.GetResourceString("Serialization_TypeRead", new object[]
                {
                    binaryTypeEnum.ToString()
                }));
            }
            assemId = num;
            return(result);
        }
Пример #20
0
        public  void Read(__BinaryParser input)
        {
            // binaryHeaderEnum has already been read
            binaryHeaderEnum = (BinaryHeaderEnum)input.ReadByte();
            topId = input.ReadInt32();
            headerId = input.ReadInt32();
            majorVersion = input.ReadInt32();
            minorVersion = input.ReadInt32();  
            if (majorVersion > binaryFormatterMajorVersion)
                throw new SerializationException(String.Format(Environment.GetResourceString("Serialization_Version"),binaryFormatterMajorVersion+"."+binaryFormatterMinorVersion, majorVersion+"."+minorVersion));

        }
 public void Read(__BinaryParser input)
 {
     this.idRef = input.ReadInt32();
 }
 public void Read(__BinaryParser input)
 {
     this.objectId = input.ReadInt32();
     this.value = input.ReadInt32();
 }
        internal static object ReadTypeInfo(BinaryTypeEnum binaryTypeEnum, __BinaryParser input, out int assemId)
        {
            object obj2 = null;
            int num = 0;
            switch (binaryTypeEnum)
            {
                case BinaryTypeEnum.Primitive:
                case BinaryTypeEnum.PrimitiveArray:
                    obj2 = (InternalPrimitiveTypeE) input.ReadByte();
                    break;

                case BinaryTypeEnum.String:
                case BinaryTypeEnum.Object:
                case BinaryTypeEnum.ObjectArray:
                case BinaryTypeEnum.StringArray:
                    break;

                case BinaryTypeEnum.ObjectUrt:
                    obj2 = input.ReadString();
                    break;

                case BinaryTypeEnum.ObjectUser:
                    obj2 = input.ReadString();
                    num = input.ReadInt32();
                    break;

                default:
                    throw new SerializationException(Environment.GetResourceString("Serialization_TypeRead", new object[] { binaryTypeEnum.ToString() }));
            }
            assemId = num;
            return obj2;
        }
Пример #24
0
 public void Read(__BinaryParser input)
 {
     this.assemId       = input.ReadInt32();
     this.assemblyIndex = input.ReadInt32();
 }
        [System.Security.SecurityCritical]  // auto-generated
        internal void Read(__BinaryParser input) 
        {
             messageEnum = (MessageEnum)input.ReadInt32();
             //uri = (String)IOUtil.ReadWithCode(input);
             methodName = (String)IOUtil.ReadWithCode(input); 
             typeName = (String)IOUtil.ReadWithCode(input);
 
#if FEATURE_REMOTING 
             if (IOUtil.FlagTest(messageEnum, MessageEnum.ContextInline))
             { 
                 scallContext = (String)IOUtil.ReadWithCode(input);
                 LogicalCallContext lcallContext = new LogicalCallContext();
                 lcallContext.RemotingData.LogicalCallID = scallContext;
                 callContext = lcallContext; 
             }
#endif 
 
             if (IOUtil.FlagTest(messageEnum, MessageEnum.ArgsInline))
                 args = IOUtil.ReadArgs(input); 
        }
 internal static Object[] ReadArgs(__BinaryParser input)
 { 
     int length = input.ReadInt32();
     Object[] args = new Object[length];
     for (int i=0; i<length; i++)
         args[i] = ReadWithCode(input); 
     return args;
 } 
        // Reads the type information from the wire
        internal static Object ReadTypeInfo(BinaryTypeEnum binaryTypeEnum, __BinaryParser input, out int assemId) 
        { 
            SerTrace.Log( "BinaryConverter", "ReadTypeInfo Entry  ",((Enum)binaryTypeEnum).ToString());
            Object var = null; 
            int readAssemId = 0;

            switch (binaryTypeEnum)
            { 
                case BinaryTypeEnum.Primitive:
                case BinaryTypeEnum.PrimitiveArray: 
                    var = (InternalPrimitiveTypeE)input.ReadByte(); 
                    break;
                case BinaryTypeEnum.String: 
                case BinaryTypeEnum.Object:
                case BinaryTypeEnum.StringArray:
                case BinaryTypeEnum.ObjectArray:
                    break; 
                case BinaryTypeEnum.ObjectUrt:
                    var = input.ReadString(); 
                    break; 
                case BinaryTypeEnum.ObjectUser:
                    var = input.ReadString(); 
                    readAssemId = input.ReadInt32();
                    break;
                default:
                    throw new SerializationException(Environment.GetResourceString("Serialization_TypeRead",((Enum)binaryTypeEnum).ToString())); 
            }
            SerTrace.Log( "BinaryConverter", "ReadTypeInfo Exit  ",var," assemId ",readAssemId); 
            assemId = readAssemId; 
            return var;
        } 
 public void Read(__BinaryParser input)
 {
     this.objectId = input.ReadInt32();
     this.value    = input.ReadString();
 }
 public void Read(__BinaryParser input)
 {
     this.crossAppDomainArrayIndex = input.ReadInt32();
 }
 [System.Security.SecurityCritical] // implements Critical method 
 public void Read(__BinaryParser input)
 { 
     assemId = input.ReadInt32(); 
     assemblyIndex = input.ReadInt32();
 } 
 [System.Security.SecurityCritical] // implements Critical method
 public void Read(__BinaryParser input)
 {
     objectId = input.ReadInt32(); 
     mapId = input.ReadInt32();
 } 
 [System.Security.SecurityCritical] // implements Critical method
 public void Read(__BinaryParser input) 
 { 
     objectId = input.ReadInt32();
     value = input.ReadString(); 
 }
 public void Read(__BinaryParser input)
 {
     this.assemId = input.ReadInt32();
     this.assemblyString = input.ReadString();
 }
 [System.Security.SecurityCritical] // implements Critical method 
 public void Read(__BinaryParser input) 
 {
     crossAppDomainArrayIndex = input.ReadInt32(); 
 }
Пример #35
0
 public void Read(__BinaryParser input)
 {
     this.idRef = input.ReadInt32();
 }
        [System.Security.SecurityCritical] // implements Critical method
        public void Read(__BinaryParser input) 
        { 
            objectId = input.ReadInt32();
            name = input.ReadString(); 
            numMembers = input.ReadInt32();
            memberNames = new String[numMembers];
            for (int i=0; i<numMembers; i++)
            { 
                memberNames[i] = input.ReadString();
                SerTrace.Log(this, "BinaryObjectWithMap Read ",i," ",memberNames[i]); 
            } 

            if (binaryHeaderEnum == BinaryHeaderEnum.ObjectWithMapAssemId) 
            {
                assemId = input.ReadInt32();
            }
        } 
Пример #37
0
 public void Read(__BinaryParser input)
 {
     this.objectId = input.ReadInt32();
     this.mapId    = input.ReadInt32();
 }
        [System.Security.SecurityCritical] // implements Critical method 
        public void Read(__BinaryParser input)
        { 
            // binaryHeaderEnum has already been read 
            objectId = input.ReadInt32();
            name = input.ReadString(); 
            numMembers = input.ReadInt32();
            memberNames = new String[numMembers];
            binaryTypeEnumA = new BinaryTypeEnum[numMembers];
            typeInformationA = new Object[numMembers]; 
            memberAssemIds = new Int32[numMembers];
            for (int i=0; i<numMembers; i++) 
                memberNames[i] = input.ReadString(); 
            for (int i=0; i<numMembers; i++)
                binaryTypeEnumA[i] = (BinaryTypeEnum)input.ReadByte(); 
            for (int i=0; i<numMembers; i++)
                if (binaryTypeEnumA[i] != BinaryTypeEnum.ObjectUrt && binaryTypeEnumA[i] != BinaryTypeEnum.ObjectUser)
                    typeInformationA[i] = BinaryConverter.ReadTypeInfo(binaryTypeEnumA[i], input, out memberAssemIds[i]);
                else 
                    BinaryConverter.ReadTypeInfo(binaryTypeEnumA[i], input, out memberAssemIds[i]);
 
            if (binaryHeaderEnum == BinaryHeaderEnum.ObjectWithMapTypedAssemId) 
            {
                assemId = input.ReadInt32(); 
            }
        }
 [System.Security.SecurityCritical] // implements Critical method
 public void Read(__BinaryParser input)
 {
     switch (binaryHeaderEnum) 
     {
         case BinaryHeaderEnum.ArraySinglePrimitive: 
             objectId = input.ReadInt32(); 
             lengthA = new int[1];
             lengthA[0] = input.ReadInt32(); 
             binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
             rank = 1;
             lowerBoundA = new Int32[rank];
             binaryTypeEnum = BinaryTypeEnum.Primitive; 
             typeInformation = (InternalPrimitiveTypeE)input.ReadByte();
             break; 
         case BinaryHeaderEnum.ArraySingleString: 
             objectId = input.ReadInt32();
             lengthA = new int[1]; 
             lengthA[0] = (int)input.ReadInt32();
             binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
             rank = 1;
             lowerBoundA = new Int32[rank]; 
             binaryTypeEnum = BinaryTypeEnum.String;
             typeInformation = null; 
             break; 
         case BinaryHeaderEnum.ArraySingleObject:
             objectId = input.ReadInt32(); 
             lengthA = new int[1];
             lengthA[0] = (int)input.ReadInt32();
             binaryArrayTypeEnum = BinaryArrayTypeEnum.Single;
             rank = 1; 
             lowerBoundA = new Int32[rank];
             binaryTypeEnum = BinaryTypeEnum.Object; 
             typeInformation = null; 
             break;
 default: 
             objectId = input.ReadInt32();
             binaryArrayTypeEnum = (BinaryArrayTypeEnum)input.ReadByte();
             rank = input.ReadInt32();
             lengthA = new Int32[rank]; 
             lowerBoundA = new Int32[rank];
             for (int i=0; i<rank; i++) 
                 lengthA[i] = input.ReadInt32(); 
             if ((binaryArrayTypeEnum == BinaryArrayTypeEnum.SingleOffset) ||
                 (binaryArrayTypeEnum == BinaryArrayTypeEnum.JaggedOffset) || 
                 (binaryArrayTypeEnum == BinaryArrayTypeEnum.RectangularOffset))
             {
                 for (int i=0; i<rank; i++)
                     lowerBoundA[i] = input.ReadInt32(); 
             }
             binaryTypeEnum = (BinaryTypeEnum)input.ReadByte(); 
             typeInformation = BinaryConverter.ReadTypeInfo(binaryTypeEnum, input, out assemId); 
             break;
     } 
 }
 [System.Security.SecurityCritical] // implements Critical method
 public void Read(__BinaryParser input)
 { 
     //binaryHeaderEnum = input.ReadByte(); already read
     idRef = input.ReadInt32(); 
 } 
Пример #41
0
 public void Read(__BinaryParser input)
 {
     this.assemId        = input.ReadInt32();
     this.assemblyString = input.ReadString();
 }
 public  void Read(__BinaryParser input, BinaryHeaderEnum binaryHeaderEnum) 
 {
     //binaryHeaderEnum = input.ReadByte(); already read 
     switch (binaryHeaderEnum) 
     {
         case BinaryHeaderEnum.ObjectNull: 
             nullCount = 1;
             break;
         case BinaryHeaderEnum.ObjectNullMultiple256:
             nullCount = input.ReadByte(); 
             //Console.WriteLine("Read nullCount "+nullCount);
             break; 
         case BinaryHeaderEnum.ObjectNullMultiple: 
             nullCount = input.ReadInt32();
             //Console.WriteLine("Read nullCount "+nullCount); 
             break;
     }
 }
        [System.Security.SecurityCritical]  // auto-generated 
        public void Read(__BinaryParser input)
        { 
             messageEnum = (MessageEnum)input.ReadInt32();

             if (IOUtil.FlagTest(messageEnum, MessageEnum.NoReturnValue))
                 returnValue = null; 
             else if (IOUtil.FlagTest(messageEnum, MessageEnum.ReturnValueVoid))
             { 
                 returnValue = instanceOfVoid; 
             }
             else if (IOUtil.FlagTest(messageEnum, MessageEnum.ReturnValueInline)) 
                 returnValue = IOUtil.ReadWithCode(input);

#if FEATURE_REMOTING
             if (IOUtil.FlagTest(messageEnum, MessageEnum.ContextInline)) 
             {
                 scallContext = (String)IOUtil.ReadWithCode(input); 
                 LogicalCallContext lcallContext = new LogicalCallContext(); 
                 lcallContext.RemotingData.LogicalCallID = scallContext;
                 callContext = lcallContext; 
             }
#endif
             if (IOUtil.FlagTest(messageEnum, MessageEnum.ArgsInline))
                 args = IOUtil.ReadArgs(input); 
        }
Пример #44
0
        public void Read(__BinaryParser input)
        {
             messageEnum = (MessageEnum)input.ReadInt32();

             if (IOUtil.FlagTest(messageEnum, MessageEnum.NoReturnValue))
                 returnValue = null;
             else if (IOUtil.FlagTest(messageEnum, MessageEnum.ReturnValueVoid))
             {
                 returnValue = FormatterServices.GetUninitializedObject(Converter.typeofSystemVoid);            
             }
             else if (IOUtil.FlagTest(messageEnum, MessageEnum.ReturnValueInline))
                 returnValue = IOUtil.ReadWithCode(input);

             if (IOUtil.FlagTest(messageEnum, MessageEnum.ContextInline))
             {
                 scallContext = (String)IOUtil.ReadWithCode(input);
                 LogicalCallContext lcallContext = new LogicalCallContext();
                 lcallContext.RemotingData.LogicalCallID = scallContext;
                 callContext = lcallContext;
             }

             if (IOUtil.FlagTest(messageEnum, MessageEnum.ArgsInline))
                 args = IOUtil.ReadArgs(input);
        }