X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f41d6c8cd750a9ea532ce66350615829c95f6ff2..ae7e6cc946f85a9f12ab97f5860bf8d6235ec12a:/interface/wx/filename.h diff --git a/interface/wx/filename.h b/interface/wx/filename.h index 5280a24026..721c9c2f6c 100644 --- a/interface/wx/filename.h +++ b/interface/wx/filename.h @@ -53,10 +53,12 @@ wxULongLong wxInvalidSize; /** @class wxFileName - wxFileName encapsulates a file name. This class serves two purposes: first, it - provides the functions to split the file names into components and to recombine - these components in the full file name which can then be passed to the OS file - functions (and @ref overview_filefunctions "wxWidgets functions" wrapping them). + wxFileName encapsulates a file name. + + This class serves two purposes: first, it provides the functions to split the + file names into components and to recombine these components in the full file + name which can then be passed to the OS file functions + (and @ref group_funcmacro_file "wxWidgets functions" wrapping them). Second, it includes the functions for working with the files itself. Note that to change the file data you should use wxFile class instead. wxFileName provides functions for working with the file attributes. @@ -146,6 +148,7 @@ wxULongLong wxInvalidSize; @li wxFileName::AssignCwd() @li wxFileName::AssignDir() @li wxFileName::AssignHomeDir() + @li wxFileName::AssignTempFileName() @li wxFileName::DirName() @li wxFileName::FileName() @li wxFileName::operator=() @@ -335,11 +338,29 @@ public: /** The function calls CreateTempFileName() to create a temporary file and sets this object to the name of the file. + If a temporary file couldn't be created, the object is put into - an invalid state (see IsOk()) + an invalid state (see IsOk()). + */ + void AssignTempFileName(const wxString& prefix); + + /** + The function calls CreateTempFileName() to create a temporary + file name and open @a fileTemp with it. + + If the file couldn't be opened, the object is put into + an invalid state (see IsOk()). */ - void AssignTempFileName(const wxString& prefix, - wxFile* fileTemp = NULL); + void AssignTempFileName(const wxString& prefix, wxFile* fileTemp); + + /** + The function calls CreateTempFileName() to create a temporary + file name and open @a fileTemp with it. + + If the file couldn't be opened, the object is put into + an invalid state (see IsOk()). + */ + void AssignTempFileName(const wxString& prefix, wxFFile* fileTemp); /** Reset all components to default, uninitialized state. @@ -541,7 +562,7 @@ public: @see GetPathSeparators() */ - static wxChar GetPathSeparator(wxPathFormat format = wxPATH_NATIVE); + static wxUniChar GetPathSeparator(wxPathFormat format = wxPATH_NATIVE); /** Returns the string containing all the path separators for this format. @@ -580,7 +601,7 @@ public: not be read (because e.g. the file is locked by another process) the returned value is ::wxInvalidSize. */ - wxULongLong GetSize(); + wxULongLong GetSize() const; /** Returns the size of the file If the file does not exist or its size could @@ -812,7 +833,7 @@ public: In other words, it returns the file name which should be used to access this file if the current directory were pathBase. - @param pathBase. + @param pathBase The directory to use as root, current directory is used by default @param format The file name format, native by default @@ -831,7 +852,7 @@ public: @param perm The permissions for the newly created directory. - See wxPosixPermissions enumeration for more info. + See the ::wxPosixPermissions enumeration for more info. @param flags If the flags contain @c wxPATH_MKDIR_FULL flag, try to create each directory in the path and also don't return an error if the target @@ -847,9 +868,9 @@ public: @param dir The directory to create - @param parm + @param perm The permissions for the newly created directory. - See wxPosixPermissions enumeration for more info. + See the ::wxPosixPermissions enumeration for more info. @param flags If the flags contain @c wxPATH_MKDIR_FULL flag, try to create each directory in the path and also don't return an error if the target