Read() public method

public Read ( __BinaryParser input ) : void
input __BinaryParser
return void
        internal void ReadAssembly(BinaryHeaderEnum binaryHeaderEnum)
        {
            SerTrace.Log(this, "ReadAssembly");
            BinaryAssembly record = new BinaryAssembly();

            if (binaryHeaderEnum == BinaryHeaderEnum.CrossAppDomainAssembly)
            {
                BinaryCrossAppDomainAssembly crossAppDomainAssembly = new BinaryCrossAppDomainAssembly();
                crossAppDomainAssembly.Read(this);
                crossAppDomainAssembly.Dump();
                record.assemId        = crossAppDomainAssembly.assemId;
                record.assemblyString = objectReader.CrossAppDomainArray(crossAppDomainAssembly.assemblyIndex) as String;
                if (record.assemblyString == null)
                {
                    throw new SerializationException(String.Format(Environment.GetResourceString("Serialization_CrossAppDomainError"), "String", crossAppDomainAssembly.assemblyIndex));
                }
            }
            else
            {
                record.Read(this);
                record.Dump();
            }

            AssemIdToAssemblyTable[record.assemId] = new BinaryAssemblyInfo(record.assemblyString);
        }
Example #2
0
        internal void ReadAssembly(BinaryHeaderEnum binaryHeaderEnum)
        {
            var record = new BinaryAssembly();

            if (binaryHeaderEnum == BinaryHeaderEnum.CrossAppDomainAssembly)
            {
                var crossAppDomainAssembly = new BinaryCrossAppDomainAssembly();
                crossAppDomainAssembly.Read(this);
                record._assemId        = crossAppDomainAssembly._assemId;
                record._assemblyString = _objectReader.CrossAppDomainArray(crossAppDomainAssembly._assemblyIndex) as string;
                if (record._assemblyString == null)
                {
                    throw new SerializationException(SR.Format(SR.Serialization_CrossAppDomainError, "String", crossAppDomainAssembly._assemblyIndex));
                }
            }
            else
            {
                record.Read(this);
            }

            AssemIdToAssemblyTable[record._assemId] = new BinaryAssemblyInfo(record._assemblyString);
        }
Example #3
0
        internal void ReadAssembly(BinaryHeaderEnum binaryHeaderEnum)
        {
            BinaryAssembly binaryAssembly = new BinaryAssembly();

            if (binaryHeaderEnum == BinaryHeaderEnum.CrossAppDomainAssembly)
            {
                BinaryCrossAppDomainAssembly appDomainAssembly = new BinaryCrossAppDomainAssembly();
                appDomainAssembly.Read(this);
                appDomainAssembly.Dump();
                binaryAssembly.assemId        = appDomainAssembly.assemId;
                binaryAssembly.assemblyString = this.objectReader.CrossAppDomainArray(appDomainAssembly.assemblyIndex) as string;
                if (binaryAssembly.assemblyString == null)
                {
                    throw new SerializationException(Environment.GetResourceString("Serialization_CrossAppDomainError", (object)"String", (object)appDomainAssembly.assemblyIndex));
                }
            }
            else
            {
                binaryAssembly.Read(this);
                binaryAssembly.Dump();
            }
            this.AssemIdToAssemblyTable[binaryAssembly.assemId] = (object)new BinaryAssemblyInfo(binaryAssembly.assemblyString);
        }
Example #4
0
        internal void ReadAssembly(BinaryHeaderEnum binaryHeaderEnum)
        {
            var record = new BinaryAssembly();
            if (binaryHeaderEnum == BinaryHeaderEnum.CrossAppDomainAssembly)
            {
                var crossAppDomainAssembly = new BinaryCrossAppDomainAssembly();
                crossAppDomainAssembly.Read(this);
                record._assemId = crossAppDomainAssembly._assemId;
                record._assemblyString = _objectReader.CrossAppDomainArray(crossAppDomainAssembly._assemblyIndex) as string;
                if (record._assemblyString == null)
                {
                    throw new SerializationException(SR.Format(SR.Serialization_CrossAppDomainError, "String", crossAppDomainAssembly._assemblyIndex));
                }
            }
            else
            {
                record.Read(this);
            }

            AssemIdToAssemblyTable[record._assemId] = new BinaryAssemblyInfo(record._assemblyString);
        }
        internal void ReadAssembly(BinaryHeaderEnum binaryHeaderEnum)
        {
            SerTrace.Log( this, "ReadAssembly");
            BinaryAssembly record = new BinaryAssembly();
            if (binaryHeaderEnum == BinaryHeaderEnum.CrossAppDomainAssembly)
            {
                BinaryCrossAppDomainAssembly crossAppDomainAssembly = new BinaryCrossAppDomainAssembly();
                crossAppDomainAssembly.Read(this);
                crossAppDomainAssembly.Dump();
                record.assemId = crossAppDomainAssembly.assemId;
                record.assemblyString = objectReader.CrossAppDomainArray(crossAppDomainAssembly.assemblyIndex) as String;
                if (record.assemblyString == null)
                    throw new SerializationException(Environment.GetResourceString("Serialization_CrossAppDomainError","String", crossAppDomainAssembly.assemblyIndex));

            }
            else
            {
                record.Read(this);
                record.Dump();
            }

            AssemIdToAssemblyTable[record.assemId] = new BinaryAssemblyInfo(record.assemblyString);
        }
 internal void ReadAssembly(BinaryHeaderEnum binaryHeaderEnum)
 {
     BinaryAssembly assembly = new BinaryAssembly();
     if (binaryHeaderEnum == BinaryHeaderEnum.CrossAppDomainAssembly)
     {
         BinaryCrossAppDomainAssembly assembly2 = new BinaryCrossAppDomainAssembly();
         assembly2.Read(this);
         assembly2.Dump();
         assembly.assemId = assembly2.assemId;
         assembly.assemblyString = this.objectReader.CrossAppDomainArray(assembly2.assemblyIndex) as string;
         if (assembly.assemblyString == null)
         {
             throw new SerializationException(Environment.GetResourceString("Serialization_CrossAppDomainError", new object[] { "String", assembly2.assemblyIndex }));
         }
     }
     else
     {
         assembly.Read(this);
         assembly.Dump();
     }
     this.AssemIdToAssemblyTable[assembly.assemId] = new BinaryAssemblyInfo(assembly.assemblyString);
 }