IVsComponentEnumeratorFactory2.GetComponents 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
为包中的所有组件提供枚举器。
public:
int GetComponents(System::String ^ bstrMachineName, int lEnumType, int bForceRefresh, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IEnumComponents ^ % pEnumerator);
public:
int GetComponents(Platform::String ^ bstrMachineName, int lEnumType, int bForceRefresh, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IEnumComponents ^ & pEnumerator);
int GetComponents(std::wstring const & bstrMachineName, int lEnumType, int bForceRefresh, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IEnumComponents const & & pEnumerator);
public int GetComponents (string bstrMachineName, int lEnumType, int bForceRefresh, out Microsoft.VisualStudio.Shell.Interop.IEnumComponents pEnumerator);
abstract member GetComponents : string * int * int * IEnumComponents -> int
Public Function GetComponents (bstrMachineName As String, lEnumType As Integer, bForceRefresh As Integer, ByRef pEnumerator As IEnumComponents) As Integer
参数
- bstrMachineName
- String
中保留,必须是 null 。
- bForceRefresh
- Int32
中保留,必须是 false 。
- pEnumerator
- IEnumComponents
弄指向枚举器对象的指针。 这会返回组件列表。 此列表可以是 COM 组件、Visual Studio 程序集,也可以是 Visual Studio 查找引用的目录列表。 列出的组件类型由确定 lEnumType 。
返回
如果该方法成功,则它会返回 S_OK。 如果该方法失败,则会返回错误代码。
实现
注解
COM 签名
从 compsvcspkg:
HRESULT IVsComponentEnumeratorFactory2::GetComponents(
[in] BSTR bstrMachineName,
[in] LONG lEnumType,
[in] BOOL bForceRefresh,
[out] IEnumComponents** pEnumerator
);