Joedb 9.1.4
The Journal-Only Embedded Database
Loading...
Searching...
No Matches
File_Client.h
Go to the documentation of this file.
1/////////////////////////////////////////////////////////////////////////////
2//
3// This code was automatically generated by the joedb compiler
4// https://www.joedb.org/
5//
6// Path to compiler: /home/rcoulom/repos/joedb/doc/source/tutorial/build/joedbc
7// Version: 9.1.4
8// joedbc compilation time: Apr 19 2025 18:13:35
9// Generation of this file: 2025-04-19 16:13:37 GMT
10//
11/////////////////////////////////////////////////////////////////////////////
12#ifndef settings_File_Client_declared
13#define settings_File_Client_declared
14
15#include "Client.h"
16#include "joedb/journal/File.h"
17
18namespace settings
19{
20 namespace detail
21 {
22 ///////////////////////////////////////////////////////////////////////////
23 class File_Client_Data
24 ///////////////////////////////////////////////////////////////////////////
25 {
26 protected:
27 joedb::File file;
28 joedb::Connection connection;
29
30 File_Client_Data(const char *file_name):
32 {
33 }
34 };
35 }
36
37 /// Shortcut to directly build a @ref Client from a file name
38 class File_Client: private detail::File_Client_Data, public Client
39 {
40 public:
41 File_Client(const char *file_name):
42 detail::File_Client_Data(file_name),
43 Client(File_Client_Data::file, File_Client_Data::connection)
44 {
45 }
46
47 File_Client(const std::string &file_name):
48 File_Client(file_name.c_str())
49 {
50 }
51 };
52}
53
54#endif
Handle concurrent access to a joedb::Buffered_File using a joedb::Connection.
Definition Client.h:45
Shortcut to directly build a Client from a file name.
Definition File_Client.h:39
File_Client(const char *file_name)
Definition File_Client.h:41
File_Client(const std::string &file_name)
Definition File_Client.h:47
Open_Mode
Definition Open_Mode.h:8
@ shared_write
like write_existing_or_create_new, but does not lock the file, and does not fail if locked
@ write_existing_or_create_new
either write_existing or create_new depending on whether the file exists. Racy in Posix,...
Definition Blob.h:7
JOEDB_FILE File
Definition File.h:25
Automatically generated by joedbc.
Definition Client.h:19