summaryrefslogtreecommitdiff
path: root/unotools
diff options
context:
space:
mode:
authorThomas Arnhold <thomas@arnhold.org>2011-07-13 13:26:54 +0200
committerThomas Arnhold <thomas@arnhold.org>2011-07-14 08:19:54 +0200
commitfd0d90b50233732abf15da59afe5fbf823e8341c (patch)
treed0f93e41398cc66a25fb275a57df4d0f8bd934da /unotools
parent36b7696fbc4339a94185b3a33c62f1f49df25129 (diff)
callcatcher: remove unused TempFile::SetTempNameBaseDirectory from unotools
Diffstat (limited to 'unotools')
-rw-r--r--unotools/inc/unotools/tempfile.hxx11
-rw-r--r--unotools/source/ucbhelper/tempfile.cxx41
2 files changed, 0 insertions, 52 deletions
diff --git a/unotools/inc/unotools/tempfile.hxx b/unotools/inc/unotools/tempfile.hxx
index 2030b1ab0791..b30f2eb4f7bd 100644
--- a/unotools/inc/unotools/tempfile.hxx
+++ b/unotools/inc/unotools/tempfile.hxx
@@ -143,17 +143,6 @@ public:
conversion functions of osl.
*/
static String CreateTempName( const String* pParent=NULL );
-
- /**
- The TempNameBaseDirectory is a subfolder in the folder that is passed as a "physical" file name in the
- SetTempNameBaseDirectory method.
- This subfolder will be used if a TempFile or TempName is created without a parent name or a parent name
- that does not belong to the local file system.
- The caller of the SetTempNameBase is responsible for deleting this folder and all temporary files in it.
- The return value of both methods is the complete "physical" name of the tempname base folder.
- It is not a URL because alle URLs must be "UCB compatible", so there may be no suitable URL at all.
- */
- static String SetTempNameBaseDirectory( const String &rBaseName );
};
}
diff --git a/unotools/source/ucbhelper/tempfile.cxx b/unotools/source/ucbhelper/tempfile.cxx
index 33a3ca6fb8f4..49d8bfaf4efd 100644
--- a/unotools/source/ucbhelper/tempfile.cxx
+++ b/unotools/source/ucbhelper/tempfile.cxx
@@ -443,47 +443,6 @@ void TempFile::CloseStream()
}
}
-String TempFile::SetTempNameBaseDirectory( const String &rBaseName )
-{
- if( !rBaseName.Len() )
- return String();
-
- rtl::OUString aUnqPath( rBaseName );
-
- // remove trailing slash
- if ( rBaseName.GetChar( rBaseName.Len() - 1 ) == sal_Unicode( '/' ) )
- aUnqPath = rBaseName.Copy( 0, rBaseName.Len() - 1 );
-
- // try to create the directory
- sal_Bool bRet = sal_False;
- osl::FileBase::RC err = osl::Directory::create( aUnqPath );
- if ( err != FileBase::E_None && err != FileBase::E_EXIST )
- // perhaps parent(s) don't exist
- bRet = ensuredir( aUnqPath );
- else
- bRet = sal_True;
-
- // failure to create base directory means returning an empty string
- rtl::OUString aTmp;
- if ( bRet )
- {
- // append own internal directory
- bRet = sal_True;
- ::rtl::OUString &rTempNameBase_Impl = TempNameBase_Impl::get();
- rTempNameBase_Impl = rBaseName;
- rTempNameBase_Impl += String( '/' );
-
- TempFile aBase( NULL, sal_True );
- if ( aBase.IsValid() )
- // use it in case of success
- rTempNameBase_Impl = aBase.pImp->aName;
-
- // return system path of used directory
- FileBase::getSystemPathFromFileURL( rTempNameBase_Impl, aTmp );
- }
-
- return aTmp;
-}
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */