GNU Octave  4.4.1
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
stat-wrappers.h
Go to the documentation of this file.
1 /*
2 
3 Copyright (C) 2016-2018 John W. Eaton
4 
5 This file is part of Octave.
6 
7 Octave is free software: you can redistribute it and/or modify it
8 under the terms of the GNU General Public License as published by
9 the Free Software Foundation, either version 3 of the License, or
10 (at your option) any later version.
11 
12 Octave is distributed in the hope that it will be useful, but
13 WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16 
17 You should have received a copy of the GNU General Public License
18 along with Octave; see the file COPYING. If not, see
19 <https://www.gnu.org/licenses/>.
20 
21 */
22 
23 #if ! defined (octave_stat_wrappers_h)
24 #define octave_stat_wrappers_h 1
25 
26 #if defined __cplusplus
27 # include <ctime>
28 #else
29 # include <stdbool.h>
30 # include <time.h>
31 #endif
32 
33 #include <sys/types.h>
34 
35 #if defined __cplusplus
36 extern "C" {
37 #endif
38 
39 extern int octave_mkdir_wrapper (const char *name, mode_t mode);
40 
41 extern int octave_mkfifo_wrapper (const char *name, mode_t mode);
42 
43 extern int octave_umask_wrapper (mode_t mode);
44 
45 extern int
46 octave_stat_wrapper (const char *fname, mode_t *mode, ino_t *ino,
47  dev_t *dev, nlink_t *nlink, uid_t *uid,
48  gid_t *gid, off_t *size, time_t *atime,
49  time_t *mtime, time_t *ctime, dev_t *rdev,
50  long *blksize, long *blocks);
51 
52 extern int
53 octave_lstat_wrapper (const char *lname, mode_t *mode, ino_t *ino,
54  dev_t *dev, nlink_t *nlink, uid_t *uid,
55  gid_t *gid, off_t *size, time_t *atime,
56  time_t *mtime, time_t *ctime, dev_t *rdev,
57  long *blksize, long *blocks);
58 
59 extern int
60 octave_fstat_wrapper (int fid, mode_t *mode, ino_t *ino,
61  dev_t *dev, nlink_t *nlink, uid_t *uid,
62  gid_t *gid, off_t *size, time_t *atime,
63  time_t *mtime, time_t *ctime, dev_t *rdev,
64  long *blksize, long *blocks);
65 
66 extern bool octave_is_blk_wrapper (mode_t mode);
67 extern bool octave_is_chr_wrapper (mode_t mode);
68 extern bool octave_is_dir_wrapper (mode_t mode);
69 extern bool octave_is_fifo_wrapper (mode_t mode);
70 extern bool octave_is_lnk_wrapper (mode_t mode);
71 extern bool octave_is_reg_wrapper (mode_t mode);
72 extern bool octave_is_sock_wrapper (mode_t mode);
73 
74 extern bool octave_have_struct_stat_st_rdev (void);
75 extern bool octave_have_struct_stat_st_blksize (void);
76 extern bool octave_have_struct_stat_st_blocks (void);
77 
78 #if defined __cplusplus
79 }
80 #endif
81 
82 #endif
fname
Definition: load-save.cc:767
Return the CPU time used by your Octave session The first output is the total time spent executing your process and is equal to the sum of second and third which are the number of CPU seconds spent executing in user mode and the number of CPU seconds spent executing in system mode
Definition: data.cc:6348
bool octave_have_struct_stat_st_blocks(void)
bool octave_is_chr_wrapper(mode_t mode)
bool octave_have_struct_stat_st_blksize(void)
bool octave_is_dir_wrapper(mode_t mode)
int octave_fstat_wrapper(int fid, mode_t *mode, ino_t *ino, dev_t *dev, nlink_t *nlink, uid_t *uid, gid_t *gid, off_t *size, time_t *atime, time_t *mtime, time_t *ctime, dev_t *rdev, long *blksize, long *blocks)
bool octave_is_lnk_wrapper(mode_t mode)
nd deftypefn *std::string name
Definition: sysdep.cc:647
bool octave_is_reg_wrapper(mode_t mode)
int octave_mkdir_wrapper(const char *name, mode_t mode)
Definition: stat-wrappers.c:40
int octave_umask_wrapper(mode_t mode)
Definition: stat-wrappers.c:52
bool octave_is_sock_wrapper(mode_t mode)
int octave_stat_wrapper(const char *fname, mode_t *mode, ino_t *ino, dev_t *dev, nlink_t *nlink, uid_t *uid, gid_t *gid, off_t *size, time_t *atime, time_t *mtime, time_t *ctime, dev_t *rdev, long *blksize, long *blocks)
Definition: stat-wrappers.c:95
bool octave_is_blk_wrapper(mode_t mode)
bool octave_have_struct_stat_st_rdev(void)
bool octave_is_fifo_wrapper(mode_t mode)
int octave_mkfifo_wrapper(const char *name, mode_t mode)
Definition: stat-wrappers.c:46
int octave_lstat_wrapper(const char *lname, mode_t *mode, ino_t *ino, dev_t *dev, nlink_t *nlink, uid_t *uid, gid_t *gid, off_t *size, time_t *atime, time_t *mtime, time_t *ctime, dev_t *rdev, long *blksize, long *blocks)
int fid
Definition: file-io.cc:625