[v3 PATCH] include: Add IColumnsInfo interface

Alistair Leslie-Hughes leslie_alistair at hotmail.com
Fri Feb 12 04:51:43 CST 2016


Signed-off-by: Alistair Leslie-Hughes <leslie_alistair at hotmail.com>
---
 dlls/msdaps/usrmarshal.c | 30 +++++++++++++++++++++++++++++
 include/Makefile.in      |  1 +
 include/colinf.idl       | 49 ++++++++++++++++++++++++++++++++++++++++++++++++
 include/dbs.idl          | 28 +++++++++++++++++++++++++++
 include/oledb.idl        |  1 +
 5 files changed, 109 insertions(+)
 create mode 100644 include/colinf.idl

diff --git a/dlls/msdaps/usrmarshal.c b/dlls/msdaps/usrmarshal.c
index 1243e48..6ad29c9 100644
--- a/dlls/msdaps/usrmarshal.c
+++ b/dlls/msdaps/usrmarshal.c
@@ -1513,3 +1513,33 @@ HRESULT CALLBACK IChapteredRowset_ReleaseChapter_Proxy(IChapteredRowset* This, H
     FIXME("(%p)->(%lx %p): stub\n", This, chapter, refcount);
     return E_NOTIMPL;
 }
+
+HRESULT CALLBACK IColumnsInfo_GetColumnInfo_Proxy(IColumnsInfo* This, DBORDINAL *columns,
+        DBCOLUMNINFO **colinfo, OLECHAR **stringsbuffer)
+{
+    FIXME("(%p)->(%p %p %p): stub\n", This, columns, colinfo, stringsbuffer);
+    return E_NOTIMPL;
+}
+
+HRESULT __RPC_STUB IColumnsInfo_GetColumnInfo_Stub(IColumnsInfo* This, DBORDINAL *columns, DBCOLUMNINFO **col_info,
+    DBBYTEOFFSET **name_offsets, DBBYTEOFFSET **columnid_offsets, DBLENGTH *string_len, OLECHAR **stringsbuffer,
+    IErrorInfo **error)
+{
+    FIXME("(%p)->(%p %p %p %p %p %p %p): stub\n", This, columns, col_info, name_offsets, columnid_offsets,
+            string_len, stringsbuffer, error);
+    return E_NOTIMPL;
+}
+
+HRESULT CALLBACK IColumnsInfo_MapColumnIDs_Proxy(IColumnsInfo* This, DBORDINAL column_ids, const DBID *dbids,
+    DBORDINAL *columns)
+{
+    FIXME("(%p)->(%ld %p %p): stub\n", This, column_ids, dbids, columns);
+    return E_NOTIMPL;
+}
+
+HRESULT __RPC_STUB IColumnsInfo_MapColumnIDs_Stub(IColumnsInfo* This, DBORDINAL column_ids, const DBID *dbids,
+    DBORDINAL *columns, IErrorInfo **error)
+{
+    FIXME("(%p)->(%ld %p %p %p): stub\n", This, column_ids, dbids, columns, error);
+    return E_NOTIMPL;
+}
diff --git a/include/Makefile.in b/include/Makefile.in
index 129ff6d..010abe5 100644
--- a/include/Makefile.in
+++ b/include/Makefile.in
@@ -24,6 +24,7 @@ IDL_SRCS = \
 	chprst.idl \
 	cmdbas.idl \
 	cmdtxt.idl \
+	colinf.idl \
 	comcat.idl \
 	commoncontrols.idl \
 	control.idl \
diff --git a/include/colinf.idl b/include/colinf.idl
new file mode 100644
index 0000000..c31bf10
--- /dev/null
+++ b/include/colinf.idl
@@ -0,0 +1,49 @@
+/*
+ * Copyright (C) 2016 Alistair Leslie-Hughes
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#if 0
+#pragma makedep install
+#endif
+
+[
+    object,
+    uuid(0c733a11-2a1c-11ce-ade5-00aa0044773d),
+    pointer_default(unique)
+]
+interface IColumnsInfo : IUnknown
+{
+    [local]
+    HRESULT GetColumnInfo([in, out] DBORDINAL *columns, [out, size_is(*columns)] DBCOLUMNINFO **colinfo,
+        [out] OLECHAR **stringsbuffer);
+
+    [call_as(GetColumnInfo)]
+    HRESULT RemoteGetColumnInfo([in, out] DBORDINAL *columns,
+        [out, size_is((ULONG)*columns)] DBCOLUMNINFO **colinfo,
+        [out, size_is((ULONG)*columns)] DBBYTEOFFSET **name_offsets,
+        [out, size_is((ULONG)*columns)] DBBYTEOFFSET **columnid_offsets,
+        [in, out] DBLENGTH *string_len, [in, out, unique] OLECHAR **stringsbuffer,
+        [out] IErrorInfo **error);
+
+    [local]
+    HRESULT MapColumnIDs([in] DBORDINAL column_ids, [in,size_is(column_ids)] const DBID *dbids,
+        [out,size_is(column_ids)] DBORDINAL *columns);
+
+    [call_as(MapColumnIDs)]
+    HRESULT RemoteMapColumnIDs([in] DBORDINAL column_ids, [in,size_is((ULONG)column_ids)] const DBID *dbids,
+        [out,size_is((ULONG)column_ids)] DBORDINAL *columns, [out] IErrorInfo **error);
+}
diff --git a/include/dbs.idl b/include/dbs.idl
index 2c46c2b..00e16f9 100644
--- a/include/dbs.idl
+++ b/include/dbs.idl
@@ -733,3 +733,31 @@ enum DBREASONENUM15 {
     DBREASON_ROWPOSITION_CLEARED,
     DBREASON_ROW_ASYNCHINSERT
 };
+
+typedef DWORD DBCOLUMNFLAGS;
+
+enum DBCOLUMNFLAGSENUM {
+    DBCOLUMNFLAGS_ISBOOKMARK    = 0x0001,
+    DBCOLUMNFLAGS_MAYDEFER      = 0x0002,
+    DBCOLUMNFLAGS_WRITE         = 0x0004,
+    DBCOLUMNFLAGS_WRITEUNKNOWN  = 0x0008,
+    DBCOLUMNFLAGS_ISFIXEDLENGTH = 0x0010,
+    DBCOLUMNFLAGS_ISNULLABLE    = 0x0020,
+    DBCOLUMNFLAGS_MAYBENULL     = 0x0040,
+    DBCOLUMNFLAGS_ISLONG        = 0x0080,
+    DBCOLUMNFLAGS_ISROWID       = 0x0100,
+    DBCOLUMNFLAGS_ISROWVER      = 0x0200,
+    DBCOLUMNFLAGS_CACHEDEFERRED = 0x1000
+};
+
+typedef struct tagDBCOLUMNINFO {
+    LPOLESTR      pwszName;
+    ITypeInfo    *pTypeInfo;
+    DBORDINAL     iOrdinal;
+    DBCOLUMNFLAGS dwFlags;
+    DBLENGTH      ulColumnSize;
+    DBTYPE        wType;
+    BYTE          bPrecision;
+    BYTE          bScale;
+    DBID          columnid;
+} DBCOLUMNINFO;
diff --git a/include/oledb.idl b/include/oledb.idl
index 8d7f001..537bb21 100644
--- a/include/oledb.idl
+++ b/include/oledb.idl
@@ -50,6 +50,7 @@ typedef DWORD_PTR DBHASHVALUE;
 #include "chprst.idl"
 #include "cmdbas.idl"
 #include "cmdtxt.idl"
+#include "colinf.idl"
 #include "dbccmd.idl"
 #include "dbcses.idl"
 #include "srcrst.idl"
-- 
1.9.1




More information about the wine-patches mailing list