roo_io
API Documentation for roo_io
Loading...
Searching...
No Matches
littlefs.h
Go to the documentation of this file.
1
#pragma once
2
3
#if (defined ESP_PLATFORM || defined ROO_TESTING) && \
4
__has_include("esp_littlefs.h")
5
6
#include "
roo_io/fs/filesystem.h
"
7
8
namespace
roo_io
{
9
10
class
LittlefsFs
:
public
Filesystem {
11
public
:
12
const
char
*
mountPoint
()
const
;
13
void
setMountPoint
(
const
char
*
mount_point
);
14
15
const
char
*
partitionLabel
()
const
;
16
void
setPartitionLabel
(
const
char
*
partition_label
);
17
18
bool
formatIfMountFailed
()
const
;
19
void
setFormatIfMountFailed
(
bool
format_if_mount_failed
);
20
21
MediaPresence checkMediaPresence()
override
;
22
23
protected
:
24
MountImpl::MountResult mountImpl(std::function<
void
()>
unmount_fn
)
override
;
25
26
void
unmountImpl()
override
;
27
28
Status
format
();
29
30
private
:
31
friend
LittlefsFs
CreateLittlefsFs
();
32
33
LittlefsFs
();
34
35
std::string
mount_point_
;
36
bool
format_if_mount_failed_
;
37
38
bool
has_partition_label_
;
39
std::string
partition_label_
;
40
std::string
mounted_partition_label_
;
41
};
42
43
extern
LittlefsFs
LITTLEFS
;
44
45
}
// namespace roo_io
46
47
#endif
// ESP_PLATFORM
filesystem.h
roo_io
Definition
byte.h:6
roo_io::basic_string_view
roo::basic_string_view< CharT, Traits > basic_string_view
Definition
string_view.h:8
roo_io::Status
Status
Definition
status.h:7
temp_repos
roo_io
src
roo_io
fs
esp32
littlefs.h
Generated by
1.9.8