다음을 통해 공유


IVsProvideUserContextForObject.GetObjectContext Method

Definition

Return the user context (IVsUserContext interface) of an object.

public:
 int GetObjectContext(System::Object ^ punk, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IVsUserContext ^ % ppctx);
public:
 int GetObjectContext(Platform::Object ^ punk, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IVsUserContext ^ &  ppctx);
int GetObjectContext(winrt::Windows::Foundation::IInspectable const & punk, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IVsUserContext const & & ppctx);
public int GetObjectContext (object punk, out Microsoft.VisualStudio.Shell.Interop.IVsUserContext ppctx);
abstract member GetObjectContext : obj * IVsUserContext -> int
Public Function GetObjectContext (punk As Object, ByRef ppctx As IVsUserContext) As Integer

Parameters

punk
Object

[in] Pointer to the Microsoft.VisualStudio.IUnknown interface of the object.

ppctx
IVsUserContext

[out] Pointer to the user context (IVsUserContext) of the object.

Returns

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From context.idl:

[C++]

HRESULT IVsProvideUserContextForObject::GetObjectContext(  
   [in] IUnknown * punk,   
   [out, retval] IVsUserContext ** ppctx  
);  

Applies to