Kaydet (Commit) 036a660a authored tarafından Julien Nabet's avatar Julien Nabet

Prefer cppu::UnoType<T>::get() to ::getCppuType((T*)0) part11

Change-Id: Ibe0a1006aba2b6cbd87c0bd6ca3acbf9ba7b0fbe
üst e1f0d790
......@@ -37,13 +37,13 @@ StillReadWriteInteraction::StillReadWriteInteraction(const css::uno::Reference<
aInterceptedRequest.Handle = HANDLE_INTERACTIVEIOEXCEPTION;
aInterceptedRequest.Request <<= css::ucb::InteractiveIOException();
aInterceptedRequest.Continuation = ::getCppuType(static_cast< css::uno::Reference< css::task::XInteractionAbort >* >(0));
aInterceptedRequest.Continuation = cppu::UnoType<css::task::XInteractionAbort>::get();
aInterceptedRequest.MatchExact = false;
lInterceptions.push_back(aInterceptedRequest);
aInterceptedRequest.Handle = HANDLE_UNSUPPORTEDDATASINKEXCEPTION;
aInterceptedRequest.Request <<= css::ucb::UnsupportedDataSinkException();
aInterceptedRequest.Continuation = ::getCppuType(static_cast< css::uno::Reference< css::task::XInteractionAbort >* >(0));
aInterceptedRequest.Continuation = cppu::UnoType<css::task::XInteractionAbort>::get();
aInterceptedRequest.MatchExact = false;
lInterceptions.push_back(aInterceptedRequest);
......@@ -108,7 +108,7 @@ ucbhelper::InterceptedInteraction::EInterceptionState StillReadWriteInteraction:
m_bHandledByMySelf = true;
css::uno::Reference< css::task::XInteractionContinuation > xAbort = ::ucbhelper::InterceptedInteraction::extractContinuation(
xRequest->getContinuations(),
::getCppuType(static_cast< css::uno::Reference< css::task::XInteractionAbort >* >(0)));
cppu::UnoType<css::task::XInteractionAbort>::get() );
if (!xAbort.is())
return ::ucbhelper::InterceptedInteraction::E_NO_CONTINUATION_FOUND;
xAbort->select();
......
......@@ -282,25 +282,25 @@ void Test::testGetTypeFavourUnsigned() {
::cppu::UnoType< bool >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< bool * >(0)) ==
::getCppuType(static_cast< bool * >(0)));
::cppu::UnoType<bool>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< sal_Bool * >(0)) ==
::cppu::UnoType< bool >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< sal_Bool * >(0)) ==
::getCppuType(static_cast< sal_Bool * >(0)));
::cppu::UnoType<sal_Bool>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_Int8 * >(0)) ==
::cppu::UnoType< ::sal_Int8 >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_Int8 * >(0)) ==
::getCppuType(static_cast< ::sal_Int8 * >(0)));
::cppu::UnoType<sal_Int8>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_Int16 * >(0)) ==
::cppu::UnoType< ::sal_Int16 >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_Int16 * >(0)) ==
::getCppuType(static_cast< ::sal_Int16 * >(0)));
::cppu::UnoType<sal_Int16>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(
static_cast< ::cppu::UnoUnsignedShortType * >(0)) ==
......@@ -316,19 +316,19 @@ void Test::testGetTypeFavourUnsigned() {
::cppu::UnoType< ::sal_Int32 >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_Int32 * >(0)) ==
::getCppuType(static_cast< ::sal_Int32 * >(0)));
::cppu::UnoType<sal_Int32>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_uInt32 * >(0)) ==
::cppu::UnoType< ::sal_uInt32 >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_uInt32 * >(0)) ==
::getCppuType(static_cast< ::sal_uInt32 * >(0)));
::cppu::UnoType<sal_uInt32>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_Int64 * >(0)) ==
::cppu::UnoType< ::sal_Int64 >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_Int64 * >(0)) ==
::getCppuType(static_cast< ::sal_Int64 * >(0)));
::cppu::UnoType<sal_Int64>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::sal_uInt64 * >(0)) ==
::cppu::UnoType< ::sal_uInt64 >::get());
......@@ -340,13 +340,13 @@ void Test::testGetTypeFavourUnsigned() {
::cppu::UnoType< float >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< float * >(0)) ==
::getCppuType(static_cast< float * >(0)));
::cppu::UnoType<float>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< double * >(0)) ==
::cppu::UnoType< double >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< double * >(0)) ==
::getCppuType(static_cast< double * >(0)));
::cppu::UnoType<double>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(
static_cast< ::cppu::UnoCharType * >(0)) ==
......@@ -362,7 +362,7 @@ void Test::testGetTypeFavourUnsigned() {
::cppu::UnoType< ::rtl::OUString >::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< ::rtl::OUString * >(0)) ==
::getCppuType(static_cast< ::rtl::OUString * >(0)));
::cppu::UnoType<rtl::OUString>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< css::uno::Type * >(0)) ==
::cppu::UnoType< css::uno::Type >::get());
......@@ -446,7 +446,7 @@ void Test::testGetTypeFavourUnsigned() {
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(
static_cast< css::lang::EventObject * >(0)) ==
::getCppuType(static_cast< css::lang::EventObject * >(0)));
::cppu::UnoType<css::lang::EventObject>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< DerivedStruct1 * >(0)) ==
::cppu::UnoType< css::lang::EventObject >::get());
......@@ -460,7 +460,7 @@ void Test::testGetTypeFavourUnsigned() {
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(
static_cast< css::beans::PropertyChangeEvent * >(0)) ==
::getCppuType(static_cast< css::beans::PropertyChangeEvent * >(0)));
::cppu::UnoType<css::beans::PropertyChangeEvent>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< DerivedStruct2 * >(0)) ==
::cppu::UnoType< css::beans::PropertyChangeEvent >::get());
......@@ -482,7 +482,7 @@ void Test::testGetTypeFavourUnsigned() {
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(
static_cast< css::uno::Exception * >(0)) ==
::getCppuType(static_cast< css::uno::Exception * >(0)));
::cppu::UnoType<css::uno::Exception>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< DerivedException1 * >(0)) ==
::cppu::UnoType< css::uno::Exception >::get());
......@@ -536,9 +536,7 @@ void Test::testGetTypeFavourUnsigned() {
::cppu::getTypeFavourUnsigned(
static_cast<
css::uno::Reference< css::uno::XComponentContext > * >(0)) ==
::getCppuType(
static_cast<
css::uno::Reference< css::uno::XComponentContext > * >(0)));
cppu::UnoType<css::uno::XComponentContext>::get());
CPPUNIT_ASSERT(
::cppu::getTypeFavourUnsigned(static_cast< DerivedInterface2 * >(0)) ==
::cppu::UnoType< css::uno::XComponentContext >::get());
......
......@@ -86,11 +86,11 @@ uno::Sequence< uno::Type > SAL_CALL SvxAccessibleTextPropertySet::getTypes() thr
{
// Create a static typecollection ...
static ::cppu::OTypeCollection aTypeCollection(
::getCppuType( static_cast< const uno::Reference< beans::XPropertySet >* > (0) ),
::getCppuType( static_cast< const uno::Reference< beans::XMultiPropertySet >* > (0) ),
::getCppuType( static_cast< const uno::Reference< beans::XPropertyState >* > (0) ),
::getCppuType( static_cast< const uno::Reference< lang::XServiceInfo >* > (0) ),
::getCppuType( static_cast< const uno::Reference< lang::XTypeProvider >* > (0) ) );
::cppu::UnoType<beans::XPropertySet>::get(),
::cppu::UnoType<beans::XMultiPropertySet>::get(),
::cppu::UnoType<beans::XPropertyState>::get(),
::cppu::UnoType<lang::XServiceInfo>::get(),
::cppu::UnoType<lang::XTypeProvider>::get() );
// ... and set his address to static pointer!
pTypeCollection = &aTypeCollection ;
......
......@@ -65,7 +65,7 @@ void SAL_CALL ConfigFlush::refresh()
// Further its not a good idea to hold the own lock
// if an outside object is called :-)
css::lang::EventObject aSource (static_cast< css::util::XRefreshable* >(this));
::cppu::OInterfaceContainerHelper* pContainer = m_lListener.getContainer(::getCppuType(static_cast< css::uno::Reference< css::util::XRefreshListener >* >(NULL)));
::cppu::OInterfaceContainerHelper* pContainer = m_lListener.getContainer(cppu::UnoType<css::util::XRefreshListener>::get());
if (pContainer)
{
::cppu::OInterfaceIteratorHelper pIterator(*pContainer);
......@@ -94,7 +94,7 @@ void SAL_CALL ConfigFlush::addRefreshListener(const css::uno::Reference< css::ut
{
// no locks necessary
// used helper lives if we live and is threadsafe by itself ...
m_lListener.addInterface(::getCppuType(static_cast< css::uno::Reference< css::util::XRefreshListener >* >(NULL)),
m_lListener.addInterface(cppu::UnoType<css::util::XRefreshListener>::get(),
xListener);
}
......@@ -104,7 +104,7 @@ void SAL_CALL ConfigFlush::removeRefreshListener(const css::uno::Reference< css:
{
// no locks necessary
// used helper lives if we live and is threadsafe by itself ...
m_lListener.removeInterface(::getCppuType(static_cast< css::uno::Reference< css::util::XRefreshListener >* >(NULL)),
m_lListener.removeInterface(cppu::UnoType<css::util::XRefreshListener>::get(),
xListener);
}
......
......@@ -87,7 +87,7 @@ OXMLControlProperty::OXMLControlProperty( ORptFilter& rImport
s_aTypeNameMap[GetXMLToken( XML_BOOLEAN)] = ::getBooleanCppuType();
s_aTypeNameMap[GetXMLToken( XML_FLOAT)] = ::cppu::UnoType<double>::get();
s_aTypeNameMap[GetXMLToken( XML_DOUBLE)] = ::cppu::UnoType<double>::get();
s_aTypeNameMap[GetXMLToken( XML_STRING)] = ::getCppuType( static_cast< OUString* >(NULL) );
s_aTypeNameMap[GetXMLToken( XML_STRING)] = ::cppu::UnoType<OUString>::get();
s_aTypeNameMap[GetXMLToken( XML_INT)] = ::cppu::UnoType<sal_Int32>::get();
s_aTypeNameMap[GetXMLToken( XML_SHORT)] = ::getCppuType( static_cast< sal_Int16* >(NULL) );
s_aTypeNameMap[GetXMLToken( XML_DATE)] = ::getCppuType( static_cast< com::sun::star::util::Date* >(NULL) );
......
......@@ -99,8 +99,8 @@ FileContentIdentifier::getTypes(
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast< uno::Reference< lang::XTypeProvider >* >( 0 ) ),
getCppuType( static_cast< uno::Reference< XContentIdentifier >* >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<XContentIdentifier>::get() );
pCollection = &collection;
}
}
......
......@@ -148,14 +148,12 @@ uno::Sequence< ucb::CommandInfo > FTPContent::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
),
ucb::CommandInfo(
OUString( "insert" ),
-1,
getCppuType(
static_cast< ucb::InsertCommandArgument * >( 0 ) )
cppu::UnoType<ucb::InsertCommandArgument>::get()
),
ucb::CommandInfo(
OUString( "delete" ),
......
......@@ -98,9 +98,9 @@ css::uno::Sequence< css::uno::Type > SAL_CALL FTPContentProvider::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast< css::uno::Reference< XTypeProvider >*>(0) ),
getCppuType( static_cast< css::uno::Reference< XServiceInfo>*> (0) ),
getCppuType( static_cast< css::uno::Reference< XContentProvider>*> (0) )
cppu::UnoType<XTypeProvider>::get(),
cppu::UnoType<XServiceInfo>::get(),
cppu::UnoType<XContentProvider>::get()
);
pCollection = &collection;
}
......
......@@ -535,8 +535,7 @@ uno::Sequence< ucb::CommandInfo > HierarchyContent::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
)
// New commands
......@@ -590,8 +589,7 @@ uno::Sequence< ucb::CommandInfo > HierarchyContent::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
),
ucb::CommandInfo(
OUString( "transfer" ),
......@@ -654,8 +652,7 @@ uno::Sequence< ucb::CommandInfo > HierarchyContent::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
)
// New commands
......@@ -699,8 +696,7 @@ uno::Sequence< ucb::CommandInfo > HierarchyContent::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
),
ucb::CommandInfo(
OUString( "transfer" ),
......
......@@ -363,14 +363,12 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
),
ucb::CommandInfo(
OUString( "transfer" ),
-1,
getCppuType(
static_cast< ucb::TransferInfo * >( 0 ) )
cppu::UnoType<ucb::TransferInfo>::get()
),
ucb::CommandInfo(
OUString( "createNewContent" ),
......@@ -442,14 +440,12 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
),
ucb::CommandInfo(
OUString( "transfer" ),
-1,
getCppuType(
static_cast< ucb::TransferInfo * >( 0 ) )
cppu::UnoType<ucb::TransferInfo>::get()
),
ucb::CommandInfo(
OUString( "createNewContent" ),
......@@ -521,8 +517,7 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
)
// New commands
......
......@@ -212,8 +212,7 @@ uno::Sequence< beans::Property > Content::getProperties(
beans::Property(
OUString( "Storage" ),
-1,
getCppuType( static_cast<
const uno::Reference< embed::XStorage > * >( 0 ) ),
cppu::UnoType<embed::XStorage>::get(),
beans::PropertyAttribute::BOUND
| beans::PropertyAttribute::READONLY
)
......@@ -279,8 +278,7 @@ uno::Sequence< beans::Property > Content::getProperties(
beans::Property(
OUString( "DocumentModel" ),
-1,
getCppuType( static_cast<
const uno::Reference< frame::XModel > * >( 0 ) ),
cppu::UnoType<frame::XModel>::get(),
beans::PropertyAttribute::BOUND
| beans::PropertyAttribute::READONLY
)
......@@ -410,8 +408,7 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
)
// New commands
......@@ -470,8 +467,7 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
)
// New commands
......@@ -531,8 +527,7 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
),
ucb::CommandInfo(
OUString( "transfer" ),
......@@ -592,8 +587,7 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
),
ucb::CommandInfo(
OUString( "transfer" ),
......@@ -655,8 +649,7 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType(
static_cast< ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<ucb::OpenCommandArgument2>::get()
)
// New commands
......
......@@ -563,14 +563,12 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "insert" ),
-1,
getCppuType( static_cast<
ucb::InsertCommandArgument * >( 0 ) ) );
cppu::UnoType<ucb::InsertCommandArgument>::get() );
aCmdInfo[ 6 ] =
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType( static_cast<
ucb::OpenCommandArgument2 * >( 0 ) ) );
cppu::UnoType<ucb::OpenCommandArgument2>::get() );
// New commands
......@@ -580,20 +578,17 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "post" ),
-1,
getCppuType( static_cast<
ucb::PostCommandArgument2 * >( 0 ) ) );
cppu::UnoType<ucb::PostCommandArgument2>::get() );
aCmdInfo[ 8 ] =
ucb::CommandInfo(
OUString( "addProperty" ),
-1,
getCppuType( static_cast<
ucb::PropertyCommandArgument * >( 0 ) ) );
cppu::UnoType<ucb::PropertyCommandArgument>::get() );
aCmdInfo[ 9 ] =
ucb::CommandInfo(
OUString( "removeProperty" ),
-1,
getCppuType( static_cast<
rtl::OUString * >( 0 ) ) );
cppu::UnoType<rtl::OUString>::get() );
bool bFolder = false;
......
......@@ -535,14 +535,12 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "insert" ),
-1,
getCppuType( static_cast<
ucb::InsertCommandArgument * >( 0 ) ) );
cppu::UnoType<ucb::InsertCommandArgument>::get() );
aCmdInfo[ 6 ] =
ucb::CommandInfo(
OUString( "open" ),
-1,
getCppuType( static_cast<
ucb::OpenCommandArgument2 * >( 0 ) ) );
cppu::UnoType<ucb::OpenCommandArgument2>::get() );
// New commands
......@@ -552,20 +550,17 @@ uno::Sequence< ucb::CommandInfo > Content::getCommands(
ucb::CommandInfo(
OUString( "post" ),
-1,
getCppuType( static_cast<
ucb::PostCommandArgument2 * >( 0 ) ) );
cppu::UnoType<ucb::PostCommandArgument2>::get() );
aCmdInfo[ 8 ] =
ucb::CommandInfo(
OUString( "addProperty" ),
-1,
getCppuType( static_cast<
ucb::PropertyCommandArgument * >( 0 ) ) );
cppu::UnoType<ucb::PropertyCommandArgument>::get() );
aCmdInfo[ 9 ] =
ucb::CommandInfo(
OUString( "removeProperty" ),
-1,
getCppuType( static_cast<
rtl::OUString * >( 0 ) ) );
cppu::UnoType<rtl::OUString>::get() );
sal_Bool bFolder = sal_False;
......
......@@ -162,10 +162,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionRequest::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference< task::XInteractionRequest > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<task::XInteractionRequest>::get() );
pCollection = &collection;
}
}
......@@ -304,10 +302,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionAbort::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference< task::XInteractionAbort > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<task::XInteractionAbort>::get() );
pCollection = &collection;
}
}
......@@ -396,10 +392,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionRetry::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference< task::XInteractionRetry > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<task::XInteractionRetry>::get() );
pCollection = &collection;
}
}
......@@ -488,10 +482,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionApprove::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference< task::XInteractionApprove > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<task::XInteractionApprove>::get() );
pCollection = &collection;
}
}
......@@ -580,10 +572,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionDisapprove::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference< task::XInteractionDisapprove > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<task::XInteractionDisapprove>::get() );
pCollection = &collection;
}
}
......@@ -674,11 +664,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionSupplyAuthentication::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference<
ucb::XInteractionSupplyAuthentication2 > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<ucb::XInteractionSupplyAuthentication2>::get() );
pCollection = &collection;
}
}
......@@ -928,10 +915,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionSupplyName::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference< ucb::XInteractionSupplyName > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<ucb::XInteractionSupplyName>::get() );
pCollection = &collection;
}
}
......@@ -1035,11 +1020,8 @@ uno::Sequence< uno::Type > SAL_CALL InteractionReplaceExistingData::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast<
uno::Reference< lang::XTypeProvider > * >( 0 ) ),
getCppuType( static_cast<
uno::Reference<
ucb::XInteractionReplaceExistingData > * >( 0 ) ) );
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<ucb::XInteractionReplaceExistingData>::get() );
pCollection = &collection;
}
}
......
......@@ -462,23 +462,23 @@ sal_Int32 SAL_CALL ResultSetMetaData::getColumnType( sal_Int32 column )
nType = DataType::BIT; // XRow::getBoolean
else if ( rType == cppu::UnoType<sal_Int32>::get() )
nType = DataType::INTEGER; // XRow::getInt
else if ( rType == getCppuType( static_cast< const sal_Int64 * >( 0 ) ) )
else if ( rType == cppu::UnoType<sal_Int64>::get() )
nType = DataType::BIGINT; // XRow::getLong
else if ( rType == getCppuType( static_cast< const sal_Int16 * >( 0 ) ) )
else if ( rType == cppu::UnoType<sal_Int16>::get() )
nType = DataType::SMALLINT; // XRow::getShort
else if ( rType == getCppuType( static_cast< const sal_Int8 * >( 0 ) ) )
else if ( rType == cppu::UnoType<sal_Int8>::get() )
nType = DataType::TINYINT; // XRow::getByte
else if ( rType == getCppuType( static_cast< const float * >( 0 ) ) )
else if ( rType == cppu::UnoType<float>::get() )
nType = DataType::REAL; // XRow::getFloat
else if ( rType == getCppuType( static_cast< const double * >( 0 ) ) )
else if ( rType == cppu::UnoType<double>::get() )
nType = DataType::DOUBLE; // XRow::getDouble
else if ( rType == getCppuType( static_cast< const Sequence< sal_Int8 > * >( 0 ) ) )
nType = DataType::VARBINARY;// XRow::getBytes
else if ( rType == getCppuType( static_cast< const Date * >( 0 ) ) )
else if ( rType == cppu::UnoType<Date>::get() )
nType = DataType::DATE; // XRow::getDate
else if ( rType == getCppuType( static_cast< const Time * >( 0 ) ) )
else if ( rType == cppu::UnoType<Time>::get() )
nType = DataType::TIME; // XRow::getTime
else if ( rType == getCppuType( static_cast< const DateTime * >( 0 ) ) )
else if ( rType == cppu::UnoType<DateTime>::get() )
nType = DataType::TIMESTAMP;// XRow::getTimestamp
else if ( rType == getCppuType( static_cast< Reference< XInputStream > * >( 0 ) ) )
nType = DataType::LONGVARBINARY; // XRow::getBinaryStream
......
......@@ -188,7 +188,7 @@ uno::Sequence< star::ucb::CommandInfo > Content::getCommands(
star::ucb::CommandInfo(
"open",
-1,
getCppuType( static_cast< star::ucb::OpenCommandArgument2 * >( 0 ) )
cppu::UnoType<star::ucb::OpenCommandArgument2>::get()
)
};
......
......@@ -105,11 +105,11 @@ css::uno::Sequence< css::uno::Type > SAL_CALL ContentProvider::getTypes()
if ( !pCollection )
{
static cppu::OTypeCollection collection(
getCppuType( static_cast< css::uno::Reference< lang::XTypeProvider > *>(0)),
getCppuType( static_cast< css::uno::Reference< lang::XServiceInfo > *>(0)),
getCppuType( static_cast< css::uno::Reference< ucb::XContentProvider > *>(0)),
getCppuType( static_cast< css::uno::Reference< lang::XComponent > *>(0)),
getCppuType( static_cast< css::uno::Reference< container::XContainerListener > *>(0))
cppu::UnoType<lang::XTypeProvider>::get(),
cppu::UnoType<lang::XServiceInfo>::get(),
cppu::UnoType<ucb::XContentProvider>::get(),
cppu::UnoType<lang::XComponent>::get(),
cppu::UnoType<container::XContainerListener>::get()
);
pCollection = &collection;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment