private SizedArray(SizedArray sizedArray)
 {
     objects = new object[sizedArray.objects.Length];
     sizedArray.objects.CopyTo(objects, 0);
     negObjects = new object[sizedArray.negObjects.Length];
     sizedArray.negObjects.CopyTo(negObjects, 0);
 }
Exemplo n.º 2
0
 public static ObjectMap Create(string name, string[] memberNames, BinaryTypeEnum[] binaryTypeEnumA, object[] typeInformationA, int[] memberAssemIds, ObjectReader objectReader, int objectId, BinaryAssemblyInfo assemblyInfo, SizedArray assemIdToAssemblyTable)
 {
     return(new ObjectMap(name, memberNames, binaryTypeEnumA, typeInformationA, memberAssemIds, objectReader, objectId, assemblyInfo, assemIdToAssemblyTable));
 }
Exemplo n.º 3
0
 public ObjectMap(string objectName, string[] memberNames, BinaryTypeEnum[] binaryTypeEnumA, object[] typeInformationA, int[] memberAssemIds, ObjectReader objectReader, int objectId, BinaryAssemblyInfo assemblyInfo, SizedArray assemIdToAssemblyTable)
 {
     this._isInitObjectInfo = true;
     this._objectName       = objectName;
     this._memberNames      = memberNames;
     this._binaryTypeEnumA  = binaryTypeEnumA;
     this._typeInformationA = typeInformationA;
     this._objectReader     = objectReader;
     this._objectId         = objectId;
     this._assemblyInfo     = assemblyInfo;
     if (assemblyInfo == null)
     {
         throw new SerializationException(RemotingResources.SerializationAssemblyNotFound.Format(objectName));
     }
     this._objectType  = objectReader.GetType(assemblyInfo, objectName);
     this._memberTypes = new Type[memberNames.Length];
     for (int i = 0; i < memberNames.Length; i++)
     {
         BinaryTypeConverter.TypeFromInfo(binaryTypeEnumA[i], typeInformationA[i], objectReader, (BinaryAssemblyInfo)assemIdToAssemblyTable[memberAssemIds[i]], out _, out _, out Type type, out _);
         this._memberTypes[i] = type;
     }
     this._objectInfo = objectReader.CreateReadObjectInfo(this._objectType, memberNames, null);
     if (!this._objectInfo.IsSi)
     {
         this._objectInfo.GetMemberTypes(memberNames, this._objectInfo.ObjectType);
     }
 }