LibreOffice Module connectivity (master) 1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
dbtools::FormattedColumnValue Class Referencefinal

a class which helps retrieving and setting the value of a database column as formatted string. More...

#include <formattedcolumnvalue.hxx>

Public Member Functions

 FormattedColumnValue (const css::uno::Reference< css::uno::XComponentContext > &_rxContext, const css::uno::Reference< css::sdbc::XRowSet > &_rxRowSet, const css::uno::Reference< css::beans::XPropertySet > &_rxColumn)
 constructs an instance More...
 
 FormattedColumnValue (const css::uno::Reference< css::util::XNumberFormatter > &i_rNumberFormatter, const css::uno::Reference< css::beans::XPropertySet > &i_rColumn)
 constructs an instance More...
 
 ~FormattedColumnValue ()
 
sal_Int16 getKeyType () const
 
const css::uno::Reference< css::sdb::XColumn > & getColumn () const
 
bool setFormattedValue (const OUString &_rFormattedStringValue) const
 
OUString getFormattedValue () const
 

Private Member Functions

 FormattedColumnValue (const FormattedColumnValue &)=delete
 
FormattedColumnValueoperator= (const FormattedColumnValue &)=delete
 

Private Attributes

std::unique_ptr< FormattedColumnValue_Datam_pData
 

Detailed Description

a class which helps retrieving and setting the value of a database column as formatted string.

Definition at line 43 of file formattedcolumnvalue.hxx.

Constructor & Destructor Documentation

◆ FormattedColumnValue() [1/3]

dbtools::FormattedColumnValue::FormattedColumnValue ( const css::uno::Reference< css::uno::XComponentContext > &  _rxContext,
const css::uno::Reference< css::sdbc::XRowSet > &  _rxRowSet,
const css::uno::Reference< css::beans::XPropertySet > &  _rxColumn 
)

constructs an instance

The format key for the string value exchange is taken from the given column object. If it has a non-<NULL> property value FormatKey, this key is taken. Otherwise, a default format matching the column type is determined.

The locale of this fallback format is the current system locale.

The number formats supplier is determined from the given RowSet, by examining its ActiveConnection.

◆ FormattedColumnValue() [2/3]

dbtools::FormattedColumnValue::FormattedColumnValue ( const css::uno::Reference< css::util::XNumberFormatter > &  i_rNumberFormatter,
const css::uno::Reference< css::beans::XPropertySet > &  i_rColumn 
)

constructs an instance

The format key for the string value exchange is taken from the given column object. If it has a non-<NULL> property value FormatKey, this key is taken. Otherwise, a default format matching the column type is determined.

The locale of this fallback format is the current system locale.

References getColumn().

◆ ~FormattedColumnValue()

dbtools::FormattedColumnValue::~FormattedColumnValue ( )

Definition at line 221 of file formattedcolumnvalue.cxx.

References m_pData.

◆ FormattedColumnValue() [3/3]

dbtools::FormattedColumnValue::FormattedColumnValue ( const FormattedColumnValue )
privatedelete

Member Function Documentation

◆ getColumn()

const Reference< XColumn > & dbtools::FormattedColumnValue::getColumn ( ) const

Definition at line 232 of file formattedcolumnvalue.cxx.

References m_pData.

◆ getFormattedValue()

OUString dbtools::FormattedColumnValue::getFormattedValue ( ) const

◆ getKeyType()

sal_Int16 dbtools::FormattedColumnValue::getKeyType ( ) const

Definition at line 226 of file formattedcolumnvalue.cxx.

References m_pData.

◆ operator=()

FormattedColumnValue & dbtools::FormattedColumnValue::operator= ( const FormattedColumnValue )
privatedelete

◆ setFormattedValue()

bool dbtools::FormattedColumnValue::setFormattedValue ( const OUString &  _rFormattedStringValue) const

Member Data Documentation

◆ m_pData

std::unique_ptr< FormattedColumnValue_Data > dbtools::FormattedColumnValue::m_pData
private

The documentation for this class was generated from the following files: