コード例 #1
0
        /// <summary>
        /// Opens a volume system.
        /// </summary>
        /// <returns></returns>
        public VolumeSystem OpenVolumeSystem()
        {
            var vs = new VolumeSystem(this);

            if (vs._handle.IsInvalid)
            {
                vs._handle.Close();
                vs = null;
            }
            return(vs);
        }
コード例 #2
0
        /// <summary>
        /// ctor, for internal use only
        /// </summary>
        /// <param name="volumeSystem"></param>
        /// <param name="ptrToVolumeInfo"></param>
        internal Volume(VolumeSystem volumeSystem, IntPtr ptrToVolumeInfo)
        {
            this._system = volumeSystem;

            this._ptr_volinfo = ptrToVolumeInfo;
            var v = TSK_VS_PART_INFO.FromIntPtr(ptrToVolumeInfo);

            if (v.HasValue)
            {
                this._struct = v.Value;
            }
        }