Skip to content

Commit ee08332

Browse files
authored
Merge pull request #260 from asbiin/fix-generator
Fix generator
2 parents a8ab087 + 71e1673 commit ee08332

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+3272
-3739
lines changed

composer.json

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@
5454
"generated/mailparse.php",
5555
"generated/mbstring.php",
5656
"generated/misc.php",
57-
"generated/msql.php",
5857
"generated/mysql.php",
5958
"generated/mysqli.php",
6059
"generated/mysqlndMs.php",
@@ -67,7 +66,6 @@
6766
"generated/password.php",
6867
"generated/pcntl.php",
6968
"generated/pcre.php",
70-
"generated/pdf.php",
7169
"generated/pgsql.php",
7270
"generated/posix.php",
7371
"generated/ps.php",
@@ -80,7 +78,6 @@
8078
"generated/shmop.php",
8179
"generated/simplexml.php",
8280
"generated/sockets.php",
83-
"generated/sodium.php",
8481
"generated/solr.php",
8582
"generated/spl.php",
8683
"generated/sqlsrv.php",

generated/Exceptions/MsqlException.php

Lines changed: 0 additions & 11 deletions
This file was deleted.

generated/Exceptions/PdfException.php

Lines changed: 0 additions & 11 deletions
This file was deleted.

generated/Exceptions/SodiumException.php

Lines changed: 0 additions & 11 deletions
This file was deleted.

generated/apache.php

Lines changed: 51 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ function apache_get_version(): string
2626
* Retrieve an Apache environment variable specified by
2727
* variable.
2828
*
29-
* This function requires Apache 2 otherwise it's undefined.
30-
*
3129
* @param string $variable The Apache environment variable
3230
* @param bool $walk_to_top Whether to get the top-level variable available to all Apache layers.
3331
* @return string The value of the Apache environment variable on success
@@ -45,6 +43,54 @@ function apache_getenv(string $variable, bool $walk_to_top = false): string
4543
}
4644

4745

46+
/**
47+
* This performs a partial request for a URI. It goes just far
48+
* enough to obtain all the important information about the given
49+
* resource.
50+
*
51+
* @param string $filename The filename (URI) that's being requested.
52+
* @return object An object of related URI information. The properties of
53+
* this object are:
54+
*
55+
*
56+
* status
57+
* the_request
58+
* status_line
59+
* method
60+
* content_type
61+
* handler
62+
* uri
63+
* filename
64+
* path_info
65+
* args
66+
* boundary
67+
* no_cache
68+
* no_local_copy
69+
* allowed
70+
* send_bodyct
71+
* bytes_sent
72+
* byterange
73+
* clength
74+
* unparsed_uri
75+
* mtime
76+
* request_time
77+
*
78+
*
79+
* Returns FALSE on failure.
80+
* @throws ApacheException
81+
*
82+
*/
83+
function apache_lookup_uri(string $filename): object
84+
{
85+
error_clear_last();
86+
$result = \apache_lookup_uri($filename);
87+
if ($result === false) {
88+
throw ApacheException::createFromPhpError();
89+
}
90+
return $result;
91+
}
92+
93+
4894
/**
4995
* Fetches all HTTP request headers from the current request. Works in the
5096
* Apache, FastCGI, CLI, FPM and NSAPI server module
@@ -163,14 +209,14 @@ function getallheaders(): array
163209
* To run the sub-request, all buffers are terminated and flushed to the
164210
* browser, pending headers are sent too.
165211
*
166-
* @param string $filename The file that the virtual command will be performed on.
212+
* @param string $uri The file that the virtual command will be performed on.
167213
* @throws ApacheException
168214
*
169215
*/
170-
function virtual(string $filename): void
216+
function virtual(string $uri): void
171217
{
172218
error_clear_last();
173-
$result = \virtual($filename);
219+
$result = \virtual($uri);
174220
if ($result === false) {
175221
throw ApacheException::createFromPhpError();
176222
}

0 commit comments

Comments
 (0)