Language

The Free and Open Productivity Suite
Released: Apache OpenOffice 4.1.11
 Overview   Namespace   Class   Index   Help 

Methods of Class FileBase


getCanonicalName
static RC getCanonicalName(
const ::rtl::OUString & strRequested,
::rtl::OUString & strValid );

virtual abstract const volatile template static inline C-linkage
NO NO NO NO NO YES YES NO

Description
Determines a valid unused canonical name for a requested name. Depending on file system and operation system
the illegal characters are replaced by valid ones. If a file or directory with the requested name
already exists a new name is generated following the common rules on the actual file system and
operating system.

Parameters
strRequested
Requested name of a file or directory.
strValid
On success receives a name which is unused and valid on the actual operating system and
file system.

Return
osl_File_E_None on success otherwise one of the following errorcodes:<p> 
osl_File_E_INVAL        the format of the parameters was not valid<br>

See Also
osl_getFileStatus

getAbsoluteFileURL
static RC getAbsoluteFileURL(
const ::rtl::OUString & strDirBase,
const ::rtl::OUString & strRelative,
::rtl::OUString & strAbsolute );

virtual abstract const volatile template static inline C-linkage
NO NO NO NO NO YES YES NO

Summary
Converts a file URL relative to a given file directory URL into an full qualified URL.

Parameters
strDirBase
Base directory URL to which the relative URL is related to.
 
strRelative[in]
URL of a file or directory relative to the base directory URL
 specified by <code>strDirBase</code>.
 
strAbsolute
On success it receives the full qualified URL of the
 requested relative URL.

 
Return
E_None on success otherwise one of the following errorcodes:<p>
 E_INVAL        the format of the parameters was not valid<br>
 E_NOMEM        not enough memory for allocating structures <br>
 E_NOTDIR        Not a directory<br>
 E_ACCES        Permission denied<br>
 E_NOENT        No such file or directory<br>
 E_NAMETOOLONG    File name too long<p>


 These errorcodes can (eventually) be returned:<p>
 E_OVERFLOW        Value too large for defined data type<p>
 E_FAULT        Bad address<br>
 E_INTR            function call was interrupted<br>
 E_LOOP            Too many symbolic links encountered<br>
 E_MULTIHOP        Multihop attempted<br>
 E_NOLINK        Link has been severed<p>

 
See Also
getStatus

getSystemPathFromFileURL
static RC getSystemPathFromFileURL(
const ::rtl::OUString & strFileURL,
::rtl::OUString & strSystemPath );

virtual abstract const volatile template static inline C-linkage
NO NO NO NO NO YES YES NO

Summary
Converts a file URL into a full qualified system path

Parameters
urlPath[in]
System dependent path of a file or a directory
     
strPath[out]
On success it receives the full qualified system path

     
Return
E_None on success otherwise one of the following errorcodes:<p>
     E_INVAL        the format of the parameters was not valid<br>

     
See Also
getFileURLFromSystemPath

getFileURLFromSystemPath
static RC getFileURLFromSystemPath(
const ::rtl::OUString & strSystemPath,
::rtl::OUString & strFileURL );

virtual abstract const volatile template static inline C-linkage
NO NO NO NO NO YES YES NO

Summary
Converts a full qualified system path into a file URL

Parameters
dir[in]
System dependent path of a file or a directory
     
strPath[out]
On success it receives the full qualified file URL

     
Return
E_None on success otherwise one of the following errorcodes:<p>
     E_INVAL        the format of the parameters was not valid<br>

     
See Also
getSystemPathFromFileURL

searchFileURL
static RC searchFileURL(
const ::rtl::OUString & strFileName,
const ::rtl::OUString & strSystemSearchPath,
::rtl::OUString & strFileURL );

virtual abstract const volatile template static inline C-linkage
NO NO NO NO NO YES YES NO

Summary
Searches a full qualified system path / file URL 

Parameters
filePath[in]
System dependent path / file URL or file or relative directory
     
searchPath[in]
Paths, in which a given file has to be searched. These paths are only for the search of a
     file or a relative path, otherwise it will be ignored. If it is set to NULL or while using the
     search path the search failed the function searches for a matching file in all system directories and in the directories
     listed in the PATH environment variable. Path list has to be in common system path list notation. F.e. on UNIX systems
     "/bin:/usr/bin" or on Windows "C:\BIN;C:\BATCH".
     
strPath[out]
On success it receives the full qualified file URL

     
Return
E_None on success otherwise one of the following errorcodes:<p>
     E_INVAL        the format of the parameters was not valid<br>
     E_NOTDIR        Not a directory<br>
     E_NOENT        No such file or directory not found<br>

     
See Also
getFileURLFromSystemPath
getAbsoluteFileURL

Top of Page

Apache Software Foundation

Copyright & License | Privacy | Contact Us | Donate | Thanks

Apache, OpenOffice, OpenOffice.org and the seagull logo are registered trademarks of The Apache Software Foundation. The Apache feather logo is a trademark of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.