diff options
Diffstat (limited to 'connectivity/source/drivers/file/FResultSetMetaData.cxx')
-rw-r--r-- | connectivity/source/drivers/file/FResultSetMetaData.cxx | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/connectivity/source/drivers/file/FResultSetMetaData.cxx b/connectivity/source/drivers/file/FResultSetMetaData.cxx index d1c612d50e70..070cd4492bc1 100644 --- a/connectivity/source/drivers/file/FResultSetMetaData.cxx +++ b/connectivity/source/drivers/file/FResultSetMetaData.cxx @@ -49,44 +49,44 @@ OResultSetMetaData::~OResultSetMetaData() m_xColumns = nullptr; } -void OResultSetMetaData::checkColumnIndex(sal_Int32 column) throw(SQLException, RuntimeException) +void OResultSetMetaData::checkColumnIndex(sal_Int32 column) { if(column <= 0 || column > (sal_Int32)(sal_Int32)m_xColumns->get().size()) throwInvalidIndexException(*this); } -sal_Int32 SAL_CALL OResultSetMetaData::getColumnDisplaySize( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Int32 SAL_CALL OResultSetMetaData::getColumnDisplaySize( sal_Int32 column ) { return getPrecision(column); } -sal_Int32 SAL_CALL OResultSetMetaData::getColumnType( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Int32 SAL_CALL OResultSetMetaData::getColumnType( sal_Int32 column ) { checkColumnIndex(column); return getINT32((m_xColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_TYPE))); } -sal_Int32 SAL_CALL OResultSetMetaData::getColumnCount( ) throw(SQLException, RuntimeException, std::exception) +sal_Int32 SAL_CALL OResultSetMetaData::getColumnCount( ) { return (m_xColumns->get()).size(); } -sal_Bool SAL_CALL OResultSetMetaData::isCaseSensitive( sal_Int32 /*column*/ ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isCaseSensitive( sal_Int32 /*column*/ ) { return false; } -OUString SAL_CALL OResultSetMetaData::getSchemaName( sal_Int32 /*column*/ ) throw(SQLException, RuntimeException, std::exception) +OUString SAL_CALL OResultSetMetaData::getSchemaName( sal_Int32 /*column*/ ) { return OUString(); } -OUString SAL_CALL OResultSetMetaData::getColumnName( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +OUString SAL_CALL OResultSetMetaData::getColumnName( sal_Int32 column ) { checkColumnIndex(column); @@ -94,77 +94,77 @@ OUString SAL_CALL OResultSetMetaData::getColumnName( sal_Int32 column ) throw(SQ return aName.hasValue() ? getString(aName) : getString((m_xColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_NAME))); } -OUString SAL_CALL OResultSetMetaData::getTableName( sal_Int32 /*column*/ ) throw(SQLException, RuntimeException, std::exception) +OUString SAL_CALL OResultSetMetaData::getTableName( sal_Int32 /*column*/ ) { return m_aTableName; } -OUString SAL_CALL OResultSetMetaData::getCatalogName( sal_Int32 /*column*/ ) throw(SQLException, RuntimeException, std::exception) +OUString SAL_CALL OResultSetMetaData::getCatalogName( sal_Int32 /*column*/ ) { return OUString(); } -OUString SAL_CALL OResultSetMetaData::getColumnTypeName( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +OUString SAL_CALL OResultSetMetaData::getColumnTypeName( sal_Int32 column ) { checkColumnIndex(column); return getString((m_xColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_TYPENAME))); } -OUString SAL_CALL OResultSetMetaData::getColumnLabel( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +OUString SAL_CALL OResultSetMetaData::getColumnLabel( sal_Int32 column ) { return getColumnName(column); } -OUString SAL_CALL OResultSetMetaData::getColumnServiceName( sal_Int32 /*column*/ ) throw(SQLException, RuntimeException, std::exception) +OUString SAL_CALL OResultSetMetaData::getColumnServiceName( sal_Int32 /*column*/ ) { return OUString(); } -sal_Bool SAL_CALL OResultSetMetaData::isCurrency( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isCurrency( sal_Int32 column ) { checkColumnIndex(column); return getBOOL((m_xColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_ISCURRENCY))); } -sal_Bool SAL_CALL OResultSetMetaData::isAutoIncrement( sal_Int32 /*setCatalogcolumn*/ ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isAutoIncrement( sal_Int32 /*setCatalogcolumn*/ ) { return false; } -sal_Bool SAL_CALL OResultSetMetaData::isSigned( sal_Int32 /*column*/ ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isSigned( sal_Int32 /*column*/ ) { return true; } -sal_Int32 SAL_CALL OResultSetMetaData::getPrecision( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Int32 SAL_CALL OResultSetMetaData::getPrecision( sal_Int32 column ) { checkColumnIndex(column); return getINT32((m_xColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_PRECISION))); } -sal_Int32 SAL_CALL OResultSetMetaData::getScale( sal_Int32 column ) throw(css::sdbc::SQLException, css::uno::RuntimeException, std::exception) +sal_Int32 SAL_CALL OResultSetMetaData::getScale( sal_Int32 column ) { checkColumnIndex(column); return getINT32((m_xColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_SCALE))); } -sal_Int32 SAL_CALL OResultSetMetaData::isNullable( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Int32 SAL_CALL OResultSetMetaData::isNullable( sal_Int32 column ) { checkColumnIndex(column); return getINT32((m_xColumns->get())[column-1]->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_ISNULLABLE))); } -sal_Bool SAL_CALL OResultSetMetaData::isSearchable( sal_Int32 /*column*/ ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isSearchable( sal_Int32 /*column*/ ) { return true; } -sal_Bool SAL_CALL OResultSetMetaData::isReadOnly( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isReadOnly( sal_Int32 column ) { checkColumnIndex(column); return m_pTable->isReadOnly() || ( @@ -173,12 +173,12 @@ sal_Bool SAL_CALL OResultSetMetaData::isReadOnly( sal_Int32 column ) throw(SQLEx } -sal_Bool SAL_CALL OResultSetMetaData::isDefinitelyWritable( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isDefinitelyWritable( sal_Int32 column ) { return !isReadOnly(column); } -sal_Bool SAL_CALL OResultSetMetaData::isWritable( sal_Int32 column ) throw(SQLException, RuntimeException, std::exception) +sal_Bool SAL_CALL OResultSetMetaData::isWritable( sal_Int32 column ) { return !isReadOnly(column); } |