public virtual void ReadByte(byte[] data) { GCHandle handle = GCHandle.Alloc(data, GCHandleType.Pinned); _volumeDescriptor = (_VolumeDescriptor)Marshal.PtrToStructure(handle.AddrOfPinnedObject(), typeof(_VolumeDescriptor)); handle.Free(); }
public void ReadByte(byte[] data) { GCHandle handle = GCHandle.Alloc(data,GCHandleType.Pinned); _volumeDescriptor = (_VolumeDescriptor)Marshal.PtrToStructure(handle.AddrOfPinnedObject(),typeof(_VolumeDescriptor)); handle.Free(); }
public VolumeDescriptor() { _volumeDescriptor = new _VolumeDescriptor(); }