public static byte[] GetBytes(string path) { // Get Handle to Hard Drive IntPtr hDrive = NativeMethods.getHandle(path); // Create a FileStream to read from hDrive using (FileStream streamToRead = NativeMethods.getFileStream(hDrive)) { return(VolumeBootRecord.GetBytes(streamToRead)); } }
internal static VolumeBootRecord Get(FileStream streamToRead) { return(new VolumeBootRecord(VolumeBootRecord.GetBytes(streamToRead))); }
public static VolumeBootRecord Get(string path) { return(new VolumeBootRecord(VolumeBootRecord.GetBytes(path))); }