Skip to content

Commit 34940a1

Browse files
authored
Merge pull request #3930 from MicrosoftDocs/master
2/12/2019 AM Publish
2 parents 61dc40d + ae1e4ae commit 34940a1

File tree

42 files changed

+718
-862
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+718
-862
lines changed

docs/debugger/debug-interface-access/idiadatasource-opensession.md

Lines changed: 47 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -2,59 +2,59 @@
22
title: "IDiaDataSource::openSession | Microsoft Docs"
33
ms.date: "11/04/2016"
44
ms.topic: "conceptual"
5-
dev_langs:
5+
dev_langs:
66
- "C++"
7-
helpviewer_keywords:
7+
helpviewer_keywords:
88
- "IDiaDataSource::openSession method"
99
ms.assetid: a3319ed0-3979-483b-9852-c0af96852c48
1010
author: "mikejo5000"
1111
ms.author: "mikejo"
1212
manager: jillfra
13-
ms.workload:
13+
ms.workload:
1414
- "multiple"
1515
---
1616
# IDiaDataSource::openSession
17-
Opens a session for querying symbols.
18-
19-
## Syntax
20-
21-
```C++
22-
HRESULT openSession
23-
IDiaSession** ppSession
24-
);
25-
```
26-
27-
#### Parameters
28-
ppSession
29-
[out] Returns an [IDiaSession](../../debugger/debug-interface-access/idiasession.md) object representing the open session.
30-
31-
## Return Value
32-
If successful, returns `S_OK`; otherwise, returns an error code. The following table shows the possible return values for this method.
33-
34-
|Value|Description|
35-
|-----------|-----------------|
36-
|E_UNEXPECTED|The [IDiaDataSource](../../debugger/debug-interface-access/idiadatasource.md) object has not previously been initialized with a source of symbols.|
37-
|E_INVALIDARG|Invalid `ppSession` parameter.|
38-
|E_OUTOFMEMORY|Insufficient memory to open the session.|
39-
40-
## Remarks
41-
This method opens an [IDiaSession](../../debugger/debug-interface-access/idiasession.md) object for a data source.
42-
43-
`IDiaSession` objects implement queries into the data source. A session manages one address space for each set of debug symbols. If the .exe or .dll file described by the data source symbols is active in multiple address ranges (for example, because multiple processes have it loaded), then one session for each address range should be used.
44-
45-
## Example
46-
47-
```C++
48-
IDiaSession* pSession;
49-
HRESULT hr = pSource->openSession( &pSession );
50-
if (FAILED(hr))
51-
{
52-
// report error
53-
}
54-
```
55-
56-
## See Also
57-
[IDiaDataSource](../../debugger/debug-interface-access/idiadatasource.md)
58-
[Overview](../../debugger/debug-interface-access/overview-debug-interface-access-sdk.md)
59-
[IDiaSession](../../debugger/debug-interface-access/idiasession.md)
60-
[Querying the .Pdb File](../../debugger/debug-interface-access/querying-the-dot-pdb-file.md)
17+
Opens a session for querying symbols.
18+
19+
## Syntax
20+
21+
```C++
22+
HRESULT openSession
23+
IDiaSession** ppSession
24+
);
25+
```
26+
27+
#### Parameters
28+
ppSession
29+
[out] Returns an [IDiaSession](../../debugger/debug-interface-access/idiasession.md) object representing the open session.
30+
31+
## Return Value
32+
If successful, returns `S_OK`; otherwise, returns an error code. The following table shows the possible return values for this method.
33+
34+
|Value|Description|
35+
|-----------|-----------------|
36+
|E_UNEXPECTED|The [IDiaDataSource](../../debugger/debug-interface-access/idiadatasource.md) object has not previously been initialized with a source of symbols.|
37+
|E_INVALIDARG|Invalid `ppSession` parameter.|
38+
|E_OUTOFMEMORY|Insufficient memory to open the session.|
39+
40+
## Remarks
41+
This method opens an [IDiaSession](../../debugger/debug-interface-access/idiasession.md) object for a data source.
42+
43+
`IDiaSession` objects implement queries into the data source. A session manages one address space for each set of debug symbols. If the .exe or .dll file described by the data source symbols is active in multiple address ranges (for example, because multiple processes have it loaded), then one session for each address range should be used.
44+
45+
## Example
46+
47+
```C++
48+
IDiaSession* pSession;
49+
HRESULT hr = pSource->openSession( &pSession );
50+
if (FAILED(hr))
51+
{
52+
// report error
53+
}
54+
```
55+
56+
## See Also
57+
[IDiaDataSource](../../debugger/debug-interface-access/idiadatasource.md)
58+
[Overview](../../debugger/debug-interface-access/overview-debug-interface-access-sdk.md)
59+
[IDiaSession](../../debugger/debug-interface-access/idiasession.md)
60+
[Querying the .Pdb File](../../debugger/debug-interface-access/querying-the-dot-pdb-file.md)

docs/debugger/debug-interface-access/idiaenumdebugstreams.md

Lines changed: 71 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -2,83 +2,83 @@
22
title: "IDiaEnumDebugStreams | Microsoft Docs"
33
ms.date: "11/04/2016"
44
ms.topic: "conceptual"
5-
dev_langs:
5+
dev_langs:
66
- "C++"
7-
helpviewer_keywords:
7+
helpviewer_keywords:
88
- "IDiaEnumDebugStreams interface"
99
ms.assetid: 611caf4f-7a5f-4aa4-b909-52feeb3cc752
1010
author: "mikejo5000"
1111
ms.author: "mikejo"
1212
manager: jillfra
13-
ms.workload:
13+
ms.workload:
1414
- "multiple"
1515
---
1616
# IDiaEnumDebugStreams
17-
Enumerates the various debug streams contained in the data source.
18-
19-
## Syntax
20-
21-
```
22-
IDiaEnumDebugStreams : IUnknown
23-
```
24-
25-
## Methods in Vtable Order
26-
The following table shows the methods of `IDiaEnumDebugStreams`.
27-
28-
|Method|Description|
29-
|------------|-----------------|
30-
|[IDiaEnumDebugStreams::get__NewEnum](../../debugger/debug-interface-access/idiaenumdebugstreams-get-newenum.md)|Retrieves the `IEnumVARIANT` version of this enumerator.|
31-
|[IDiaEnumDebugStreams::get_Count](../../debugger/debug-interface-access/idiaenumdebugstreams-get-count.md)|Retrieves the number of debug streams.|
32-
|[IDiaEnumDebugStreams::Item](../../debugger/debug-interface-access/idiaenumdebugstreams-item.md)|Retrieves a debug stream by means of an index.|
33-
|[IDiaEnumDebugStreams::Next](../../debugger/debug-interface-access/idiaenumdebugstreams-next.md)|Retrieves a specified number of debug streams in the enumeration sequence.|
34-
|[IDiaEnumDebugStreams::Skip](../../debugger/debug-interface-access/idiaenumdebugstreams-skip.md)|Skips a specified number of debug streams in an enumeration sequence.|
35-
|[IDiaEnumDebugStreams::Reset](../../debugger/debug-interface-access/idiaenumdebugstreams-reset.md)|Resets an enumeration sequence to the beginning.|
36-
|[IDiaEnumDebugStreams::Clone](../../debugger/debug-interface-access/idiaenumdebugstreams-clone.md)|Creates an enumerator that contains the same enumeration state as the current enumerator.|
37-
38-
## Remarks
39-
The content of debug streams is implementation-dependent and the data formats are undocumented.
40-
41-
## Notes for Callers
42-
Call the [IDiaSession::getEnumDebugStreams](../../debugger/debug-interface-access/idiasession-getenumdebugstreams.md) method to obtain an `IDiaEnumDebugStreams` object.
43-
44-
## Example
45-
This example shows how to access the data streams available from this interface. See the [IDiaEnumDebugStreamData](../../debugger/debug-interface-access/idiaenumdebugstreamdata.md) interface for an implementation of the `PrintStreamData` function.
46-
47-
```C++
48-
void DumpAllDebugStreams( IDiaSession* pSession)
49-
{
50-
IDiaEnumDebugStreams* pEnumStreams;
51-
52-
wprintf(L"\n\n*** DEBUG STREAMS\n\n");
53-
// Retrieve an enumerated sequence of debug data streams
54-
if(pSession->getEnumDebugStreams(&pEnumStreams) == S_OK)
55-
{
56-
IDiaEnumDebugStreamData* pStream;
57-
ULONG celt = 0;
58-
59-
for(; pEnumStreams->Next(1, &pStream, &celt) == S_OK; pStream = NULL)
60-
{
61-
PrintStreamData(pStream);
62-
pStream->Release();
63-
}
64-
pEnumStreams->Release();
65-
}
66-
else
67-
{
68-
wprintf(L"Failed to get any debug streams!\n");
69-
}
70-
wprintf(L"\n");
71-
}
72-
```
73-
74-
## Requirements
75-
Header: Dia2.h
76-
77-
Library: diaguids.lib
78-
79-
DLL: msdia80.dll
80-
81-
## See Also
82-
[Interfaces (Debug Interface Access SDK)](../../debugger/debug-interface-access/interfaces-debug-interface-access-sdk.md)
83-
[IDiaEnumDebugStreamData](../../debugger/debug-interface-access/idiaenumdebugstreamdata.md)
84-
[IDiaSession::getEnumDebugStreams](../../debugger/debug-interface-access/idiasession-getenumdebugstreams.md)
17+
Enumerates the various debug streams contained in the data source.
18+
19+
## Syntax
20+
21+
```
22+
IDiaEnumDebugStreams : IUnknown
23+
```
24+
25+
## Methods in Vtable Order
26+
The following table shows the methods of `IDiaEnumDebugStreams`.
27+
28+
|Method|Description|
29+
|------------|-----------------|
30+
|[IDiaEnumDebugStreams::get__NewEnum](../../debugger/debug-interface-access/idiaenumdebugstreams-get-newenum.md)|Retrieves the `IEnumVARIANT` version of this enumerator.|
31+
|[IDiaEnumDebugStreams::get_Count](../../debugger/debug-interface-access/idiaenumdebugstreams-get-count.md)|Retrieves the number of debug streams.|
32+
|[IDiaEnumDebugStreams::Item](../../debugger/debug-interface-access/idiaenumdebugstreams-item.md)|Retrieves a debug stream by means of an index.|
33+
|[IDiaEnumDebugStreams::Next](../../debugger/debug-interface-access/idiaenumdebugstreams-next.md)|Retrieves a specified number of debug streams in the enumeration sequence.|
34+
|[IDiaEnumDebugStreams::Skip](../../debugger/debug-interface-access/idiaenumdebugstreams-skip.md)|Skips a specified number of debug streams in an enumeration sequence.|
35+
|[IDiaEnumDebugStreams::Reset](../../debugger/debug-interface-access/idiaenumdebugstreams-reset.md)|Resets an enumeration sequence to the beginning.|
36+
|[IDiaEnumDebugStreams::Clone](../../debugger/debug-interface-access/idiaenumdebugstreams-clone.md)|Creates an enumerator that contains the same enumeration state as the current enumerator.|
37+
38+
## Remarks
39+
The content of debug streams is implementation-dependent and the data formats are undocumented.
40+
41+
## Notes for Callers
42+
Call the [IDiaSession::getEnumDebugStreams](../../debugger/debug-interface-access/idiasession-getenumdebugstreams.md) method to obtain an `IDiaEnumDebugStreams` object.
43+
44+
## Example
45+
This example shows how to access the data streams available from this interface. See the [IDiaEnumDebugStreamData](../../debugger/debug-interface-access/idiaenumdebugstreamdata.md) interface for an implementation of the `PrintStreamData` function.
46+
47+
```C++
48+
void DumpAllDebugStreams( IDiaSession* pSession)
49+
{
50+
IDiaEnumDebugStreams* pEnumStreams;
51+
52+
wprintf(L"\n\n*** DEBUG STREAMS\n\n");
53+
// Retrieve an enumerated sequence of debug data streams
54+
if(pSession->getEnumDebugStreams(&pEnumStreams) == S_OK)
55+
{
56+
IDiaEnumDebugStreamData* pStream;
57+
ULONG celt = 0;
58+
59+
for(; pEnumStreams->Next(1, &pStream, &celt) == S_OK; pStream = NULL)
60+
{
61+
PrintStreamData(pStream);
62+
pStream->Release();
63+
}
64+
pEnumStreams->Release();
65+
}
66+
else
67+
{
68+
wprintf(L"Failed to get any debug streams!\n");
69+
}
70+
wprintf(L"\n");
71+
}
72+
```
73+
74+
## Requirements
75+
Header: Dia2.h
76+
77+
Library: diaguids.lib
78+
79+
DLL: msdia80.dll
80+
81+
## See Also
82+
[Interfaces (Debug Interface Access SDK)](../../debugger/debug-interface-access/interfaces-debug-interface-access-sdk.md)
83+
[IDiaEnumDebugStreamData](../../debugger/debug-interface-access/idiaenumdebugstreamdata.md)
84+
[IDiaSession::getEnumDebugStreams](../../debugger/debug-interface-access/idiasession-getenumdebugstreams.md)

0 commit comments

Comments
 (0)