1 /* 2 * Support functions 3 * 4 * Copyright (C) 2008-2020, Joachim Metz <joachim.metz@gmail.com> 5 * 6 * Refer to AUTHORS for acknowledgements. 7 * 8 * This program is free software: you can redistribute it and/or modify 9 * it under the terms of the GNU Lesser General Public License as published by 10 * the Free Software Foundation, either version 3 of the License, or 11 * (at your option) any later version. 12 * 13 * This program is distributed in the hope that it will be useful, 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 * GNU General Public License for more details. 17 * 18 * You should have received a copy of the GNU Lesser General Public License 19 * along with this program. If not, see <https://www.gnu.org/licenses/>. 20 */ 21 22 #if !defined( _LIBCFILE_SUPPORT_H ) 23 #define _LIBCFILE_SUPPORT_H 24 25 #include <common.h> 26 #include <types.h> 27 28 #include "libcfile_extern.h" 29 #include "libcfile_libcerror.h" 30 31 #if defined( __cplusplus ) 32 extern "C" { 33 #endif 34 35 #if !defined( HAVE_LOCAL_LIBCFILE ) 36 37 LIBCFILE_EXTERN \ 38 const char *libcfile_get_version( 39 void ); 40 41 LIBCFILE_EXTERN \ 42 int libcfile_get_codepage( 43 int *codepage, 44 libcerror_error_t **error ); 45 46 LIBCFILE_EXTERN \ 47 int libcfile_set_codepage( 48 int codepage, 49 libcerror_error_t **error ); 50 51 #endif /* !defined( HAVE_LOCAL_LIBCFILE ) */ 52 53 LIBCFILE_EXTERN \ 54 int libcfile_file_exists( 55 const char *filename, 56 libcerror_error_t **error ); 57 58 #if defined( HAVE_WIDE_CHARACTER_TYPE ) 59 60 LIBCFILE_EXTERN \ 61 int libcfile_file_exists_wide( 62 const wchar_t *filename, 63 libcerror_error_t **error ); 64 65 #endif /* defined( HAVE_WIDE_CHARACTER_TYPE ) */ 66 67 LIBCFILE_EXTERN \ 68 int libcfile_file_remove( 69 const char *filename, 70 libcerror_error_t **error ); 71 72 LIBCFILE_EXTERN \ 73 int libcfile_file_remove_with_error_code( 74 const char *filename, 75 uint32_t *error_code, 76 libcerror_error_t **error ); 77 78 #if defined( HAVE_WIDE_CHARACTER_TYPE ) 79 80 LIBCFILE_EXTERN \ 81 int libcfile_file_remove_wide( 82 const wchar_t *filename, 83 libcerror_error_t **error ); 84 85 LIBCFILE_EXTERN \ 86 int libcfile_file_remove_wide_with_error_code( 87 const wchar_t *filename, 88 uint32_t *error_code, 89 libcerror_error_t **error ); 90 91 #endif /* defined( HAVE_WIDE_CHARACTER_TYPE ) */ 92 93 #if defined( __cplusplus ) 94 } 95 #endif 96 97 #endif /* !defined( _LIBCFILE_SUPPORT_H ) */ 98 99