BitShares-Core  7.0.2
BitShares blockchain node software and command-line wallet software
file_mapping.hpp
Go to the documentation of this file.
1 #pragma once
2 #include <fc/fwd.hpp>
3 #include <cstdint>
4 #include <cstdlib>
5 
6 namespace boost {
7  namespace interprocess {
8  class file_mapping;
9  class mapped_region;
10  }
11 }
12 namespace fc {
13  enum mode_t {
17  };
18 
19  class file_mapping {
20  public:
21  file_mapping( const char* file, mode_t );
22  ~file_mapping();
23  private:
24  friend class mapped_region;
25  #ifdef _WIN64
27  #else
29  #endif
30  };
31 
32  class mapped_region {
33  public:
34  mapped_region( const file_mapping& fm, mode_t m, uint64_t start, size_t size );
35  mapped_region( const file_mapping& fm, mode_t m );
37  void flush();
38  void* get_address()const;
39  size_t get_size()const;
40  private:
42  };
43 }
fwd.hpp
fc::read_write
@ read_write
Definition: file_mapping.hpp:16
fc
Definition: api.hpp:15
fc::file_mapping::~file_mapping
~file_mapping()
Definition: file_mapping.cpp:13
fc::read_only
@ read_only
Definition: file_mapping.hpp:14
fc::file_mapping::file_mapping
file_mapping(const char *file, mode_t)
Definition: file_mapping.cpp:9
fc::mapped_region::mapped_region
mapped_region(const file_mapping &fm, mode_t m, uint64_t start, size_t size)
Definition: file_mapping.cpp:17
fc::mode_t
mode_t
Definition: file_mapping.hpp:13
fc::mapped_region::flush
void flush()
Definition: file_mapping.cpp:32
fc::mapped_region::~mapped_region
~mapped_region()
Definition: file_mapping.cpp:25
fc::mapped_region
Definition: file_mapping.hpp:32
fc::write_only
@ write_only
Definition: file_mapping.hpp:15
fc::mapped_region::get_size
size_t get_size() const
Definition: file_mapping.cpp:37
fc::file_mapping
Definition: file_mapping.hpp:19
fc::mapped_region::get_address
void * get_address() const
Definition: file_mapping.cpp:27
fc::fwd
Used to forward declare value types.
Definition: fwd.hpp:10