Skip to content

Commit 96bbff5

Browse files
authored
Merge pull request #1124 from msebolt/consolidation-oledb-pr13
Consolidation oledb pr13
2 parents 8b05530 + e9d1ba5 commit 96bbff5

19 files changed

+414
-604
lines changed

.openpublishing.redirection.json

+65
Original file line numberDiff line numberDiff line change
@@ -905,6 +905,71 @@
905905
"redirect_url": "/cpp/data/oledb/cdynamicstringaccessor-class#setstring",
906906
"redirect_document_id": false
907907
},
908+
{
909+
"source_path": "docs/data/oledb/cenumerator-find.md",
910+
"redirect_url": "/cpp/data/oledb/cenumerator-class#find",
911+
"redirect_document_id": false
912+
},
913+
{
914+
"source_path": "docs/data/oledb/cenumerator-getmoniker.md",
915+
"redirect_url": "/cpp/data/oledb/cenumerator-class#getmoniker",
916+
"redirect_document_id": false
917+
},
918+
{
919+
"source_path": "docs/data/oledb/cenumerator-open.md",
920+
"redirect_url": "/cpp/data/oledb/cenumerator-class#open",
921+
"redirect_document_id": false
922+
},
923+
{
924+
"source_path": "docs/data/oledb/cenumeratoraccessor-m-bisparent.md",
925+
"redirect_url": "/cpp/data/oledb/cenumeratoraccessor-class#bisparent",
926+
"redirect_document_id": false
927+
},
928+
{
929+
"source_path": "docs/data/oledb/cenumeratoraccessor-m-ntype.md",
930+
"redirect_url": "/cpp/data/oledb/cenumeratoraccessor-class#ntype",
931+
"redirect_document_id": false
932+
},
933+
{
934+
"source_path": "docs/data/oledb/cenumeratoraccessor-m-szdescription.md",
935+
"redirect_url": "/cpp/data/oledb/cenumeratoraccessor-class#szdescription",
936+
"redirect_document_id": false
937+
},
938+
{
939+
"source_path": "docs/data/oledb/cenumeratoraccessor-m-szname.md",
940+
"redirect_url": "/cpp/data/oledb/cenumeratoraccessor-class#szname",
941+
"redirect_document_id": false
942+
},
943+
{
944+
"source_path": "docs/data/oledb/cenumeratoraccessor-m-szparsename.md",
945+
"redirect_url": "/cpp/data/oledb/cenumeratoraccessor-class#szparsename",
946+
"redirect_document_id": false
947+
},
948+
{
949+
"source_path": "docs/data/oledb/cmanualaccessor-addbindentry.md",
950+
"redirect_url": "/cpp/data/oledb/cmanualaccessor-class#addbindentry",
951+
"redirect_document_id": false
952+
},
953+
{
954+
"source_path": "docs/data/oledb/cmanualaccessor-addparameterentry.md",
955+
"redirect_url": "/cpp/data/oledb/cmanualaccessor-class#addparameterentry",
956+
"redirect_document_id": false
957+
},
958+
{
959+
"source_path": "docs/data/oledb/cmanualaccessor-createaccessor.md",
960+
"redirect_url": "/cpp/data/oledb/cmanualaccessor-class#createaccessor",
961+
"redirect_document_id": false
962+
},
963+
{
964+
"source_path": "docs/data/oledb/cmanualaccessor-createparameteraccessor.md",
965+
"redirect_url": "/cpp/data/oledb/cmanualaccessor-class#createparameteraccessor",
966+
"redirect_document_id": false
967+
},
968+
{
969+
"source_path": "docs/data/oledb/crestrictions-open.md",
970+
"redirect_url": "/cpp/data/oledb/crestrictions-class#open",
971+
"redirect_document_id": false
972+
},
908973
{
909974
"source_path": "docs/dotnet/index.md",
910975
"redirect_url": "/cpp/dotnet/dotnet-programming-with-cpp-cli-visual-cpp",

docs/data/oledb/TOC.md

-13
Original file line numberDiff line numberDiff line change
@@ -110,26 +110,13 @@
110110
### [CDynamicStringAccessorA Class](cdynamicstringaccessora-class.md)
111111
### [CDynamicStringAccessorW Class](cdynamicstringaccessorw-class.md)
112112
### [CEnumerator Class](cenumerator-class.md)
113-
#### [CEnumerator::Find](cenumerator-find.md)
114-
#### [CEnumerator::GetMoniker](cenumerator-getmoniker.md)
115-
#### [CEnumerator::Open](cenumerator-open.md)
116113
### [CEnumeratorAccessor Class](cenumeratoraccessor-class.md)
117-
#### [CEnumeratorAccessor::m_bIsParent](cenumeratoraccessor-m-bisparent.md)
118-
#### [CEnumeratorAccessor::m_nType](cenumeratoraccessor-m-ntype.md)
119-
#### [CEnumeratorAccessor::m_szDescription](cenumeratoraccessor-m-szdescription.md)
120-
#### [CEnumeratorAccessor::m_szName](cenumeratoraccessor-m-szname.md)
121-
#### [CEnumeratorAccessor::m_szParseName](cenumeratoraccessor-m-szparsename.md)
122114
### [CManualAccessor Class](cmanualaccessor-class.md)
123-
#### [CManualAccessor::AddBindEntry](cmanualaccessor-addbindentry.md)
124-
#### [CManualAccessor::AddParameterEntry](cmanualaccessor-addparameterentry.md)
125-
#### [CManualAccessor::CreateAccessor](cmanualaccessor-createaccessor.md)
126-
#### [CManualAccessor::CreateParameterAccessor](cmanualaccessor-createparameteraccessor.md)
127115
### [CMultipleResults Class](cmultipleresults-class.md)
128116
### [CNoAccessor Class](cnoaccessor-class.md)
129117
### [CNoMultipleResults Class](cnomultipleresults-class.md)
130118
### [CNoRowset Class](cnorowset-class.md)
131119
### [CRestrictions Class](crestrictions-class.md)
132-
#### [CRestrictions::Open](crestrictions-open.md)
133120
### [CRowset Class](crowset-class.md)
134121
#### [CRowset::AddRefRows](crowset-addrefrows.md)
135122
#### [CRowset::Close](crowset-close.md)

docs/data/oledb/cenumerator-class.md

+81-9
Original file line numberDiff line numberDiff line change
@@ -4,39 +4,111 @@ ms.custom: ""
44
ms.date: "11/04/2016"
55
ms.technology: ["cpp-data"]
66
ms.topic: "reference"
7-
f1_keywords: ["CEnumerator"]
7+
f1_keywords: ["CEnumerator", "CEnumerator::Find", "ATL::CEnumerator::Find", "ATL.CEnumerator.Find", "CEnumerator.Find",
8+
"GetMoniker", "CEnumerator.GetMoniker", "CEnumerator::GetMoniker", "ATL.CEnumerator.GetMoniker", "ATL::CEnumerator::GetMoniker",
9+
"ATL.CEnumerator.Open", "CEnumerator::Open", "ATL::CEnumerator::Open", "CEnumerator.Open"]
810
dev_langs: ["C++"]
9-
helpviewer_keywords: ["CEnumerator class"]
11+
helpviewer_keywords: ["CEnumerator class", "Find method", "GetMoniker method", "Open method"]
1012
ms.assetid: 25805f1b-26e3-402f-af83-1b5fe5ddebf7
1113
author: "mikeblome"
1214
ms.author: "mblome"
1315
ms.workload: ["cplusplus", "data-storage"]
1416
---
1517
# CEnumerator Class
16-
Uses an OLE DB enumerator object, which exposes the [ISourcesRowset](https://msdn.microsoft.com/en-us/library/ms715969.aspx) interface to return a rowset describing all data sources and enumerators.
18+
Uses an OLE DB enumerator object, which exposes the [ISourcesRowset](https://msdn.microsoft.com/library/ms715969.aspx) interface to return a rowset describing all data sources and enumerators.
1719

1820
## Syntax
1921

2022
```cpp
2123
class CEnumerator
2224
public CAccessorRowset< CAccessor <CEnumeratorAccessor >>
2325
```
26+
27+
## Requirements
28+
**Header:**atldbcli.h
2429
2530
## Members
2631
2732
### Methods
2833
2934
|||
3035
|-|-|
31-
|[Find](../../data/oledb/cenumerator-find.md)|Searches through available providers (data sources) looking for one with the specified name.|
32-
|[GetMoniker](../../data/oledb/cenumerator-getmoniker.md)|Retrieves the `IMoniker` interface for the current record.|
33-
|[Open](../../data/oledb/cenumerator-open.md)|Opens the enumerator.|
36+
|[Find](#find)|Searches through available providers (data sources) looking for one with the specified name.|
37+
|[GetMoniker](#getmoniker)|Retrieves the `IMoniker` interface for the current record.|
38+
|[Open](#open)|Opens the enumerator.|
3439
3540
## Remarks
36-
You can retrieve the **ISourcesRowset** data indirectly from this class.
41+
You can retrieve the `ISourcesRowset` data indirectly from this class.
42+
43+
## <a name="find"></a> CEnumerator::Find
44+
Looks for a specified name among available providers.
3745
38-
## Requirements
39-
**Header:**atldbcli.h
46+
### Syntax
47+
48+
```cpp
49+
bool Find(TCHAR* szSearchName) throw();
50+
```
51+
52+
#### Parameters
53+
*szSearchName*
54+
[in] The name to search for.
55+
56+
### Return Value
57+
**true** if the name was found. Otherwise, **false**.
58+
59+
### Remarks
60+
This name maps to the `SOURCES_NAME` member of the [ISourcesRowset](https://msdn.microsoft.com/library/ms715969.aspx) interface.
61+
62+
## <a name="getmoniker"></a> CEnumerator::GetMoniker
63+
Parses the display name to extract the component of the string that can be converted into a moniker.
64+
65+
### Syntax
66+
67+
```cpp
68+
HRESULT GetMoniker(LPMONIKER* ppMoniker) const throw();
69+
70+
71+
HRESULT GetMoniker(LPMONIKER* ppMoniker, 
72+
LPCTSTR lpszDisplayName) const throw();
73+
```
74+
75+
#### Parameters
76+
*ppMoniker*
77+
[out] The moniker parsed from the display name ([CEnumeratorAccessor::m_szParseName](../../data/oledb/cenumeratoraccessor-m-szparsename.md)) of the current row.
78+
79+
*lpszDisplayName*
80+
[in] The display name to parse.
81+
82+
### Return Value
83+
A standard HRESULT.
84+
85+
## <a name="open"></a> CEnumerator::Open
86+
Binds the moniker for the enumerator, if one is specified, then retrieves the rowset for the enumerator by calling [ISourcesRowset::GetSourcesRowset](https://msdn.microsoft.com/library/ms711200.aspx).
87+
88+
### Syntax
89+
90+
```cpp
91+
HRESULT Open(LPMONIKER pMoniker) throw();
92+
93+
94+
HRESULT Open(const CLSID* pClsid = & CLSID_OLEDB_ENUMERATOR) throw();
95+
96+
97+
HRESULT Open(const CEnumerator& enumerator) throw();
98+
```
99+
100+
#### Parameters
101+
*pMoniker*
102+
[in] A pointer to a moniker for an enumerator.
103+
104+
*pClsid*
105+
[in] A pointer to the `CLSID` of an enumerator.
106+
107+
*enumerator*
108+
[in] A reference to an enumerator.
109+
110+
### Return Value
111+
A standard HRESULT.
40112

41113
## See Also
42114
[DBViewer](../../visual-cpp-samples.md)

docs/data/oledb/cenumerator-find.md

-38
This file was deleted.

docs/data/oledb/cenumerator-getmoniker.md

-42
This file was deleted.

docs/data/oledb/cenumerator-open.md

-47
This file was deleted.

0 commit comments

Comments
 (0)