Kill DECL_PROP1IMPL and related (odk part)
Change-Id: Id4cd66b6082ec53facc985af48fc92de58a4c066
This commit is contained in:
@@ -769,12 +769,18 @@ IPropertyArrayHelper* OResultSet::createArrayHelper( ) const
|
||||
Sequence< Property > aProps(6);
|
||||
Property* pProperties = aProps.getArray();
|
||||
sal_Int32 nPos = 0;
|
||||
DECL_PROP1IMPL(CURSORNAME, ::rtl::OUString) PropertyAttribute::READONLY);
|
||||
DECL_PROP0(FETCHDIRECTION, sal_Int32);
|
||||
DECL_PROP0(FETCHSIZE, sal_Int32);
|
||||
DECL_BOOL_PROP1IMPL(ISBOOKMARKABLE) PropertyAttribute::READONLY);
|
||||
DECL_PROP1IMPL(RESULTSETCONCURRENCY,sal_Int32) PropertyAttribute::READONLY);
|
||||
DECL_PROP1IMPL(RESULTSETTYPE, sal_Int32) PropertyAttribute::READONLY);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_CURSORNAME),
|
||||
PROPERTY_ID_CURSORNAME, ::cppu::UnoType<OUString>::get(), PropertyAttribute::READONLY);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_FETCHDIRECTION),
|
||||
PROPERTY_ID_FETCHDIRECTION, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_FETCHSIZE),
|
||||
PROPERTY_ID_FETCHSIZE, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_ISBOOKMARKABLE),
|
||||
PROPERTY_ID_ISBOOKMARKABLE, ::getBooleanCppuType(), PropertyAttribute::READONLY);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_RESULTSETCONCURRENCY),
|
||||
PROPERTY_ID_RESULTSETCONCURRENCY, ::cppu::UnoType<sal_Int32>::get(), PropertyAttribute::READONLY);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_RESULTSETTYPE),
|
||||
PROPERTY_ID_RESULTSETTYPE, ::cppu::UnoType<sal_Int32>::get(), PropertyAttribute::READONLY);
|
||||
|
||||
return new OPropertyArrayHelper(aProps);
|
||||
}
|
||||
|
@@ -268,16 +268,26 @@ void SAL_CALL OStatement_Base::clearWarnings( ) throw(SQLException, RuntimeExce
|
||||
Sequence< Property > aProps(10);
|
||||
Property* pProperties = aProps.getArray();
|
||||
sal_Int32 nPos = 0;
|
||||
DECL_PROP0(CURSORNAME, ::rtl::OUString);
|
||||
DECL_BOOL_PROP0(ESCAPEPROCESSING);
|
||||
DECL_PROP0(FETCHDIRECTION,sal_Int32);
|
||||
DECL_PROP0(FETCHSIZE, sal_Int32);
|
||||
DECL_PROP0(MAXFIELDSIZE,sal_Int32);
|
||||
DECL_PROP0(MAXROWS, sal_Int32);
|
||||
DECL_PROP0(QUERYTIMEOUT,sal_Int32);
|
||||
DECL_PROP0(RESULTSETCONCURRENCY,sal_Int32);
|
||||
DECL_PROP0(RESULTSETTYPE,sal_Int32);
|
||||
DECL_BOOL_PROP0(USEBOOKMARKS);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_CURSORNAME),
|
||||
PROPERTY_ID_CURSORNAME, ::cppu::UnoType<OUString>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_ESCAPEPROCESSING),
|
||||
PROPERTY_ID_ESCAPEPROCESSING, ::getBooleanCppuType(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_FETCHDIRECTION),
|
||||
PROPERTY_ID_FETCHDIRECTION, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_FETCHSIZE),
|
||||
PROPERTY_ID_FETCHSIZE, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_MAXFIELDSIZE),
|
||||
PROPERTY_ID_MAXFIELDSIZE, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_MAXROWS),
|
||||
PROPERTY_ID_MAXROWS, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_QUERYTIMEOUT),
|
||||
PROPERTY_ID_QUERYTIMEOUT, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_RESULTSETCONCURRENCY),
|
||||
PROPERTY_ID_RESULTSETCONCURRENCY, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_RESULTSETTYPE),
|
||||
PROPERTY_ID_RESULTSETTYPE, ::cppu::UnoType<sal_Int32>::get(), 0);
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_USEBOOKMARKS),
|
||||
PROPERTY_ID_USEBOOKMARKS, ::getBooleanCppuType(), 0);
|
||||
|
||||
return new ::cppu::OPropertyArrayHelper(aProps);
|
||||
}
|
||||
|
@@ -83,20 +83,6 @@ namespace skeleton
|
||||
}
|
||||
|
||||
|
||||
|
||||
#define DECL_PROP1IMPL(varname, type) \
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_##varname), PROPERTY_ID_##varname, ::cppu::UnoType< type >::get(),
|
||||
|
||||
#define DECL_PROP0(varname, type) \
|
||||
DECL_PROP1IMPL(varname, type) 0)
|
||||
|
||||
#define DECL_BOOL_PROP1IMPL(varname) \
|
||||
pProperties[nPos++] = ::com::sun::star::beans::Property(OPropertyMap::getPropMap().getNameByIndex(PROPERTY_ID_##varname), PROPERTY_ID_##varname, ::getBooleanCppuType(),
|
||||
|
||||
#define DECL_BOOL_PROP0(varname) \
|
||||
DECL_BOOL_PROP1IMPL(varname) 0)
|
||||
|
||||
|
||||
#define PROPERTY_ID_QUERYTIMEOUT 1
|
||||
#define PROPERTY_ID_MAXFIELDSIZE 2
|
||||
#define PROPERTY_ID_MAXROWS 3
|
||||
|
Reference in New Issue
Block a user