|
2 | 2 | * Generated by build-library.php, Please DO NOT modify!
|
3 | 3 | */
|
4 | 4 |
|
5 |
| -/* $Id: 1ed49dbae3a1850b3a67d9904e07dac9b96adb43 */ |
| 5 | +/* $Id: b591f704aaab92336e8906d2584b7030fde90e87 */ |
6 | 6 |
|
7 | 7 | static const char* swoole_library_source_constants =
|
8 | 8 | "\n"
|
@@ -618,34 +618,33 @@ static const char* swoole_library_source_core_string_object =
|
618 | 618 | " /**\n"
|
619 | 619 | " * @return static\n"
|
620 | 620 | " */\n"
|
621 |
| - " public function substr(int $offset, ?int $length = null)\n" |
| 621 | + " public function substr(int $offset, ?int $length = null): self\n" |
622 | 622 | " {\n"
|
623 | 623 | " return new static(substr($this->string, ...func_get_args()));\n"
|
624 | 624 | " }\n"
|
625 | 625 | "\n"
|
626 |
| - " public function repeat(int $n): StringObject\n" |
| 626 | + " /**\n" |
| 627 | + " * @return static\n" |
| 628 | + " */\n" |
| 629 | + " public function repeat(int $times): self\n" |
627 | 630 | " {\n"
|
628 |
| - " return new static(str_repeat($this->string, $n));\n" |
| 631 | + " return new static(str_repeat($this->string, $times));\n" |
629 | 632 | " }\n"
|
630 | 633 | "\n"
|
631 | 634 | " /**\n"
|
632 |
| - " * @param $str\n" |
| 635 | + " * @param mixed $str\n" |
| 636 | + " * @return static\n" |
633 | 637 | " */\n"
|
634 |
| - " public function append($str): StringObject\n" |
| 638 | + " public function append($str): self\n" |
635 | 639 | " {\n"
|
636 |
| - " if (is_string($str)) {\n" |
637 |
| - " $this->string .= $str;\n" |
638 |
| - " } else {\n" |
639 |
| - " $this->string .= strval($str);\n" |
640 |
| - " }\n" |
641 |
| - " return $this;\n" |
| 640 | + " return new static($this->string .= $str);\n" |
642 | 641 | " }\n"
|
643 | 642 | "\n"
|
644 | 643 | " /**\n"
|
645 | 644 | " * @param null|int $count\n"
|
646 | 645 | " * @return static\n"
|
647 | 646 | " */\n"
|
648 |
| - " public function replace(string $search, string $replace, &$count = null)\n" |
| 647 | + " public function replace(string $search, string $replace, &$count = null): self\n" |
649 | 648 | " {\n"
|
650 | 649 | " return new static(str_replace($search, $replace, $this->string, $count));\n"
|
651 | 650 | " }\n"
|
@@ -692,9 +691,9 @@ static const char* swoole_library_source_core_string_object =
|
692 | 691 | " /**\n"
|
693 | 692 | " * @return static\n"
|
694 | 693 | " */\n"
|
695 |
| - " public function chunkSplit(int $chunkLength = 76, string $chunkEnd = '')\n" |
| 694 | + " public function chunkSplit(int $chunkLength = 76, string $chunkEnd = ''): self\n" |
696 | 695 | " {\n"
|
697 |
| - " return new static(chunk_split($this->string, ...func_get_args()));\n" |
| 696 | + " return new static(chunk_split($this->string, $chunkLength, $chunkEnd));\n" |
698 | 697 | " }\n"
|
699 | 698 | "\n"
|
700 | 699 | " public function chunk(int $splitLength = 1): ArrayObject\n"
|
@@ -3517,6 +3516,7 @@ static const char* swoole_library_source_core_curl_handler =
|
3517 | 3516 | " 'protocol' => 0,\n"
|
3518 | 3517 | " 'ssl_verifyresult' => 0,\n"
|
3519 | 3518 | " 'scheme' => '',\n"
|
| 3519 | + " 'private' => '',\n" |
3520 | 3520 | " ];\n"
|
3521 | 3521 | "\n"
|
3522 | 3522 | " private $withHeaderOut = false;\n"
|
@@ -3880,6 +3880,9 @@ static const char* swoole_library_source_core_curl_handler =
|
3880 | 3880 | " case CURLOPT_TCP_NODELAY:\n"
|
3881 | 3881 | " $this->clientOptions[Constant::OPTION_OPEN_TCP_NODELAY] = boolval($value);\n"
|
3882 | 3882 | " break;\n"
|
| 3883 | + " case CURLOPT_PRIVATE:\n" |
| 3884 | + " $this->info['private'] = $value;\n" |
| 3885 | + " break;\n" |
3883 | 3886 | " /*\n"
|
3884 | 3887 | " * Ignore options\n"
|
3885 | 3888 | " */\n"
|
@@ -7115,6 +7118,8 @@ static const char* swoole_library_source_ext_curl =
|
7115 | 7118 | " return $info['redirect_time'];\n"
|
7116 | 7119 | " case CURLINFO_HEADER_SIZE:\n"
|
7117 | 7120 | " return $info['header_size'];\n"
|
| 7121 | + " case CURLINFO_PRIVATE:\n" |
| 7122 | + " return $info['private'];\n" |
7118 | 7123 | " default:\n"
|
7119 | 7124 | " return null;\n"
|
7120 | 7125 | " }\n"
|
|
0 commit comments