Libecoli
0.9.1
Extensible COmmand LIne library
Loading...
Searching...
No Matches
node_file.h
1
/* SPDX-License-Identifier: BSD-3-Clause
2
* Copyright 2016, Olivier MATZ <zer0@droids-corp.org>
3
*/
4
9
10
#pragma once
11
12
#include <dirent.h>
13
#include <sys/stat.h>
14
15
#include <ecoli/node.h>
16
17
struct
ec_node
*ec_node_file(
const
char
*
id
,
const
char
*file);
18
19
/* file is duplicated */
20
int
ec_node_file_set_str(
struct
ec_node
*node,
const
char
*file);
21
23
struct
ec_node_file_ops
{
24
int (*lstat)(
const
char
*pathname,
struct
stat *buf);
25
DIR *(*opendir)(
const
char
*name);
26
struct
dirent *(*readdir)(DIR *dirp);
27
int (*closedir)(DIR *dirp);
28
int (*dirfd)(DIR *dirp);
29
int (*fstatat)(
int
dirfd,
const
char
*pathname,
struct
stat *buf,
int
flags);
30
};
31
33
void
ec_node_file_set_ops(
const
struct
ec_node_file_ops
*ops);
34
ec_node
struct ec_node * ec_node(const char *typename, const char *id)
ec_node_file_ops
Definition
node_file.h:23
include
ecoli
node_file.h
Generated by
1.13.2