MySQL 8.4.2
Source Code Documentation
stdx::io::file_handle Class Reference

#include <file_handle.h>

Public Types

using path_type = filesystem::path
 
using path_view_type = filesystem::path
 
using native_handle_type = int
 
using dev_t = ::dev_t
 
using ino_t = ::ino_t
 

Public Member Functions

 file_handle (native_handle_type h, dev_t devid, ino_t inode, caching caching=caching::none, flag flags=flag::none) noexcept
 
 file_handle (const file_handle &)=delete
 
file_handleoperator= (const file_handle &)=delete
 
 file_handle (file_handle &&rhs)
 
 ~file_handle ()
 
stdx::expected< void, std::error_code > unlink ()
 
stdx::expected< void, std::error_code > close () noexcept
 
stdx::expected< size_t, std::error_code > write (const char *data, const size_t len)
 
native_handle_type release () noexcept
 
caching kernel_caching () const noexcept
 
flag flags () const noexcept
 
native_handle_type native_handle () const noexcept
 
dev_t st_dev () const noexcept
 
ino_t st_ino () const noexcept
 
stdx::expected< path_type, std::error_code > current_path () const noexcept
 

Static Public Member Functions

static stdx::expected< file_handle, std::error_code > file (const path_handle &base, file_handle::path_view_type path, mode _mode=mode::read, creation _creation=creation::open_existing, caching _caching=caching::all, flag flags=flag::none) noexcept
 
static stdx::expected< file_handle, std::error_code > uniquely_named_file (const path_handle &base, mode _mode=mode::write, caching _caching=caching::temporary, flag flags=flag::none) noexcept
 

Static Public Attributes

static constexpr const native_handle_type invalid_handle {-1}
 

Private Attributes

native_handle_type handle_ {invalid_handle}
 
dev_t devid_
 
ino_t inode_
 
caching caching_
 
flag flags_
 

Member Typedef Documentation

◆ dev_t

◆ ino_t

◆ native_handle_type

◆ path_type

◆ path_view_type

Constructor & Destructor Documentation

◆ file_handle() [1/3]

stdx::io::file_handle::file_handle ( native_handle_type  h,
dev_t  devid,
ino_t  inode,
caching  caching = caching::none,
flag  flags = flag::none 
)
inlinenoexcept

◆ file_handle() [2/3]

stdx::io::file_handle::file_handle ( const file_handle )
delete

◆ file_handle() [3/3]

stdx::io::file_handle::file_handle ( file_handle &&  rhs)
inline

◆ ~file_handle()

stdx::io::file_handle::~file_handle ( )
inline

Member Function Documentation

◆ close()

stdx::expected< void, std::error_code > stdx::io::file_handle::close ( )
noexcept

◆ current_path()

stdx::expected< file_handle::path_type, std::error_code > stdx::io::file_handle::current_path ( ) const
noexcept

◆ file()

stdx::expected< file_handle, std::error_code > stdx::io::file_handle::file ( const path_handle base,
file_handle::path_view_type  path,
mode  _mode = mode::read,
creation  _creation = creation::open_existing,
caching  _caching = caching::all,
flag  flags = flag::none 
)
staticnoexcept

◆ flags()

flag stdx::io::file_handle::flags ( ) const
inlinenoexcept

◆ kernel_caching()

caching stdx::io::file_handle::kernel_caching ( ) const
inlinenoexcept

◆ native_handle()

native_handle_type stdx::io::file_handle::native_handle ( ) const
inlinenoexcept

◆ operator=()

file_handle & stdx::io::file_handle::operator= ( const file_handle )
delete

◆ release()

native_handle_type stdx::io::file_handle::release ( )
inlinenoexcept

◆ st_dev()

dev_t stdx::io::file_handle::st_dev ( ) const
inlinenoexcept

◆ st_ino()

ino_t stdx::io::file_handle::st_ino ( ) const
inlinenoexcept

◆ uniquely_named_file()

stdx::expected< file_handle, std::error_code > stdx::io::file_handle::uniquely_named_file ( const path_handle base,
mode  _mode = mode::write,
caching  _caching = caching::temporary,
flag  flags = flag::none 
)
staticnoexcept

◆ unlink()

stdx::expected< void, std::error_code > stdx::io::file_handle::unlink ( )

◆ write()

stdx::expected< std::size_t, std::error_code > stdx::io::file_handle::write ( const char *  data,
const size_t  len 
)

Member Data Documentation

◆ caching_

caching stdx::io::file_handle::caching_
private

◆ devid_

dev_t stdx::io::file_handle::devid_
private

◆ flags_

flag stdx::io::file_handle::flags_
private

◆ handle_

native_handle_type stdx::io::file_handle::handle_ {invalid_handle}
private

◆ inode_

ino_t stdx::io::file_handle::inode_
private

◆ invalid_handle

constexpr const native_handle_type stdx::io::file_handle::invalid_handle {-1}
staticconstexpr

The documentation for this class was generated from the following files: