[Libreoffice-commits] core.git: include/sot sot/source
Noel Grandin
noel at peralex.com
Mon Jul 6 04:46:01 PDT 2015
include/sot/factory.hxx | 6 --
include/sot/object.hxx | 2
include/sot/stg.hxx | 24 ---------
include/sot/storage.hxx | 5 -
include/sot/storinfo.hxx | 1
sot/source/base/object.cxx | 4 -
sot/source/sdstor/stg.cxx | 104 ---------------------------------------
sot/source/sdstor/stgcache.hxx | 1
sot/source/sdstor/stgdir.hxx | 3 -
sot/source/sdstor/stgelem.hxx | 4 -
sot/source/sdstor/stgstrms.cxx | 19 -------
sot/source/sdstor/stgstrms.hxx | 7 --
sot/source/sdstor/storage.cxx | 10 ---
sot/source/sdstor/ucbstorage.cxx | 66 ------------------------
14 files changed, 2 insertions(+), 254 deletions(-)
New commits:
commit c4379aacbe9d5732dadf02c2d4306266e162ffc6
Author: Noel Grandin <noel at peralex.com>
Date: Fri Jul 3 15:24:09 2015 +0200
loplugin:unusedmethods sot
Change-Id: I14e8bb3e4e38ade1044ce1c50c9676a65152724c
Reviewed-on: https://gerrit.libreoffice.org/16733
Reviewed-by: Noel Grandin <noelgrandin at gmail.com>
Tested-by: Noel Grandin <noelgrandin at gmail.com>
diff --git a/include/sot/factory.hxx b/include/sot/factory.hxx
index b5f5ff6..7314e3a 100644
--- a/include/sot/factory.hxx
+++ b/include/sot/factory.hxx
@@ -59,12 +59,6 @@ public:
void PutSuperClass( const SotFactory * );
bool Is( const SotFactory * pSuperClass ) const;
- const SotFactory * GetSuper( sal_uInt16 nPos ) const
- {
- return nPos < nSuperCount ?
- pSuperClasses[ nPos ]
- : NULL;
- }
private:
SotFactory( const SotFactory & ) SAL_DELETED_FUNCTION;
diff --git a/include/sot/object.hxx b/include/sot/object.hxx
index 8c20856..41077fe 100644
--- a/include/sot/object.hxx
+++ b/include/sot/object.hxx
@@ -35,7 +35,6 @@ friend class SotFactory;
protected:
virtual ~SotObject();
- void SetExtern() { bOwner = false; }
virtual bool Close();
public:
SotObject();
@@ -46,7 +45,6 @@ private:
public:
static void * CreateInstance( SotObject ** = NULL );
static SotFactory * ClassFactory();
- virtual const SotFactory * GetSvFactory() const;
virtual void * Cast( const SotFactory * );
bool Owner() const { return bOwner; }
diff --git a/include/sot/stg.hxx b/include/sot/stg.hxx
index 5f4ba36..bfb5702 100644
--- a/include/sot/stg.hxx
+++ b/include/sot/stg.hxx
@@ -55,7 +55,6 @@ protected:
virtual ~StorageBase();
public:
TYPEINFO();
- virtual const SvStream* GetSvStream() const = 0;
virtual bool Validate( bool=false ) const = 0;
virtual bool ValidateMode( StreamMode ) const = 0;
void ResetError() const;
@@ -80,7 +79,6 @@ public:
virtual sal_uLong GetSize() const = 0;
virtual bool CopyTo( BaseStorageStream * pDestStm ) = 0;
virtual bool Commit() = 0;
- virtual bool Revert() = 0;
virtual bool Equals( const BaseStorageStream& rStream ) const = 0;
};
@@ -98,13 +96,9 @@ public:
virtual void SetClass( const SvGlobalName & rClass,
SotClipboardFormatId nOriginalClipFormat,
const OUString & rUserTypeName ) = 0;
- virtual void SetConvertClass( const SvGlobalName & rConvertClass,
- SotClipboardFormatId nOriginalClipFormat,
- const OUString & rUserTypeName ) = 0;
virtual SvGlobalName GetClassName() = 0;
virtual SotClipboardFormatId GetFormat() = 0;
virtual OUString GetUserName() = 0;
- virtual bool ShouldConvert() = 0;
virtual void FillInfoList( SvStorageInfoList* ) const = 0;
virtual bool CopyTo( BaseStorage* pDestStg ) const = 0;
virtual bool Commit() = 0;
@@ -127,7 +121,6 @@ public:
virtual bool Remove( const OUString & rEleName ) = 0;
virtual bool Rename( const OUString & rEleName, const OUString & rNewName ) = 0;
virtual bool CopyTo( const OUString & rEleName, BaseStorage * pDest, const OUString & rNewName ) = 0;
- virtual bool MoveTo( const OUString & rEleName, BaseStorage * pDest, const OUString & rNewName ) = 0;
virtual bool ValidateFAT() = 0;
virtual bool Equals( const BaseStorage& rStream ) const = 0;
};
@@ -164,10 +157,8 @@ public:
virtual sal_uLong GetSize() const SAL_OVERRIDE;
virtual bool CopyTo( BaseStorageStream * pDestStm ) SAL_OVERRIDE;
virtual bool Commit() SAL_OVERRIDE;
- virtual bool Revert() SAL_OVERRIDE;
virtual bool Validate( bool=false ) const SAL_OVERRIDE;
virtual bool ValidateMode( StreamMode ) const SAL_OVERRIDE;
- const SvStream* GetSvStream() const SAL_OVERRIDE;
virtual bool Equals( const BaseStorageStream& rStream ) const SAL_OVERRIDE;
};
@@ -198,13 +189,9 @@ public:
virtual void SetClass( const SvGlobalName & rClass,
SotClipboardFormatId nOriginalClipFormat,
const OUString & rUserTypeName ) SAL_OVERRIDE;
- virtual void SetConvertClass( const SvGlobalName & rConvertClass,
- SotClipboardFormatId nOriginalClipFormat,
- const OUString & rUserTypeName ) SAL_OVERRIDE;
virtual SvGlobalName GetClassName() SAL_OVERRIDE;
virtual SotClipboardFormatId GetFormat() SAL_OVERRIDE;
virtual OUString GetUserName() SAL_OVERRIDE;
- virtual bool ShouldConvert() SAL_OVERRIDE;
virtual void FillInfoList( SvStorageInfoList* ) const SAL_OVERRIDE;
virtual bool CopyTo( BaseStorage* pDestStg ) const SAL_OVERRIDE;
virtual bool Commit() SAL_OVERRIDE;
@@ -227,12 +214,10 @@ public:
virtual bool Remove( const OUString & rEleName ) SAL_OVERRIDE;
virtual bool Rename( const OUString & rEleName, const OUString & rNewName ) SAL_OVERRIDE;
virtual bool CopyTo( const OUString & rEleName, BaseStorage * pDest, const OUString & rNewName ) SAL_OVERRIDE;
- virtual bool MoveTo( const OUString & rEleName, BaseStorage * pDest, const OUString & rNewName ) SAL_OVERRIDE;
virtual bool ValidateFAT() SAL_OVERRIDE;
virtual bool Validate( bool=false ) const SAL_OVERRIDE;
virtual bool ValidateMode( StreamMode ) const SAL_OVERRIDE;
bool ValidateMode( StreamMode, StgDirEntry* p ) const;
- virtual const SvStream* GetSvStream() const SAL_OVERRIDE;
virtual bool Equals( const BaseStorage& rStream ) const SAL_OVERRIDE;
};
@@ -259,10 +244,8 @@ public:
virtual sal_uLong GetSize() const SAL_OVERRIDE;
virtual bool CopyTo( BaseStorageStream * pDestStm ) SAL_OVERRIDE;
virtual bool Commit() SAL_OVERRIDE;
- virtual bool Revert() SAL_OVERRIDE;
virtual bool Validate( bool=false ) const SAL_OVERRIDE;
virtual bool ValidateMode( StreamMode ) const SAL_OVERRIDE;
- const SvStream* GetSvStream() const SAL_OVERRIDE;
virtual bool Equals( const BaseStorageStream& rStream ) const SAL_OVERRIDE;
bool SetProperty( const OUString& rName, const ::com::sun::star::uno::Any& rValue );
@@ -312,13 +295,9 @@ public:
virtual void SetClass( const SvGlobalName & rClass,
SotClipboardFormatId nOriginalClipFormat,
const OUString & rUserTypeName ) SAL_OVERRIDE;
- virtual void SetConvertClass( const SvGlobalName & rConvertClass,
- SotClipboardFormatId nOriginalClipFormat,
- const OUString & rUserTypeName ) SAL_OVERRIDE;
virtual SvGlobalName GetClassName() SAL_OVERRIDE;
virtual SotClipboardFormatId GetFormat() SAL_OVERRIDE;
virtual OUString GetUserName() SAL_OVERRIDE;
- virtual bool ShouldConvert() SAL_OVERRIDE;
virtual void FillInfoList( SvStorageInfoList* ) const SAL_OVERRIDE;
virtual bool CopyTo( BaseStorage* pDestStg ) const SAL_OVERRIDE;
virtual bool Commit() SAL_OVERRIDE;
@@ -341,13 +320,10 @@ public:
virtual bool Remove( const OUString & rEleName ) SAL_OVERRIDE;
virtual bool Rename( const OUString & rEleName, const OUString & rNewName ) SAL_OVERRIDE;
virtual bool CopyTo( const OUString & rEleName, BaseStorage * pDest, const OUString & rNewName ) SAL_OVERRIDE;
- virtual bool MoveTo( const OUString & rEleName, BaseStorage * pDest, const OUString & rNewName ) SAL_OVERRIDE;
virtual bool ValidateFAT() SAL_OVERRIDE;
virtual bool Validate( bool=false ) const SAL_OVERRIDE;
virtual bool ValidateMode( StreamMode ) const SAL_OVERRIDE;
- virtual const SvStream* GetSvStream() const SAL_OVERRIDE;
virtual bool Equals( const BaseStorage& rStream ) const SAL_OVERRIDE;
- bool GetProperty( const OUString& rEleName, const OUString& rName, ::com::sun::star::uno::Any& rValue );
UCBStorageElement_Impl* FindElement_Impl( const OUString& rName ) const;
bool CopyStorageElement_Impl( UCBStorageElement_Impl& rElement,
diff --git a/include/sot/storage.hxx b/include/sot/storage.hxx
index 0850bde..8d0bcc8 100644
--- a/include/sot/storage.hxx
+++ b/include/sot/storage.hxx
@@ -62,7 +62,6 @@ private:
public:
static void * CreateInstance( SotObject ** = NULL );
static SotFactory * ClassFactory();
- virtual const SotFactory * GetSvFactory() const SAL_OVERRIDE;
virtual void * Cast( const SotFactory * ) SAL_OVERRIDE;
virtual void ResetError() SAL_OVERRIDE;
@@ -116,7 +115,6 @@ private:
public:
static void * CreateInstance( SotObject ** = NULL );
static SotFactory * ClassFactory();
- virtual const SotFactory * GetSvFactory() const SAL_OVERRIDE;
virtual void * Cast( const SotFactory * ) SAL_OVERRIDE;
SvMemoryStream * CreateMemoryStream();
@@ -139,7 +137,6 @@ public:
return m_nVersion;
}
- sal_uLong GetErrorCode() const { return m_nError; }
sal_uLong GetError() const { return ERRCODE_TOERROR(m_nError); }
void SetError( sal_uLong nErrorCode )
{
@@ -147,9 +144,7 @@ public:
m_nError = nErrorCode;
}
- bool IsRoot() const { return m_bIsRoot; }
void SignAsRoot( bool b = true ) { m_bIsRoot = b; }
- void SetDeleteStream( bool bDelete ) { m_bDelStm = bDelete; }
// own data sector
void SetClass( const SvGlobalName & rClass,
diff --git a/include/sot/storinfo.hxx b/include/sot/storinfo.hxx
index 1793a68..98e5360 100644
--- a/include/sot/storinfo.hxx
+++ b/include/sot/storinfo.hxx
@@ -46,7 +46,6 @@ public:
, bStorage( bIsStorage )
{}
- const SvGlobalName & GetClassName() const { return aClassName; }
const OUString & GetName() const { return aName; }
bool IsStream() const { return bStream; }
bool IsStorage() const { return bStorage; }
diff --git a/sot/source/base/object.cxx b/sot/source/base/object.cxx
index 013853d..aa80990 100644
--- a/sot/source/base/object.cxx
+++ b/sot/source/base/object.cxx
@@ -52,10 +52,6 @@ void * SotObject::CreateInstance( SotObject ** ppObj )
return p;
}
-const SotFactory * SotObject::GetSvFactory() const
-{
- return ClassFactory();
-}
void * SotObject::Cast( const SotFactory * pFact )
{
diff --git a/sot/source/sdstor/stg.cxx b/sot/source/sdstor/stg.cxx
index a3e2085..953da65 100644
--- a/sot/source/sdstor/stg.cxx
+++ b/sot/source/sdstor/stg.cxx
@@ -274,20 +274,6 @@ bool StorageStream::Commit()
}
}
-bool StorageStream::Revert()
-{
- bool bResult = false;
-
- if ( Validate() )
- {
- pEntry->Revert();
- pIo->MoveError( *this );
- bResult = Good();
- }
-
- return bResult;
-}
-
bool StorageStream::CopyTo( BaseStorageStream* pDest )
{
if( !Validate() || !pDest || !pDest->Validate( true ) || Equals( *pDest ) )
@@ -299,11 +285,6 @@ bool StorageStream::CopyTo( BaseStorageStream* pDest )
return Good() && pDest->Good();
}
-const SvStream* StorageStream::GetSvStream() const
-{
- return GetSvStream_Impl();
-}
-
bool StorageStream::Validate( bool bValidate ) const
{
bool bRet = Validate_Impl( bValidate );
@@ -810,59 +791,6 @@ bool Storage::CopyTo( BaseStorage* pDest ) const
return Good() && pDest->Good();
}
-// Move one element
-
-bool Storage::MoveTo( const OUString& rElem, BaseStorage* pODest, const OUString& rNew )
-{
- if( !Validate() || !pODest || !pODest->Validate( true ) || Equals( *pODest ) )
- {
- SetError( SVSTREAM_ACCESS_DENIED );
- return false;
- }
-
- StgDirEntry* pElem = pIo->pTOC->Find( *pEntry, rElem );
- if( pElem )
- {
- // Simplest case: both storages share the same file
- bool bRes;
- Storage *pOther = PTR_CAST( Storage, pODest );
- if( pOther && pIo == pOther->pIo && rElem == rNew )
- {
- Storage *p = static_cast<Storage*>(pODest);
- Storage *pDest = p;
- // both storages are conventional storages, use implementation dependent code
- if( !pElem->IsContained( pDest->pEntry ) )
- {
- // cyclic move
- SetError( SVSTREAM_ACCESS_DENIED );
- return false;
- }
- bRes = pIo->pTOC->Move( *pEntry, *pDest->pEntry, rNew );
- if( !bRes )
- {
- pIo->MoveError( *this );
- pDest->pIo->MoveError( *pDest );
- sal_uLong nErr = GetError();
- if( !nErr )
- nErr = pDest->GetError();
- SetError( nErr );
- pDest->SetError( nErr );
- }
- }
- else
- {
- bRes = CopyTo( rElem, pODest, rNew );
- if( bRes )
- bRes = Remove( rElem );
- }
- if( !bRes )
- SetError( pIo->GetError() );
- return bRes;
- }
- SetError( SVSTREAM_FILE_NOT_FOUND );
- return false;
-}
-
bool Storage::IsStorage( const OUString& rName ) const
{
if( Validate() )
@@ -959,21 +887,6 @@ void Storage::SetClass( const SvGlobalName & rClass,
SetError( SVSTREAM_ACCESS_DENIED );
}
-void Storage::SetConvertClass( const SvGlobalName & rConvertClass,
- SotClipboardFormatId nOriginalClipFormat,
- const OUString & rUserTypeName )
-{
- if( Validate( true ) )
- {
- SetClass( rConvertClass, nOriginalClipFormat, rUserTypeName );
- // plus the convert flag:
- StgOleStream aOle( *this, true );
- aOle.GetFlags() |= 4;
- if( !aOle.Store() )
- SetError( aOle.GetError() );
- }
-}
-
SvGlobalName Storage::GetClassName()
{
StgCompObjStream aCompObj( *this, false );
@@ -1005,18 +918,6 @@ OUString Storage::GetUserName()
return OUString();
}
-bool Storage::ShouldConvert()
-{
- StgOleStream aOle( *this, false );
- if( aOle.Load() )
- return ( aOle.GetFlags() & 4 ) != 0;
- else
- {
- pIo->ResetError();
- return false;
- }
-}
-
bool Storage::ValidateFAT()
{
Link<> aLink = StgIo::GetErrorLink();
@@ -1046,11 +947,6 @@ const ClsId& Storage::GetClassId() const
return aDummyId;
}
-const SvStream* Storage::GetSvStream() const
-{
- return GetSvStream_Impl();
-}
-
bool Storage::Validate( bool bValidate ) const
{
bool bRet = Validate_Impl( bValidate );
diff --git a/sot/source/sdstor/stgcache.hxx b/sot/source/sdstor/stgcache.hxx
index bef0c76..64c3d9e 100644
--- a/sot/source/sdstor/stgcache.hxx
+++ b/sot/source/sdstor/stgcache.hxx
@@ -74,7 +74,6 @@ public:
void SetStrm( UCBStorageStream* );
bool IsWritable() { return ( pStrm && pStrm->IsWritable() ); }
bool Good() { return nError == SVSTREAM_OK; }
- bool Bad() { return nError != SVSTREAM_OK; }
sal_uLong GetError() { return nError; }
void MoveError( StorageBase& );
void SetError( sal_uLong );
diff --git a/sot/source/sdstor/stgdir.hxx b/sot/source/sdstor/stgdir.hxx
index 3f762d9..c0924f1 100644
--- a/sot/source/sdstor/stgdir.hxx
+++ b/sot/source/sdstor/stgdir.hxx
@@ -74,7 +74,6 @@ public:
void SetDirty() { bDirty = true; }
bool IsDirty();
- void ClearDirty();
bool Commit();
bool Revert();
@@ -84,7 +83,6 @@ public:
sal_Int32 GetSize();
bool SetSize( sal_Int32 );
sal_Int32 Seek( sal_Int32 );
- sal_Int32 Tell() { return nPos; }
sal_Int32 Read( void*, sal_Int32 );
sal_Int32 Write( const void*, sal_Int32 );
void Copy( BaseStorageStream& );
@@ -105,7 +103,6 @@ public:
StgDirEntry* GetRoot() { return pRoot; }
StgDirEntry* Find( StgDirEntry&, const OUString& );
StgDirEntry* Create( StgDirEntry&, const OUString&, StgEntryType );
- bool Remove( StgDirEntry&, const OUString& );
bool Rename( StgDirEntry&, const OUString&, const OUString& );
bool Move( StgDirEntry&, StgDirEntry&, const OUString& );
};
diff --git a/sot/source/sdstor/stgelem.hxx b/sot/source/sdstor/stgelem.hxx
index 385ee9b..0a8bcc9 100644
--- a/sot/source/sdstor/stgelem.hxx
+++ b/sot/source/sdstor/stgelem.hxx
@@ -62,7 +62,6 @@ public:
bool Load( SvStream& );
bool Store( StgIo& );
bool Check(); // check the signature and version
- short GetByteOrder() const { return nByteOrder; }
sal_Int32 GetTOCStart() const { return nTOCstrm; }
void SetTOCStart( sal_Int32 n );
sal_Int32 GetDataFATStart() const { return nDataFAT; }
@@ -79,7 +78,6 @@ public:
sal_Int32 GetMasters() const { return nMaster; }
void SetMasters( sal_Int32 n );
static short GetFAT1Size() { return cFATPagesInHeader; }
- const ClsId& GetClassId() const { return aClsId; }
sal_Int32 GetFATPage( short ) const;
void SetFATPage( short, sal_Int32 );
};
@@ -136,8 +134,6 @@ public:
StgEntryType GetType() const { return (StgEntryType) cType; }
sal_Int32 GetStartPage() const { return nPage1; }
void SetType( StgEntryType t ) { cType = (sal_uInt8) t; }
- sal_uInt8 GetFlags() const { return cFlags; }
- void SetFlags( sal_uInt8 c ) { cFlags = c; }
sal_Int32 GetSize() const { return nSize; }
void SetSize( sal_Int32 n ) { nSize = n; }
const ClsId& GetClassId() const { return aClsId; }
diff --git a/sot/source/sdstor/stgstrms.cxx b/sot/source/sdstor/stgstrms.cxx
index e85e0c6..a530501 100644
--- a/sot/source/sdstor/stgstrms.cxx
+++ b/sot/source/sdstor/stgstrms.cxx
@@ -458,15 +458,6 @@ bool StgStrm::Pos2Page( sal_Int32 nBytePos )
return nPage >= 0;
}
-// Retrieve the physical page for a given byte offset.
-
-rtl::Reference< StgPage > StgStrm::GetPhysPage( sal_Int32 nBytePos, bool bForce )
-{
- if( !Pos2Page( nBytePos ) )
- return NULL;
- return rIo.Get( nPage, bForce );
-}
-
// Copy an entire stream. Both streams are allocated in the FAT.
// The target stream is this stream.
@@ -569,16 +560,6 @@ bool StgFATStrm::Pos2Page( sal_Int32 nBytePos )
return nPage >= 0;
}
-// Retrieve the physical page for a given byte offset.
-// Since Pos2Page() already has computed the physical offset,
-// use the byte offset directly.
-
-rtl::Reference< StgPage > StgFATStrm::GetPhysPage( sal_Int32 nBytePos, bool bForce )
-{
- OSL_ENSURE( nBytePos >= 0, "The value may not be negative!" );
- return rIo.Get( nBytePos / ( nPageSize >> 2 ), bForce );
-}
-
// Get the page number entry for the given page offset.
sal_Int32 StgFATStrm::GetPage( short nOff, bool bMake, sal_uInt16 *pnMasterAlloc )
diff --git a/sot/source/sdstor/stgstrms.hxx b/sot/source/sdstor/stgstrms.hxx
index 32dd1bd..ba51547 100644
--- a/sot/source/sdstor/stgstrms.hxx
+++ b/sot/source/sdstor/stgstrms.hxx
@@ -81,15 +81,13 @@ public:
sal_Int32 GetStart() const { return nStart; }
sal_Int32 GetSize() const { return nSize; }
sal_Int32 GetPage() const { return nPage; }
- short GetPageSize() const { return nPageSize; }
sal_Int32 GetPages() const { return ( nSize + nPageSize - 1 ) / nPageSize;}
- short GetOffset() const { return nOffset;}
- void SetEntry( StgDirEntry& );
+ short GetOffset() const { return nOffset;}
+ void SetEntry( StgDirEntry& );
virtual bool SetSize( sal_Int32 );
virtual bool Pos2Page( sal_Int32 nBytePos );
virtual sal_Int32 Read( void*, sal_Int32 ) { return 0; }
virtual sal_Int32 Write( const void*, sal_Int32 ) { return 0; }
- virtual rtl::Reference< StgPage > GetPhysPage( sal_Int32 nBytePos, bool bForce = false );
virtual bool IsSmallStrm() const { return false; }
};
@@ -106,7 +104,6 @@ public:
using StgStrm::GetPage;
sal_Int32 GetPage( short, bool, sal_uInt16 *pnMasterAlloc = 0);
virtual bool SetSize( sal_Int32 ) SAL_OVERRIDE;
- virtual rtl::Reference< StgPage > GetPhysPage( sal_Int32 nBytePos, bool bForce = false ) SAL_OVERRIDE;
};
// The stream has a size increment which normally is 1, but which can be
diff --git a/sot/source/sdstor/storage.cxx b/sot/source/sdstor/storage.cxx
index 30c80b7..60aa410 100644
--- a/sot/source/sdstor/storage.cxx
+++ b/sot/source/sdstor/storage.cxx
@@ -76,11 +76,6 @@ void * SotStorageStream::CreateInstance( SotObject ** ppObj )
return p;
}
-const SotFactory * SotStorageStream::GetSvFactory() const
-{
- return ClassFactory();
-}
-
void * SotStorageStream::Cast( const SotFactory * pFact )
{
void * pRet = NULL;
@@ -342,11 +337,6 @@ void * SotStorage::CreateInstance( SotObject ** ppObj )
return p;
}
-const SotFactory * SotStorage::GetSvFactory() const
-{
- return ClassFactory();
-}
-
void * SotStorage::Cast( const SotFactory * pFact )
{
void * pRet = NULL;
diff --git a/sot/source/sdstor/ucbstorage.cxx b/sot/source/sdstor/ucbstorage.cxx
index 47f659f..e2c84c0 100644
--- a/sot/source/sdstor/ucbstorage.cxx
+++ b/sot/source/sdstor/ucbstorage.cxx
@@ -1350,15 +1350,6 @@ bool UCBStorageStream::ValidateMode( StreamMode m ) const
return true;
}
-const SvStream* UCBStorageStream::GetSvStream() const
-{
- if( !pImp->Init() )
- return NULL;
-
- pImp->CopySourceToTemporary();
- return pImp->m_pStream; // should not live longer then pImp!!!
-}
-
SvStream* UCBStorageStream::GetModifySvStream()
{
return static_cast<SvStream*>(pImp);
@@ -1377,11 +1368,6 @@ bool UCBStorageStream::Commit()
return true;
}
-bool UCBStorageStream::Revert()
-{
- return pImp->Revert();
-}
-
bool UCBStorageStream::CopyTo( BaseStorageStream* pDestStm )
{
if( !pImp->Init() )
@@ -2466,17 +2452,6 @@ const ClsId& UCBStorage::GetClassId() const
return ( const ClsId& ) pImp->m_aClassId.GetCLSID();
}
-void UCBStorage::SetConvertClass( const SvGlobalName & /*rConvertClass*/, SotClipboardFormatId /*nOriginalClipFormat*/, const OUString & /*rUserTypeName*/ )
-{
- // ???
-}
-
-bool UCBStorage::ShouldConvert()
-{
- // ???
- return false;
-}
-
SvGlobalName UCBStorage::GetClassName()
{
return pImp->m_aClassId;
@@ -2994,40 +2969,6 @@ bool UCBStorage::Rename( const OUString& rEleName, const OUString& rNewName )
return pElement != NULL;
}
-bool UCBStorage::MoveTo( const OUString& rEleName, BaseStorage* pNewSt, const OUString& rNewName )
-{
- if( rEleName.isEmpty() || rNewName.isEmpty() )
- return false;
-
- if ( pNewSt == static_cast<BaseStorage*>(this) && !FindElement_Impl( rNewName ) )
- {
- return Rename( rEleName, rNewName );
- }
- else
- {
-/*
- if ( PTR_CAST( UCBStorage, pNewSt ) )
- {
- // because the element is moved, not copied, a special optimization is possible :
- // first copy the UCBStorageElement; flag old element as "Removed" and new as "Inserted",
- // clear original name/type of the new element
- // if moved element is open: copy content, but change absolute URL ( and those of all children of the element! ),
- // clear original name/type of new content, keep the old original stream/storage, but forget its working streams,
- // close original UCBContent and original stream, only the TempFile and its stream may remain unchanged, but now
- // belong to the new content
- // if original and editable stream are identical ( readonly element ), it has to be copied to the editable
- // stream of the destination object
- // Not implemented at the moment ( risky?! ), perhaps later
- }
-*/
- // MoveTo is done by first copying to the new destination and then removing the old element
- bool bRet = CopyTo( rEleName, pNewSt, rNewName );
- if ( bRet )
- bRet = Remove( rEleName );
- return bRet;
- }
-}
-
bool UCBStorage::ValidateFAT()
{
// ???
@@ -3054,13 +2995,6 @@ bool UCBStorage::ValidateMode( StreamMode m ) const
return true;
}
-const SvStream* UCBStorage::GetSvStream() const
-{
- // this would cause a complete download of the file
- // as it looks, this method is NOT used inside of SOT, only exported by class SotStorage - but for what ???
- return pImp->m_pSource;
-}
-
bool UCBStorage::Equals( const BaseStorage& rStorage ) const
{
// ???
More information about the Libreoffice-commits
mailing list