C# Class ScpControl.Driver.Devcon

Managed wrapper for SetupAPI.
https://msdn.microsoft.com/en-us/library/windows/hardware/ff550897(v=vs.85).aspx
Mostra file Open project: nefarius/ScpToolkit

Public Methods

Method Description
Create ( string className, System.Guid classGuid, string node ) : bool
Find ( System.Guid target, string &path, string &instanceId, int instance ) : bool
Install ( string fullInfPath, bool &rebootRequired ) : bool
Refresh ( ) : bool
Remove ( System.Guid classGuid, string path, string instanceId ) : bool

Private Methods

Method Description
CM_Get_Device_ID ( int DevInst, IntPtr Buffer, int BufferLen, int Flags ) : int
CM_Locate_DevNode_Ex ( UInt32 &pdnDevInst, IntPtr pDeviceID, UInt32 ulFlags, IntPtr hMachine ) : UInt32
CM_Reenumerate_DevNode_Ex ( UInt32 dnDevInst, UInt32 ulFlags, IntPtr hMachine ) : UInt32
DiInstallDevice ( IntPtr hParent, IntPtr lpInfoSet, SP_DEVINFO_DATA &DeviceInfoData, SP_DRVINFO_DATA &DriverInfoData, DiFlags Flags, bool &NeedReboot ) : bool
DiInstallDriver ( IntPtr hwndParent, string FullInfPath, uint Flags, bool &NeedReboot ) : bool
SetupDiCallClassInstaller ( int InstallFunction, IntPtr DeviceInfoSet, SP_DEVINFO_DATA &DeviceInfoData ) : bool
SetupDiCreateDeviceInfo ( IntPtr DeviceInfoSet, string DeviceName, System.Guid &ClassGuid, string DeviceDescription, IntPtr hwndParent, int CreationFlags, SP_DEVINFO_DATA &DeviceInfoData ) : bool
SetupDiCreateDeviceInfoList ( System.Guid &ClassGuid, IntPtr hwndParent ) : IntPtr
SetupDiDestroyDeviceInfoList ( IntPtr DeviceInfoSet ) : bool
SetupDiEnumDeviceInterfaces ( IntPtr DeviceInfoSet, IntPtr DeviceInfoData, System.Guid &InterfaceClassGuid, int MemberIndex, SP_DEVINFO_DATA &DeviceInterfaceData ) : bool
SetupDiGetClassDevs ( System.Guid &ClassGuid, IntPtr Enumerator, IntPtr hwndParent, int Flags ) : IntPtr
SetupDiGetDeviceInterfaceDetail ( IntPtr DeviceInfoSet, SP_DEVINFO_DATA &DeviceInterfaceData, IntPtr DeviceInterfaceDetailData, int DeviceInterfaceDetailDataSize, int &RequiredSize, SP_DEVINFO_DATA &DeviceInfoData ) : bool
SetupDiOpenDeviceInfo ( IntPtr DeviceInfoSet, string DeviceInstanceId, IntPtr hwndParent, int Flags, SP_DEVINFO_DATA &DeviceInfoData ) : bool
SetupDiSetClassInstallParams ( IntPtr DeviceInfoSet, SP_DEVINFO_DATA &DeviceInterfaceData, SP_REMOVEDEVICE_PARAMS &ClassInstallParams, int ClassInstallParamsSize ) : bool
SetupDiSetDeviceRegistryProperty ( IntPtr DeviceInfoSet, SP_DEVINFO_DATA &DeviceInfoData, int Property, [ PropertyBuffer, int PropertyBufferSize ) : bool

Method Details

Create() public static method

public static Create ( string className, System.Guid classGuid, string node ) : bool
className string
classGuid System.Guid
node string
return bool

Find() public static method

public static Find ( System.Guid target, string &path, string &instanceId, int instance ) : bool
target System.Guid
path string
instanceId string
instance int
return bool

Install() public static method

public static Install ( string fullInfPath, bool &rebootRequired ) : bool
fullInfPath string
rebootRequired bool
return bool

Refresh() public static method

public static Refresh ( ) : bool
return bool

Remove() public static method

public static Remove ( System.Guid classGuid, string path, string instanceId ) : bool
classGuid System.Guid
path string
instanceId string
return bool