| ARX 1.0 The next-generation open source augmented reality toolkit.

Loading...
Searching...
No Matches
Macros | Functions
file_utils.c File Reference
`#include <ARX/ARUtil/file_utils.h>`
`#include <stdio.h>`
`#include <string.h>`
`#include <stdbool.h>`
`#include <unistd.h>`
`#include <sys/param.h>`
`#include <utime.h>`
`#include <ftw.h>`
`#include <termios.h>`
`#include <stdlib.h>`
`#include <sys/stat.h>`
`#include <errno.h>`
`#include <time.h>`
`#include "uuid/uuid_sha1.h"`
`#include "unzip.h"`
`#include "zip.h"`
Include dependency graph for file_utils.c:

## Macros
#define | FOPEN_FUNC(filename, mode) fopen(filename, mode)
#define | FTELLO_FUNC(stream) ftello(stream)
#define | FSEEKO_FUNC(stream, offset, origin) fseeko(stream, offset, origin)
#define | WRITEBUFFERSIZE (8192)
#define | NOCRYPT
#define | BUFSIZE 16384
#define | datevalue_in_range(min, max, value) ((min) <= (value) && (value) <= (max))
#define | SHA1_READ_BUFSIZE 16384

## Functions
int | test_f (const char *file, const char *dir)
int | test_d (const char *dir)
int | cp_f (const char *source_file, const char *target_file)
int | rn_f (const char *source_file, const char *target_file)
int | mkdir_p (const char *path)
int | rm_rf (const char *path)
int | unzip_od (const char *zipFilePathname, const char *dir)
int | zip_od (char *zipFilePathname, const char *baseFilePath, const char **fileNames, int totalFiles)
int64_t | get_file_size (const char *pathName)
char * | cat (const char *file, size_t *bufSize_p)
char | read_sn1 (void)
int | export_ (const char *name, const char *val)
int | sha1 (const char *filePath, char sha1[41])

## Macro Definition Documentation

## ◆ BUFSIZE [1/2]

#define BUFSIZE 16384

## ◆ BUFSIZE [2/2]

#define BUFSIZE 16384

## ◆ datevalue_in_range

#define datevalue_in_range | ( |  | min,
|  |  | max,
|  |  | value
| ) |  | ((min) <= (value) && (value) <= (max))

## ◆ FOPEN_FUNC

#define FOPEN_FUNC | ( |  | filename,
|  |  | mode
| ) |  | fopen(filename, mode)

## ◆ FSEEKO_FUNC

#define FSEEKO_FUNC | ( |  | stream,
|  |  | offset,
|  |  | origin
| ) |  | fseeko(stream, offset, origin)

## ◆ FTELLO_FUNC

#define FTELLO_FUNC | ( |  | stream | ) | ftello(stream)

## ◆ NOCRYPT

#define NOCRYPT

## ◆ SHA1_READ_BUFSIZE

#define SHA1_READ_BUFSIZE 16384

## ◆ WRITEBUFFERSIZE

#define WRITEBUFFERSIZE (8192)

## Function Documentation

## ◆ cat()

char * cat | ( | const char * | file,
|  | size_t * | bufSize_p
| ) |  |

## ◆ cp_f()

int cp_f | ( | const char * | source_file,
|  | const char * | target_file
| ) |  |

## ◆ export_()

int export_ | ( | const char * | name,
|  | const char * | val
| ) |  |

## ◆ get_file_size()

int64_t get_file_size | ( | const char * | pathName | ) |

## ◆ mkdir_p()

int mkdir_p | ( | const char * | path | ) |

## ◆ read_sn1()

char read_sn1 | ( | void |  | ) |

## ◆ rm_rf()

int rm_rf | ( | const char * | path | ) |

Here is the call graph for this function:

## ◆ rn_f()

int rn_f | ( | const char * | source_file,
|  | const char * | target_file
| ) |  |

Here is the call graph for this function:

## ◆ sha1()

int sha1 | ( | const char * | filePath,
|  | char | sha1[41]
| ) |  |

Here is the call graph for this function:

## ◆ test_d()

int test_d | ( | const char * | dir | ) |

## ◆ test_f()

int test_f | ( | const char * | file,
|  | const char * | dir
| ) |  |

## ◆ unzip_od()

int unzip_od | ( | const char * | zipFilePathname,
|  | const char * | dir
| ) |  |

Here is the call graph for this function:

## ◆ zip_od()

int zip_od | ( | char * | zipFilePathname,
|  | const char * | baseFilePath,
|  | const char ** | fileNames,
|  | int | totalFiles
| ) |  |

Here is the call graph for this function: