1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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 #include "FieldDescriptions.hxx"
21 #include <tools/debug.hxx>
22 #include <tools/diagnose_ex.h>
23 #include "dbu_tbl.hrc"
24 #include <com/sun/star/sdbc/ColumnValue.hpp>
25 #include "dbustrings.hrc"
26 #include <comphelper/types.hxx>
27 #include <comphelper/extract.hxx>
28 #include "UITools.hxx"
29 #include <com/sun/star/util/NumberFormat.hpp>
31 #define DEFAULT_VARCHAR_PRECISION 100
32 #define DEFAULT_OTHER_PRECISION 16
33 #define DEFAULT_NUMERIC_PRECISION 5
34 #define DEFAULT_NUMERIC_SCALE 0
36 using namespace dbaui
;
37 using namespace ::com::sun::star::sdbc
;
38 using namespace ::com::sun::star::uno
;
39 using namespace ::com::sun::star::beans
;
40 using namespace ::com::sun::star::util
;
42 // class OFieldDescription
43 OFieldDescription::OFieldDescription()
45 ,m_nType(DataType::VARCHAR
)
48 ,m_nIsNullable(ColumnValue::NULLABLE
)
50 ,m_eHorJustify(SVX_HOR_JUSTIFY_STANDARD
)
51 ,m_bIsAutoIncrement(false)
52 ,m_bIsPrimaryKey(false)
58 OFieldDescription::OFieldDescription( const OFieldDescription
& rDescr
)
59 :m_aDefaultValue(rDescr
.m_aDefaultValue
)
60 ,m_aControlDefault(rDescr
.m_aControlDefault
)
61 ,m_aWidth(rDescr
.m_aWidth
)
62 ,m_aRelativePosition(rDescr
.m_aRelativePosition
)
63 ,m_pType(rDescr
.m_pType
)
64 ,m_xDest(rDescr
.m_xDest
)
65 ,m_xDestInfo(rDescr
.m_xDestInfo
)
66 ,m_sName(rDescr
.m_sName
)
67 ,m_sTypeName(rDescr
.m_sTypeName
)
68 ,m_sDescription(rDescr
.m_sDescription
)
69 ,m_sAutoIncrementValue(rDescr
.m_sAutoIncrementValue
)
70 ,m_nType(rDescr
.m_nType
)
71 ,m_nPrecision(rDescr
.m_nPrecision
)
72 ,m_nScale(rDescr
.m_nScale
)
73 ,m_nIsNullable(rDescr
.m_nIsNullable
)
74 ,m_nFormatKey(rDescr
.m_nFormatKey
)
75 ,m_eHorJustify(rDescr
.m_eHorJustify
)
76 ,m_bIsAutoIncrement(rDescr
.m_bIsAutoIncrement
)
77 ,m_bIsPrimaryKey(rDescr
.m_bIsPrimaryKey
)
78 ,m_bIsCurrency(rDescr
.m_bIsCurrency
)
79 ,m_bHidden(rDescr
.m_bHidden
)
83 OFieldDescription::~OFieldDescription()
87 OFieldDescription::OFieldDescription(const Reference
< XPropertySet
>& xAffectedCol
,bool _bUseAsDest
)
89 ,m_nType(DataType::VARCHAR
)
92 ,m_nIsNullable(ColumnValue::NULLABLE
)
94 ,m_eHorJustify(SVX_HOR_JUSTIFY_STANDARD
)
95 ,m_bIsAutoIncrement(false)
96 ,m_bIsPrimaryKey(false)
100 OSL_ENSURE(xAffectedCol
.is(),"PropetySet can notbe null!");
101 if ( xAffectedCol
.is() )
105 m_xDest
= xAffectedCol
;
106 m_xDestInfo
= xAffectedCol
->getPropertySetInfo();
112 Reference
<XPropertySetInfo
> xPropSetInfo
= xAffectedCol
->getPropertySetInfo();
113 if(xPropSetInfo
->hasPropertyByName(PROPERTY_NAME
))
114 SetName(::comphelper::getString(xAffectedCol
->getPropertyValue(PROPERTY_NAME
)));
115 if(xPropSetInfo
->hasPropertyByName(PROPERTY_DESCRIPTION
))
116 SetDescription(::comphelper::getString(xAffectedCol
->getPropertyValue(PROPERTY_DESCRIPTION
)));
117 if(xPropSetInfo
->hasPropertyByName(PROPERTY_HELPTEXT
))
120 xAffectedCol
->getPropertyValue(PROPERTY_HELPTEXT
) >>= sHelpText
;
121 SetHelpText(sHelpText
);
123 if(xPropSetInfo
->hasPropertyByName(PROPERTY_DEFAULTVALUE
))
124 SetDefaultValue( xAffectedCol
->getPropertyValue(PROPERTY_DEFAULTVALUE
) );
126 if(xPropSetInfo
->hasPropertyByName(PROPERTY_CONTROLDEFAULT
))
127 SetControlDefault( xAffectedCol
->getPropertyValue(PROPERTY_CONTROLDEFAULT
) );
129 if(xPropSetInfo
->hasPropertyByName(PROPERTY_AUTOINCREMENTCREATION
))
130 SetAutoIncrementValue(::comphelper::getString(xAffectedCol
->getPropertyValue(PROPERTY_AUTOINCREMENTCREATION
)));
131 if(xPropSetInfo
->hasPropertyByName(PROPERTY_TYPE
))
132 SetTypeValue(::comphelper::getINT32(xAffectedCol
->getPropertyValue(PROPERTY_TYPE
)));
133 if (xPropSetInfo
->hasPropertyByName(PROPERTY_TYPENAME
))
134 SetTypeName(::comphelper::getString(xAffectedCol
->getPropertyValue(PROPERTY_TYPENAME
)));
135 if(xPropSetInfo
->hasPropertyByName(PROPERTY_PRECISION
))
136 SetPrecision(::comphelper::getINT32(xAffectedCol
->getPropertyValue(PROPERTY_PRECISION
)));
137 if(xPropSetInfo
->hasPropertyByName(PROPERTY_SCALE
))
138 SetScale(::comphelper::getINT32(xAffectedCol
->getPropertyValue(PROPERTY_SCALE
)));
139 if(xPropSetInfo
->hasPropertyByName(PROPERTY_ISNULLABLE
))
140 SetIsNullable(::comphelper::getINT32(xAffectedCol
->getPropertyValue(PROPERTY_ISNULLABLE
)));
141 if(xPropSetInfo
->hasPropertyByName(PROPERTY_FORMATKEY
))
143 const Any aValue
= xAffectedCol
->getPropertyValue(PROPERTY_FORMATKEY
);
144 if ( aValue
.hasValue() )
145 SetFormatKey(::comphelper::getINT32(aValue
));
147 if(xPropSetInfo
->hasPropertyByName(PROPERTY_RELATIVEPOSITION
))
148 m_aRelativePosition
= xAffectedCol
->getPropertyValue(PROPERTY_RELATIVEPOSITION
);
149 if(xPropSetInfo
->hasPropertyByName(PROPERTY_WIDTH
))
150 m_aWidth
= xAffectedCol
->getPropertyValue(PROPERTY_WIDTH
);
151 if(xPropSetInfo
->hasPropertyByName(PROPERTY_HIDDEN
))
152 xAffectedCol
->getPropertyValue(PROPERTY_HIDDEN
) >>= m_bHidden
;
153 if(xPropSetInfo
->hasPropertyByName(PROPERTY_ALIGN
))
155 const Any aValue
= xAffectedCol
->getPropertyValue(PROPERTY_ALIGN
);
156 if ( aValue
.hasValue() )
157 SetHorJustify( ::dbaui::mapTextJustify(::comphelper::getINT32(aValue
)));
159 if(xPropSetInfo
->hasPropertyByName(PROPERTY_ISAUTOINCREMENT
))
160 SetAutoIncrement(::cppu::any2bool(xAffectedCol
->getPropertyValue(PROPERTY_ISAUTOINCREMENT
)));
162 catch(const Exception
&)
164 DBG_UNHANDLED_EXCEPTION();
170 void OFieldDescription::FillFromTypeInfo(const TOTypeInfoSP
& _pType
,bool _bForce
,bool _bReset
)
172 TOTypeInfoSP pOldType
= getTypeInfo();
173 if ( _pType
!= pOldType
)
175 // reset type depending information
179 SetControlDefault(Any());
182 bool bForce
= _bForce
|| pOldType
.get() == NULL
|| pOldType
->nType
!= _pType
->nType
;
183 switch ( _pType
->nType
)
186 case DataType::VARCHAR
:
189 sal_Int32 nPrec
= DEFAULT_VARCHAR_PRECISION
;
190 if ( GetPrecision() )
191 nPrec
= GetPrecision();
192 SetPrecision(::std::min
<sal_Int32
>(nPrec
,_pType
->nPrecision
));
195 case DataType::TIMESTAMP
:
196 if ( bForce
&& _pType
->nMaximumScale
)
198 SetScale(::std::min
<sal_Int32
>(GetScale() ? GetScale() : DEFAULT_NUMERIC_SCALE
,_pType
->nMaximumScale
));
204 sal_Int32 nPrec
= DEFAULT_OTHER_PRECISION
;
205 switch ( _pType
->nType
)
210 nPrec
= _pType
->nPrecision
;
213 if ( GetPrecision() )
214 nPrec
= GetPrecision();
218 if ( _pType
->nPrecision
)
219 SetPrecision(::std::min
<sal_Int32
>(nPrec
? nPrec
: DEFAULT_NUMERIC_PRECISION
,_pType
->nPrecision
));
220 if ( _pType
->nMaximumScale
)
221 SetScale(::std::min
<sal_Int32
>(GetScale() ? GetScale() : DEFAULT_NUMERIC_SCALE
,_pType
->nMaximumScale
));
224 if ( _pType
->aCreateParams
.isEmpty() )
226 SetPrecision(_pType
->nPrecision
);
227 SetScale(_pType
->nMinimumScale
);
229 if ( !_pType
->bNullable
&& IsNullable() )
230 SetIsNullable(ColumnValue::NO_NULLS
);
231 if ( !_pType
->bAutoIncrement
&& IsAutoIncrement() )
232 SetAutoIncrement(false);
233 SetCurrency( _pType
->bCurrency
);
235 SetTypeName(_pType
->aTypeName
);
239 void OFieldDescription::SetName(const OUString
& _rName
)
243 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_NAME
) )
244 m_xDest
->setPropertyValue(PROPERTY_NAME
,makeAny(_rName
));
248 catch(const Exception
& )
250 DBG_UNHANDLED_EXCEPTION();
254 void OFieldDescription::SetHelpText(const OUString
& _sHelpText
)
258 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_HELPTEXT
) )
259 m_xDest
->setPropertyValue(PROPERTY_HELPTEXT
,makeAny(_sHelpText
));
261 m_sHelpText
= _sHelpText
;
263 catch(const Exception
& )
265 DBG_UNHANDLED_EXCEPTION();
269 void OFieldDescription::SetDescription(const OUString
& _rDescription
)
273 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_DESCRIPTION
) )
274 m_xDest
->setPropertyValue(PROPERTY_DESCRIPTION
,makeAny(_rDescription
));
276 m_sDescription
= _rDescription
;
278 catch(const Exception
& )
280 DBG_UNHANDLED_EXCEPTION();
284 void OFieldDescription::SetDefaultValue(const Any
& _rDefaultValue
)
288 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_DEFAULTVALUE
) )
289 m_xDest
->setPropertyValue(PROPERTY_DEFAULTVALUE
, _rDefaultValue
);
291 m_aDefaultValue
= _rDefaultValue
;
293 catch( const Exception
& )
295 DBG_UNHANDLED_EXCEPTION();
299 void OFieldDescription::SetControlDefault(const Any
& _rControlDefault
)
303 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_CONTROLDEFAULT
) )
304 m_xDest
->setPropertyValue(PROPERTY_CONTROLDEFAULT
, _rControlDefault
);
306 m_aControlDefault
= _rControlDefault
;
308 catch( const Exception
& )
310 DBG_UNHANDLED_EXCEPTION();
314 void OFieldDescription::SetAutoIncrementValue(const OUString
& _sAutoIncValue
)
318 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_AUTOINCREMENTCREATION
) )
319 m_xDest
->setPropertyValue(PROPERTY_AUTOINCREMENTCREATION
,makeAny(_sAutoIncValue
));
321 m_sAutoIncrementValue
= _sAutoIncValue
;
323 catch( const Exception
& )
325 DBG_UNHANDLED_EXCEPTION();
329 void OFieldDescription::SetType(TOTypeInfoSP _pType
)
336 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_TYPE
) )
337 m_xDest
->setPropertyValue(PROPERTY_TYPE
,makeAny(m_pType
->nType
));
339 m_nType
= m_pType
->nType
;
341 catch( const Exception
& )
343 DBG_UNHANDLED_EXCEPTION();
348 void OFieldDescription::SetTypeValue(sal_Int32 _nType
)
352 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_TYPE
) )
353 m_xDest
->setPropertyValue(PROPERTY_TYPE
,makeAny(_nType
));
357 OSL_ENSURE(!m_pType
.get(),"Invalid call here!");
360 catch( const Exception
& )
362 DBG_UNHANDLED_EXCEPTION();
366 void OFieldDescription::SetPrecision(const sal_Int32
& _rPrecision
)
370 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_PRECISION
) )
371 m_xDest
->setPropertyValue(PROPERTY_PRECISION
,makeAny(_rPrecision
));
373 m_nPrecision
= _rPrecision
;
375 catch( const Exception
& )
377 DBG_UNHANDLED_EXCEPTION();
381 void OFieldDescription::SetScale(const sal_Int32
& _rScale
)
385 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_SCALE
) )
386 m_xDest
->setPropertyValue(PROPERTY_SCALE
,makeAny(_rScale
));
390 catch( const Exception
& )
392 DBG_UNHANDLED_EXCEPTION();
396 void OFieldDescription::SetIsNullable(const sal_Int32
& _rIsNullable
)
400 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_ISNULLABLE
) )
401 m_xDest
->setPropertyValue(PROPERTY_ISNULLABLE
,makeAny(_rIsNullable
));
403 m_nIsNullable
= _rIsNullable
;
405 catch( const Exception
& )
407 DBG_UNHANDLED_EXCEPTION();
411 void OFieldDescription::SetFormatKey(const sal_Int32
& _rFormatKey
)
415 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_FORMATKEY
) )
416 m_xDest
->setPropertyValue(PROPERTY_FORMATKEY
,makeAny(_rFormatKey
));
418 m_nFormatKey
= _rFormatKey
;
420 catch( const Exception
& )
422 DBG_UNHANDLED_EXCEPTION();
426 void OFieldDescription::SetHorJustify(const SvxCellHorJustify
& _rHorJustify
)
430 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_ALIGN
) )
431 m_xDest
->setPropertyValue(PROPERTY_ALIGN
,makeAny( dbaui::mapTextAllign(_rHorJustify
)));
433 m_eHorJustify
= _rHorJustify
;
435 catch( const Exception
& )
437 DBG_UNHANDLED_EXCEPTION();
441 void OFieldDescription::SetAutoIncrement(bool _bAuto
)
445 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_ISAUTOINCREMENT
) )
446 m_xDest
->setPropertyValue(PROPERTY_ISAUTOINCREMENT
,makeAny(_bAuto
));
448 m_bIsAutoIncrement
= _bAuto
;
450 catch( const Exception
& )
452 DBG_UNHANDLED_EXCEPTION();
456 void OFieldDescription::SetPrimaryKey(bool _bPKey
)
458 m_bIsPrimaryKey
= _bPKey
;
460 SetIsNullable(::com::sun::star::sdbc::ColumnValue::NO_NULLS
);
463 void OFieldDescription::SetCurrency(bool _bIsCurrency
)
465 m_bIsCurrency
= _bIsCurrency
;
468 OUString
OFieldDescription::GetName() const
470 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_NAME
) )
471 return ::comphelper::getString(m_xDest
->getPropertyValue(PROPERTY_NAME
));
476 OUString
OFieldDescription::GetDescription() const
478 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_DESCRIPTION
) )
479 return ::comphelper::getString(m_xDest
->getPropertyValue(PROPERTY_DESCRIPTION
));
481 return m_sDescription
;
484 OUString
OFieldDescription::GetHelpText() const
486 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_HELPTEXT
) )
487 return ::comphelper::getString(m_xDest
->getPropertyValue(PROPERTY_HELPTEXT
));
492 ::com::sun::star::uno::Any
OFieldDescription::GetControlDefault() const
494 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_CONTROLDEFAULT
) )
495 return m_xDest
->getPropertyValue(PROPERTY_CONTROLDEFAULT
);
497 return m_aControlDefault
;
500 OUString
OFieldDescription::GetAutoIncrementValue() const
502 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_AUTOINCREMENTCREATION
) )
503 return ::comphelper::getString(m_xDest
->getPropertyValue(PROPERTY_AUTOINCREMENTCREATION
));
505 return m_sAutoIncrementValue
;
508 sal_Int32
OFieldDescription::GetType() const
510 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_TYPE
) )
511 return ::comphelper::getINT32(m_xDest
->getPropertyValue(PROPERTY_TYPE
));
513 return m_pType
.get() ? m_pType
->nType
: m_nType
;
516 OUString
OFieldDescription::GetTypeName() const
518 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_TYPENAME
) )
519 return ::comphelper::getString(m_xDest
->getPropertyValue(PROPERTY_TYPENAME
));
521 return m_pType
.get() ? m_pType
->aTypeName
: m_sTypeName
;
524 sal_Int32
OFieldDescription::GetPrecision() const
526 sal_Int32 nPrec
= m_nPrecision
;
527 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_PRECISION
) )
528 nPrec
= ::comphelper::getINT32(m_xDest
->getPropertyValue(PROPERTY_PRECISION
));
530 TOTypeInfoSP pTypeInfo
= getTypeInfo();
533 switch ( pTypeInfo
->nType
)
535 case DataType::TINYINT
:
536 case DataType::SMALLINT
:
537 case DataType::INTEGER
:
538 case DataType::BIGINT
:
540 nPrec
= pTypeInfo
->nPrecision
;
548 sal_Int32
OFieldDescription::GetScale() const
550 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_SCALE
) )
551 return ::comphelper::getINT32(m_xDest
->getPropertyValue(PROPERTY_SCALE
));
556 sal_Int32
OFieldDescription::GetIsNullable() const
558 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_ISNULLABLE
) )
559 return ::comphelper::getINT32(m_xDest
->getPropertyValue(PROPERTY_ISNULLABLE
));
561 return m_nIsNullable
;
564 sal_Int32
OFieldDescription::GetFormatKey() const
566 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_FORMATKEY
) )
567 return ::comphelper::getINT32(m_xDest
->getPropertyValue(PROPERTY_FORMATKEY
));
572 SvxCellHorJustify
OFieldDescription::GetHorJustify() const
574 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_ALIGN
) )
575 return ::dbaui::mapTextJustify(::comphelper::getINT32(m_xDest
->getPropertyValue(PROPERTY_ALIGN
)));
577 return m_eHorJustify
;
581 TOTypeInfoSP
OFieldDescription::getSpecialTypeInfo() const
583 TOTypeInfoSP
pSpecialType( new OTypeInfo() );
584 *pSpecialType
= *m_pType
;
585 pSpecialType
->nPrecision
= GetPrecision();
586 pSpecialType
->nMaximumScale
= static_cast<sal_Int16
>(GetScale());
587 pSpecialType
->bAutoIncrement
= IsAutoIncrement(); // http://dba.openoffice.org/issues/show_bug.cgi?id=115398 fixed by ludob
591 bool OFieldDescription::IsAutoIncrement() const
593 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_ISAUTOINCREMENT
) )
594 return ::cppu::any2bool(m_xDest
->getPropertyValue(PROPERTY_ISAUTOINCREMENT
));
596 return m_bIsAutoIncrement
;
601 bool OFieldDescription::IsNullable() const
603 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_ISNULLABLE
) )
604 return ::comphelper::getINT32(m_xDest
->getPropertyValue(PROPERTY_ISNULLABLE
)) == ::com::sun::star::sdbc::ColumnValue::NULLABLE
;
606 return m_nIsNullable
== ::com::sun::star::sdbc::ColumnValue::NULLABLE
;
609 void OFieldDescription::SetTypeName(const OUString
& _sTypeName
)
613 if ( m_xDest
.is() && m_xDestInfo
->hasPropertyByName(PROPERTY_TYPENAME
) )
614 m_xDest
->setPropertyValue(PROPERTY_TYPENAME
,makeAny(_sTypeName
));
616 m_sTypeName
= _sTypeName
;
618 catch( const Exception
& )
620 DBG_UNHANDLED_EXCEPTION();
624 void OFieldDescription::copyColumnSettingsTo(const Reference
< XPropertySet
>& _rxColumn
)
626 if ( _rxColumn
.is() )
628 Reference
<XPropertySetInfo
> xInfo
= _rxColumn
->getPropertySetInfo();
630 if ( GetFormatKey() != NumberFormat::ALL
&& xInfo
->hasPropertyByName(PROPERTY_FORMATKEY
) )
631 _rxColumn
->setPropertyValue(PROPERTY_FORMATKEY
,makeAny(GetFormatKey()));
632 if ( GetHorJustify() != SVX_HOR_JUSTIFY_STANDARD
&& xInfo
->hasPropertyByName(PROPERTY_ALIGN
) )
633 _rxColumn
->setPropertyValue(PROPERTY_ALIGN
,makeAny(dbaui::mapTextAllign(GetHorJustify())));
634 if ( !GetHelpText().isEmpty() && xInfo
->hasPropertyByName(PROPERTY_HELPTEXT
) )
635 _rxColumn
->setPropertyValue(PROPERTY_HELPTEXT
,makeAny(GetHelpText()));
636 if ( GetControlDefault().hasValue() && xInfo
->hasPropertyByName(PROPERTY_CONTROLDEFAULT
) )
637 _rxColumn
->setPropertyValue(PROPERTY_CONTROLDEFAULT
,GetControlDefault());
639 if(xInfo
->hasPropertyByName(PROPERTY_RELATIVEPOSITION
))
640 _rxColumn
->setPropertyValue(PROPERTY_RELATIVEPOSITION
,m_aRelativePosition
);
641 if(xInfo
->hasPropertyByName(PROPERTY_WIDTH
))
642 _rxColumn
->setPropertyValue(PROPERTY_WIDTH
,m_aWidth
);
643 if(xInfo
->hasPropertyByName(PROPERTY_HIDDEN
))
644 _rxColumn
->setPropertyValue(PROPERTY_HIDDEN
,makeAny(m_bHidden
));
648 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */