php_fileinfo.h 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. /*
  2. +----------------------------------------------------------------------+
  3. | PHP Version 7 |
  4. +----------------------------------------------------------------------+
  5. | Copyright (c) 1997-2018 The PHP Group |
  6. +----------------------------------------------------------------------+
  7. | This source file is subject to version 3.0 of the PHP license, |
  8. | that is bundled with this package in the file LICENSE, and is |
  9. | available through the world-wide-web at the following url: |
  10. | http://www.php.net/license/3_0.txt. |
  11. | If you did not receive a copy of the PHP license and are unable to |
  12. | obtain it through the world-wide-web, please send a note to |
  13. | license@php.net so we can mail you a copy immediately. |
  14. +----------------------------------------------------------------------+
  15. | Author: Ilia Alshanetsky <ilia@php.net> |
  16. +----------------------------------------------------------------------+
  17. */
  18. #ifndef PHP_FILEINFO_H
  19. #define PHP_FILEINFO_H
  20. extern zend_module_entry fileinfo_module_entry;
  21. #define phpext_fileinfo_ptr &fileinfo_module_entry
  22. #define PHP_FILEINFO_VERSION PHP_VERSION
  23. #ifdef PHP_WIN32
  24. #define PHP_FILEINFO_API __declspec(dllexport)
  25. #else
  26. #define PHP_FILEINFO_API
  27. #endif
  28. #ifdef ZTS
  29. #include "TSRM.h"
  30. #endif
  31. PHP_MINFO_FUNCTION(fileinfo);
  32. PHP_FUNCTION(finfo_open);
  33. PHP_FUNCTION(finfo_close);
  34. PHP_FUNCTION(finfo_set_flags);
  35. PHP_FUNCTION(finfo_file);
  36. PHP_FUNCTION(finfo_buffer);
  37. PHP_FUNCTION(mime_content_type);
  38. #ifdef ZTS
  39. #define FILEINFO_G(v) TSRMG(fileinfo_globals_id, zend_fileinfo_globals *, v)
  40. #else
  41. #define FILEINFO_G(v) (fileinfo_globals.v)
  42. #endif
  43. #endif /* PHP_FILEINFO_H */
  44. /*
  45. * Local variables:
  46. * tab-width: 4
  47. * c-basic-offset: 4
  48. * End:
  49. * vim600: noet sw=4 ts=4 fdm=marker
  50. * vim<600: noet sw=4 ts=4
  51. */