Coverage Report

Created: 2026-09-14 06:25

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/php-src/ext/standard/dir_arginfo.h
Line
Count
Source
1
/* This is a generated file, edit dir.stub.php instead.
2
 * Stub hash: e21d382cd4001001874c49d8c5244efb57613910 */
3
4
#include "zend_constants.h"
5
6
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Directory_close, 0, 0, IS_VOID, 0)
7
ZEND_END_ARG_INFO()
8
9
#define arginfo_class_Directory_rewind arginfo_class_Directory_close
10
11
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_class_Directory_read, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
12
ZEND_END_ARG_INFO()
13
14
ZEND_METHOD(Directory, close);
15
ZEND_METHOD(Directory, rewind);
16
ZEND_METHOD(Directory, read);
17
18
static const zend_function_entry class_Directory_methods[] = {
19
  ZEND_ME(Directory, close, arginfo_class_Directory_close, ZEND_ACC_PUBLIC)
20
  ZEND_ME(Directory, rewind, arginfo_class_Directory_rewind, ZEND_ACC_PUBLIC)
21
  ZEND_ME(Directory, read, arginfo_class_Directory_read, ZEND_ACC_PUBLIC)
22
  ZEND_FE_END
23
};
24
25
static void register_dir_symbols(int module_number)
26
16
{
27
16
  REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", dirsep_str, CONST_PERSISTENT);
28
16
  REGISTER_STRING_CONSTANT("PATH_SEPARATOR", pathsep_str, CONST_PERSISTENT);
29
16
#if (defined(PHP_GLOB_BRACE) && PHP_GLOB_BRACE != 0)
30
16
  REGISTER_LONG_CONSTANT("GLOB_BRACE", PHP_GLOB_BRACE, CONST_PERSISTENT);
31
16
#endif
32
16
#if (defined(PHP_GLOB_ERR) && PHP_GLOB_ERR != 0)
33
16
  REGISTER_LONG_CONSTANT("GLOB_ERR", PHP_GLOB_ERR, CONST_PERSISTENT);
34
16
#endif
35
16
#if (defined(PHP_GLOB_MARK) && PHP_GLOB_MARK != 0)
36
16
  REGISTER_LONG_CONSTANT("GLOB_MARK", PHP_GLOB_MARK, CONST_PERSISTENT);
37
16
#endif
38
16
#if (defined(PHP_GLOB_NOCHECK) && PHP_GLOB_NOCHECK != 0)
39
16
  REGISTER_LONG_CONSTANT("GLOB_NOCHECK", PHP_GLOB_NOCHECK, CONST_PERSISTENT);
40
16
#endif
41
16
#if (defined(PHP_GLOB_NOESCAPE) && PHP_GLOB_NOESCAPE != 0)
42
16
  REGISTER_LONG_CONSTANT("GLOB_NOESCAPE", PHP_GLOB_NOESCAPE, CONST_PERSISTENT);
43
16
#endif
44
16
#if (defined(PHP_GLOB_NOSORT) && PHP_GLOB_NOSORT != 0)
45
16
  REGISTER_LONG_CONSTANT("GLOB_NOSORT", PHP_GLOB_NOSORT, CONST_PERSISTENT);
46
16
#endif
47
16
#if (defined(PHP_GLOB_ONLYDIR) && PHP_GLOB_ONLYDIR != 0)
48
16
  REGISTER_LONG_CONSTANT("GLOB_ONLYDIR", PHP_GLOB_ONLYDIR, CONST_PERSISTENT);
49
16
#endif
50
16
#if defined(PHP_GLOB_AVAILABLE_FLAGS)
51
16
  REGISTER_LONG_CONSTANT("GLOB_AVAILABLE_FLAGS", PHP_GLOB_AVAILABLE_FLAGS, CONST_PERSISTENT);
52
16
#endif
53
16
  REGISTER_LONG_CONSTANT("SCANDIR_SORT_ASCENDING", PHP_SCANDIR_SORT_ASCENDING, CONST_PERSISTENT);
54
16
  REGISTER_LONG_CONSTANT("SCANDIR_SORT_DESCENDING", PHP_SCANDIR_SORT_DESCENDING, CONST_PERSISTENT);
55
16
  REGISTER_LONG_CONSTANT("SCANDIR_SORT_NONE", PHP_SCANDIR_SORT_NONE, CONST_PERSISTENT);
56
16
}
57
58
static zend_class_entry *register_class_Directory(void)
59
16
{
60
16
  zend_class_entry ce, *class_entry;
61
62
16
  INIT_CLASS_ENTRY(ce, "Directory", class_Directory_methods);
63
16
  class_entry = zend_register_internal_class_with_flags(&ce, NULL, ZEND_ACC_FINAL|ZEND_ACC_NO_DYNAMIC_PROPERTIES|ZEND_ACC_NOT_SERIALIZABLE);
64
65
16
  zval property_path_default_value;
66
16
  ZVAL_UNDEF(&property_path_default_value);
67
16
  zend_declare_typed_property(class_entry, ZSTR_KNOWN(ZEND_STR_PATH), &property_path_default_value, ZEND_ACC_PUBLIC|ZEND_ACC_READONLY, NULL, (zend_type) ZEND_TYPE_INIT_MASK(MAY_BE_STRING));
68
69
16
  zval property_handle_default_value;
70
16
  ZVAL_UNDEF(&property_handle_default_value);
71
16
  zend_string *property_handle_name = zend_string_init("handle", sizeof("handle") - 1, true);
72
16
  zend_declare_typed_property(class_entry, property_handle_name, &property_handle_default_value, ZEND_ACC_PUBLIC|ZEND_ACC_READONLY, NULL, (zend_type) ZEND_TYPE_INIT_MASK(MAY_BE_ANY));
73
16
  zend_string_release_ex(property_handle_name, true);
74
75
16
  return class_entry;
76
16
}