summaryrefslogtreecommitdiff
path: root/embeddedobj/source/commonembedding/persistence.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'embeddedobj/source/commonembedding/persistence.cxx')
-rw-r--r--embeddedobj/source/commonembedding/persistence.cxx52
1 files changed, 26 insertions, 26 deletions
diff --git a/embeddedobj/source/commonembedding/persistence.cxx b/embeddedobj/source/commonembedding/persistence.cxx
index aebfb813a256..4a057f85f085 100644
--- a/embeddedobj/source/commonembedding/persistence.cxx
+++ b/embeddedobj/source/commonembedding/persistence.cxx
@@ -911,12 +911,12 @@ void SAL_CALL OCommonEmbeddedObject::setPersistentEntry(
if ( !xStorage.is() )
throw lang::IllegalArgumentException( "No parent storage is provided!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ),
+ static_cast< ::cppu::OWeakObject* >(this),
1 );
if ( sEntName.isEmpty() )
throw lang::IllegalArgumentException( "Empty element name is provided!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ),
+ static_cast< ::cppu::OWeakObject* >(this),
2 );
// May be LOADED should be forbidden here ???
@@ -931,7 +931,7 @@ void SAL_CALL OCommonEmbeddedObject::setPersistentEntry(
throw embed::WrongStateException(
"Can't change persistent representation of activated object!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
@@ -955,7 +955,7 @@ void SAL_CALL OCommonEmbeddedObject::setPersistentEntry(
else
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
// for now support of this interface is required to allow breaking of links and converting them to normal embedded
@@ -1112,7 +1112,7 @@ void SAL_CALL OCommonEmbeddedObject::setPersistentEntry(
//}
else
throw lang::IllegalArgumentException( "Wrong connection mode is provided!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ),
+ static_cast< ::cppu::OWeakObject* >(this),
3 );
}
}
@@ -1136,13 +1136,13 @@ void SAL_CALL OCommonEmbeddedObject::storeToEntry( const uno::Reference< embed::
{
// the object is still not loaded
throw embed::WrongStateException( "Can't store object without persistence!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
// for now support of this interface is required to allow breaking of links and converting them to normal embedded
// objects, so the persist name must be handled correctly ( althowgh no real persist entry is used )
@@ -1268,13 +1268,13 @@ void SAL_CALL OCommonEmbeddedObject::storeAsEntry( const uno::Reference< embed::
{
// the object is still not loaded
throw embed::WrongStateException( "Can't store object without persistence!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
// for now support of this interface is required to allow breaking of links and converting them to normal embedded
// objects, so the persist name must be handled correctly ( althowgh no real persist entry is used )
@@ -1407,7 +1407,7 @@ void SAL_CALL OCommonEmbeddedObject::saveCompleted( sal_Bool bUseNew )
{
// the object is still not loaded
throw embed::WrongStateException( "Can't store object without persistence!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
// for now support of this interface is required to allow breaking of links and converting them to normal embedded
@@ -1486,7 +1486,7 @@ sal_Bool SAL_CALL OCommonEmbeddedObject::hasEntry()
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
if ( m_xObjectStorage.is() )
return sal_True;
@@ -1507,13 +1507,13 @@ OUString SAL_CALL OCommonEmbeddedObject::getEntryName()
{
// the object is still not loaded
throw embed::WrongStateException( "The object persistence is not initialized!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
return m_aEntryName;
}
@@ -1537,13 +1537,13 @@ void SAL_CALL OCommonEmbeddedObject::storeOwn()
{
// the object is still not loaded
throw embed::WrongStateException( "Can't store object without persistence!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
if ( m_bReadOnly )
throw io::IOException(); // TODO: access denied
@@ -1623,13 +1623,13 @@ sal_Bool SAL_CALL OCommonEmbeddedObject::isReadonly()
{
// the object is still not loaded
throw embed::WrongStateException( "The object persistence is not initialized!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
return m_bReadOnly;
}
@@ -1655,7 +1655,7 @@ void SAL_CALL OCommonEmbeddedObject::reload(
{
// the object is still not loaded
throw embed::WrongStateException( "The object persistence is not initialized!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_nObjectState != embed::EmbedStates::LOADED )
@@ -1663,13 +1663,13 @@ void SAL_CALL OCommonEmbeddedObject::reload(
// the object is still not loaded
throw embed::WrongStateException(
"The object must be in loaded state to be reloaded!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
if ( m_bIsLink )
{
@@ -1777,7 +1777,7 @@ void SAL_CALL OCommonEmbeddedObject::breakLink( const uno::Reference< embed::XSt
// it must be a linked initialized object
throw embed::WrongStateException(
"The object is not a valid linked object!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
else
{
@@ -1787,12 +1787,12 @@ void SAL_CALL OCommonEmbeddedObject::breakLink( const uno::Reference< embed::XSt
if ( !xStorage.is() )
throw lang::IllegalArgumentException( "No parent storage is provided!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ),
+ static_cast< ::cppu::OWeakObject* >(this),
1 );
if ( sEntName.isEmpty() )
throw lang::IllegalArgumentException( "Empty element name is provided!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ),
+ static_cast< ::cppu::OWeakObject* >(this),
2 );
if ( !m_bIsLink || m_nObjectState == -1 )
@@ -1800,13 +1800,13 @@ void SAL_CALL OCommonEmbeddedObject::breakLink( const uno::Reference< embed::XSt
// it must be a linked initialized object
throw embed::WrongStateException(
"The object is not a valid linked object!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
}
if ( m_bWaitSaveCompleted )
throw embed::WrongStateException(
"The object waits for saveCompleted() call!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
uno::Reference< container::XNameAccess > xNameAccess( xStorage, uno::UNO_QUERY );
if ( !xNameAccess.is() )
@@ -1878,7 +1878,7 @@ OUString SAL_CALL OCommonEmbeddedObject::getLinkURL()
if ( !m_bIsLink )
throw embed::WrongStateException(
"The object is not a link object!",
- uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
+ static_cast< ::cppu::OWeakObject* >(this) );
return m_aLinkURL;
}