Flutter Engine
file.h File Reference
#include <functional>
#include <initializer_list>
#include <string>
#include <vector>
#include "flutter/fml/macros.h"
#include "flutter/fml/unique_fd.h"

Go to the source code of this file.

Classes

class  fml::ScopedTemporaryDirectory
 

Namespaces

 fml
 

Typedefs

using fml::FileVisitor = std::function< bool(const fml::UniqueFD &directory, const std::string &filename)>
 

Enumerations

enum  fml::FilePermission {
  fml::FilePermission::kRead,
  fml::FilePermission::kWrite,
  fml::FilePermission::kReadWrite
}
 

Functions

std::string fml::CreateTemporaryDirectory ()
 
fml::UniqueFD fml::OpenFile (const char *path, bool create_if_necessary, FilePermission permission)
 This can open a directory on POSIX, but not on Windows. More...
 
fml::UniqueFD fml::OpenFile (const fml::UniqueFD &base_directory, const char *path, bool create_if_necessary, FilePermission permission)
 This can open a directory on POSIX, but not on Windows. More...
 
fml::UniqueFD fml::OpenFileReadOnly (const fml::UniqueFD &base_directory, const char *path)
 
fml::UniqueFD fml::OpenDirectory (const char *path, bool create_if_necessary, FilePermission permission)
 
fml::UniqueFD fml::OpenDirectory (const fml::UniqueFD &base_directory, const char *path, bool create_if_necessary, FilePermission permission)
 
fml::UniqueFD fml::OpenDirectoryReadOnly (const fml::UniqueFD &base_directory, const char *path)
 
fml::UniqueFD fml::Duplicate (fml::UniqueFD::element_type descriptor)
 
bool fml::IsDirectory (const fml::UniqueFD &directory)
 
bool fml::IsDirectory (const fml::UniqueFD &base_directory, const char *path)
 
bool fml::IsFile (const std::string &path)
 
bool fml::TruncateFile (const fml::UniqueFD &file, size_t size)
 
bool fml::FileExists (const fml::UniqueFD &base_directory, const char *path)
 
bool fml::UnlinkDirectory (const char *path)
 
bool fml::UnlinkDirectory (const fml::UniqueFD &base_directory, const char *path)
 
bool fml::UnlinkFile (const char *path)
 
bool fml::UnlinkFile (const fml::UniqueFD &base_directory, const char *path)
 
fml::UniqueFD fml::CreateDirectory (const fml::UniqueFD &base_directory, const std::vector< std::string > &components, FilePermission permission)
 
bool fml::WriteAtomically (const fml::UniqueFD &base_directory, const char *file_name, const Mapping &mapping)
 
bool fml::VisitFiles (const fml::UniqueFD &directory, const FileVisitor &visitor)
 
bool fml::VisitFilesRecursively (const fml::UniqueFD &directory, const FileVisitor &visitor)
 
bool fml::RemoveFilesInDirectory (const fml::UniqueFD &directory)
 
bool fml::RemoveDirectoryRecursively (const fml::UniqueFD &parent, const char *directory_name)