tdf#130857 qt weld: Implement QtInstanceWidget::get_text_height
[LibreOffice.git] / connectivity / source / inc / file / FResultSetMetaData.hxx
blobdee656a915f43c614bde7138ac7b189b936364a5
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #pragma once
22 #include <com/sun/star/sdbc/XResultSetMetaData.hpp>
23 #include <cppuhelper/implbase.hxx>
24 #include <connectivity/CommonTools.hxx>
25 #include <rtl/ref.hxx>
27 namespace connectivity::file
29 class OFileTable;
31 //************ Class: ResultSetMetaData
33 typedef ::cppu::WeakImplHelper< css::sdbc::XResultSetMetaData> OResultSetMetaData_BASE;
35 class OResultSetMetaData :
36 public OResultSetMetaData_BASE
38 OUString m_aTableName;
39 ::rtl::Reference<connectivity::OSQLColumns> m_xColumns;
40 OFileTable* m_pTable;
42 /// @throws css::sdbc::SQLException
43 /// @throws css::uno::RuntimeException
44 void checkColumnIndex(sal_Int32 column);
45 protected:
46 virtual ~OResultSetMetaData() override;
47 public:
48 // a Constructor, that is needed for when Returning the Object is needed:
49 OResultSetMetaData(::rtl::Reference<connectivity::OSQLColumns> _xColumns, OUString _aTableName, OFileTable* _pTable);
51 virtual sal_Int32 SAL_CALL getColumnCount( ) override;
52 virtual sal_Bool SAL_CALL isAutoIncrement( sal_Int32 column ) override;
53 virtual sal_Bool SAL_CALL isCaseSensitive( sal_Int32 column ) override;
54 virtual sal_Bool SAL_CALL isSearchable( sal_Int32 column ) override;
55 virtual sal_Bool SAL_CALL isCurrency( sal_Int32 column ) override;
56 virtual sal_Int32 SAL_CALL isNullable( sal_Int32 column ) override;
57 virtual sal_Bool SAL_CALL isSigned( sal_Int32 column ) override;
58 virtual sal_Int32 SAL_CALL getColumnDisplaySize( sal_Int32 column ) override;
59 virtual OUString SAL_CALL getColumnLabel( sal_Int32 column ) override;
60 virtual OUString SAL_CALL getColumnName( sal_Int32 column ) override;
61 virtual OUString SAL_CALL getSchemaName( sal_Int32 column ) override;
62 virtual sal_Int32 SAL_CALL getPrecision( sal_Int32 column ) override;
63 virtual sal_Int32 SAL_CALL getScale( sal_Int32 column ) override;
64 virtual OUString SAL_CALL getTableName( sal_Int32 column ) override;
65 virtual OUString SAL_CALL getCatalogName( sal_Int32 column ) override;
66 virtual sal_Int32 SAL_CALL getColumnType( sal_Int32 column ) override;
67 virtual OUString SAL_CALL getColumnTypeName( sal_Int32 column ) override;
68 virtual sal_Bool SAL_CALL isReadOnly( sal_Int32 column ) override;
69 virtual sal_Bool SAL_CALL isWritable( sal_Int32 column ) override;
70 virtual sal_Bool SAL_CALL isDefinitelyWritable( sal_Int32 column ) override;
71 virtual OUString SAL_CALL getColumnServiceName( sal_Int32 column ) override;
77 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */