IDebugPortRequest2::GetPortName
Note
This article applies to Visual Studio 2015. If you're looking for the latest Visual Studio documentation, see Visual Studio documentation. We recommend upgrading to the latest version of Visual Studio. Download it here
Gets the name of the port.
Syntax
HRESULT GetPortName(
BSTR* pbstrPortName
);
int GetPortName(
out string pbstrPortName
);
Parameters
pbstrPortName
[out] Returns the name of the port.
Return Value
If successful, returns S_OK
; otherwise, returns an error code.
Remarks
The IDebugPortRequest2 interface is usually passed from a debug package (the client) to a port supplier (the server) to obtain a connection to a port. Both the debug package and the port supplier are aware of the possible choices for the port. If a simple string can describe the port, then the IDebugPortRequest2::GetPortName
method has enough information to make the connection. Otherwise, additional interfaces can be provided by the client, which can be obtained by the server using IDebugPortRequest2::QueryInterface
.