public int ReadFrom(byte[] buffer, int offset)
 {
     ExtentLength   = Utilities.ToUInt32LittleEndian(buffer, offset);
     ExtentLocation = new LogicalBlockAddress();
     ExtentLocation.ReadFrom(buffer, offset + 4);
     ImplementationUse = Utilities.ToByteArray(buffer, offset + 10, 6);
     return(16);
 }
 public int ReadFrom(byte[] buffer, int offset)
 {
     ExtentLength = Utilities.ToUInt32LittleEndian(buffer, offset);
     ExtentLocation = new LogicalBlockAddress();
     ExtentLocation.ReadFrom(buffer, offset + 4);
     ImplementationUse = Utilities.ToByteArray(buffer, offset + 10, 6);
     return 16;
 }
        public int ReadFrom(byte[] buffer, int offset)
        {
            uint len = Utilities.ToUInt32LittleEndian(buffer, offset);

            ExtentLength = len & 0x3FFFFFFF;
            Flags = (ShortAllocationFlags)((len >> 30) & 0x3);

            ExtentLocation = new LogicalBlockAddress();
            ExtentLocation.ReadFrom(buffer, offset + 4);
            ImplementationUse = Utilities.ToByteArray(buffer, offset + 10, 6);
            return 16;
        }
예제 #4
0
        public int ReadFrom(byte[] buffer, int offset)
        {
            uint len = Utilities.ToUInt32LittleEndian(buffer, offset);

            ExtentLength = len & 0x3FFFFFFF;
            Flags        = (ShortAllocationFlags)((len >> 30) & 0x3);

            ExtentLocation = new LogicalBlockAddress();
            ExtentLocation.ReadFrom(buffer, offset + 4);
            ImplementationUse = Utilities.ToByteArray(buffer, offset + 10, 6);
            return(16);
        }
        public int ReadFrom(byte[] buffer, int offset)
        {
            PriorDirectEntries = Utilities.ToUInt32LittleEndian(buffer, offset);
            StrategyType = Utilities.ToUInt16LittleEndian(buffer, offset + 4);
            StrategyParameter = Utilities.ToUInt16LittleEndian(buffer, offset + 6);
            MaxEntries = Utilities.ToUInt16LittleEndian(buffer, offset + 8);
            FileType = (FileType)buffer[offset + 11];
            ParentICBLocation = Utilities.ToStruct<LogicalBlockAddress>(buffer, offset + 12);

            ushort flagsField = Utilities.ToUInt16LittleEndian(buffer, offset + 18);
            AllocationType = (AllocationType)(flagsField & 0x3);
            Flags = (InformationControlBlockFlags)(flagsField & 0xFFFC);

            return 20;
        }
        public int ReadFrom(byte[] buffer, int offset)
        {
            PriorDirectEntries = Utilities.ToUInt32LittleEndian(buffer, offset);
            StrategyType       = Utilities.ToUInt16LittleEndian(buffer, offset + 4);
            StrategyParameter  = Utilities.ToUInt16LittleEndian(buffer, offset + 6);
            MaxEntries         = Utilities.ToUInt16LittleEndian(buffer, offset + 8);
            FileType           = (FileType)buffer[offset + 11];
            ParentICBLocation  = Utilities.ToStruct <LogicalBlockAddress>(buffer, offset + 12);

            ushort flagsField = Utilities.ToUInt16LittleEndian(buffer, offset + 18);

            AllocationType = (AllocationType)(flagsField & 0x3);
            Flags          = (InformationControlBlockFlags)(flagsField & 0xFFFC);

            return(20);
        }