Skip to content

Commit d5b583a

Browse files
committed
Merge branch 'PHP-8.0'
* PHP-8.0: Use camelCase method names in OCICollection and OCILob
2 parents 8f601be + e94731f commit d5b583a

File tree

7 files changed

+26
-26
lines changed

7 files changed

+26
-26
lines changed

ext/oci8/oci8.stub.php

+6-6
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,7 @@ public function import(string $filename): bool {}
559559
* @alias oci_lob_import
560560
* @tentative-return-type
561561
*/
562-
public function savefile(string $filename): bool {}
562+
public function saveFile(string $filename): bool {}
563563

564564
/**
565565
* @alias oci_lob_load
@@ -637,19 +637,19 @@ public function flush(int $flag = 0): bool {}
637637
* @alias ocisetbufferinglob
638638
* @tentative-return-type
639639
*/
640-
public function setbuffering(bool $mode): bool {}
640+
public function setBuffering(bool $mode): bool {}
641641

642642
/**
643643
* @alias ocigetbufferinglob
644644
* @tentative-return-type
645645
*/
646-
public function getbuffering(): bool {}
646+
public function getBuffering(): bool {}
647647

648648
/**
649649
* @alias oci_lob_export
650650
* @tentative-return-type
651651
*/
652-
public function writetofile(string $filename, ?int $offset = null, ?int $length = null): bool {}
652+
public function writeToFile(string $filename, ?int $offset = null, ?int $length = null): bool {}
653653

654654
/**
655655
* @alias oci_lob_export
@@ -658,7 +658,7 @@ public function writetofile(string $filename, ?int $offset = null, ?int $length
658658
public function export(string $filename, ?int $offset = null, ?int $length = null): bool {}
659659

660660
/** @tentative-return-type */
661-
public function writetemporary(string $data, int $type = OCI_TEMP_CLOB): bool {}
661+
public function writeTemporary(string $data, int $type = OCI_TEMP_CLOB): bool {}
662662

663663
/** @tentative-return-type */
664664
public function close(): bool {}
@@ -699,7 +699,7 @@ public function assign(OCICollection $from): bool {}
699699
* @alias oci_collection_element_assign
700700
* @tentative-return-type
701701
*/
702-
public function assignelem(int $index, string $value): bool {}
702+
public function assignElem(int $index, string $value): bool {}
703703

704704
/**
705705
* @alias oci_collection_size

ext/oci8/oci8_arginfo.h

+15-15
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* This is a generated file, edit the .stub.php file instead.
2-
* Stub hash: caa419a313bfcbf14e179e6f9fc2270b432175b0 */
2+
* Stub hash: 57a4d5ea363a2fb6e006adb76ce3d273a2b20828 */
33

44
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_oci_define_by_name, 0, 3, _IS_BOOL, 0)
55
ZEND_ARG_INFO(0, statement)
@@ -447,7 +447,7 @@ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_import, 0
447447
ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0)
448448
ZEND_END_ARG_INFO()
449449

450-
#define arginfo_class_OCILob_savefile arginfo_class_OCILob_import
450+
#define arginfo_class_OCILob_saveFile arginfo_class_OCILob_import
451451

452452
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_MASK_EX(arginfo_class_OCILob_load, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
453453
ZEND_END_ARG_INFO()
@@ -493,21 +493,21 @@ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_flush, 0,
493493
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, flag, IS_LONG, 0, "0")
494494
ZEND_END_ARG_INFO()
495495

496-
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_setbuffering, 0, 1, _IS_BOOL, 0)
496+
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_setBuffering, 0, 1, _IS_BOOL, 0)
497497
ZEND_ARG_TYPE_INFO(0, mode, _IS_BOOL, 0)
498498
ZEND_END_ARG_INFO()
499499

500-
#define arginfo_class_OCILob_getbuffering arginfo_class_OCILob_eof
500+
#define arginfo_class_OCILob_getBuffering arginfo_class_OCILob_eof
501501

502-
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_writetofile, 0, 1, _IS_BOOL, 0)
502+
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_writeToFile, 0, 1, _IS_BOOL, 0)
503503
ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0)
504504
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, offset, IS_LONG, 1, "null")
505505
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, length, IS_LONG, 1, "null")
506506
ZEND_END_ARG_INFO()
507507

508-
#define arginfo_class_OCILob_export arginfo_class_OCILob_writetofile
508+
#define arginfo_class_OCILob_export arginfo_class_OCILob_writeToFile
509509

510-
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_writetemporary, 0, 1, _IS_BOOL, 0)
510+
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCILob_writeTemporary, 0, 1, _IS_BOOL, 0)
511511
ZEND_ARG_TYPE_INFO(0, data, IS_STRING, 0)
512512
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, type, IS_LONG, 0, "OCI_TEMP_CLOB")
513513
ZEND_END_ARG_INFO()
@@ -530,7 +530,7 @@ ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCICollection_as
530530
ZEND_ARG_OBJ_INFO(0, from, OCICollection, 0)
531531
ZEND_END_ARG_INFO()
532532

533-
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCICollection_assignelem, 0, 2, _IS_BOOL, 0)
533+
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_OCICollection_assignElem, 0, 2, _IS_BOOL, 0)
534534
ZEND_ARG_TYPE_INFO(0, index, IS_LONG, 0)
535535
ZEND_ARG_TYPE_INFO(0, value, IS_STRING, 0)
536536
ZEND_END_ARG_INFO()
@@ -621,7 +621,7 @@ ZEND_FUNCTION(oci_collection_trim);
621621
ZEND_FUNCTION(oci_new_collection);
622622
ZEND_FUNCTION(oci_register_taf_callback);
623623
ZEND_FUNCTION(oci_unregister_taf_callback);
624-
ZEND_METHOD(OCILob, writetemporary);
624+
ZEND_METHOD(OCILob, writeTemporary);
625625
ZEND_METHOD(OCILob, close);
626626

627627

@@ -756,7 +756,7 @@ static const zend_function_entry ext_functions[] = {
756756
static const zend_function_entry class_OCILob_methods[] = {
757757
ZEND_ME_MAPPING(save, oci_lob_save, arginfo_class_OCILob_save, ZEND_ACC_PUBLIC)
758758
ZEND_ME_MAPPING(import, oci_lob_import, arginfo_class_OCILob_import, ZEND_ACC_PUBLIC)
759-
ZEND_ME_MAPPING(savefile, oci_lob_import, arginfo_class_OCILob_savefile, ZEND_ACC_PUBLIC)
759+
ZEND_ME_MAPPING(saveFile, oci_lob_import, arginfo_class_OCILob_saveFile, ZEND_ACC_PUBLIC)
760760
ZEND_ME_MAPPING(load, oci_lob_load, arginfo_class_OCILob_load, ZEND_ACC_PUBLIC)
761761
ZEND_ME_MAPPING(read, oci_lob_read, arginfo_class_OCILob_read, ZEND_ACC_PUBLIC)
762762
ZEND_ME_MAPPING(eof, oci_lob_eof, arginfo_class_OCILob_eof, ZEND_ACC_PUBLIC)
@@ -769,11 +769,11 @@ static const zend_function_entry class_OCILob_methods[] = {
769769
ZEND_ME_MAPPING(truncate, oci_lob_truncate, arginfo_class_OCILob_truncate, ZEND_ACC_PUBLIC)
770770
ZEND_ME_MAPPING(erase, oci_lob_erase, arginfo_class_OCILob_erase, ZEND_ACC_PUBLIC)
771771
ZEND_ME_MAPPING(flush, oci_lob_flush, arginfo_class_OCILob_flush, ZEND_ACC_PUBLIC)
772-
ZEND_ME_MAPPING(setbuffering, ocisetbufferinglob, arginfo_class_OCILob_setbuffering, ZEND_ACC_PUBLIC)
773-
ZEND_ME_MAPPING(getbuffering, ocigetbufferinglob, arginfo_class_OCILob_getbuffering, ZEND_ACC_PUBLIC)
774-
ZEND_ME_MAPPING(writetofile, oci_lob_export, arginfo_class_OCILob_writetofile, ZEND_ACC_PUBLIC)
772+
ZEND_ME_MAPPING(setBuffering, ocisetbufferinglob, arginfo_class_OCILob_setBuffering, ZEND_ACC_PUBLIC)
773+
ZEND_ME_MAPPING(getBuffering, ocigetbufferinglob, arginfo_class_OCILob_getBuffering, ZEND_ACC_PUBLIC)
774+
ZEND_ME_MAPPING(writeToFile, oci_lob_export, arginfo_class_OCILob_writeToFile, ZEND_ACC_PUBLIC)
775775
ZEND_ME_MAPPING(export, oci_lob_export, arginfo_class_OCILob_export, ZEND_ACC_PUBLIC)
776-
ZEND_ME(OCILob, writetemporary, arginfo_class_OCILob_writetemporary, ZEND_ACC_PUBLIC)
776+
ZEND_ME(OCILob, writeTemporary, arginfo_class_OCILob_writeTemporary, ZEND_ACC_PUBLIC)
777777
ZEND_ME(OCILob, close, arginfo_class_OCILob_close, ZEND_ACC_PUBLIC)
778778
ZEND_ME_MAPPING(free, oci_free_descriptor, arginfo_class_OCILob_free, ZEND_ACC_PUBLIC)
779779
ZEND_FE_END
@@ -785,7 +785,7 @@ static const zend_function_entry class_OCICollection_methods[] = {
785785
ZEND_ME_MAPPING(append, oci_collection_append, arginfo_class_OCICollection_append, ZEND_ACC_PUBLIC)
786786
ZEND_ME_MAPPING(getElem, oci_collection_element_get, arginfo_class_OCICollection_getElem, ZEND_ACC_PUBLIC)
787787
ZEND_ME_MAPPING(assign, oci_collection_assign, arginfo_class_OCICollection_assign, ZEND_ACC_PUBLIC)
788-
ZEND_ME_MAPPING(assignelem, oci_collection_element_assign, arginfo_class_OCICollection_assignelem, ZEND_ACC_PUBLIC)
788+
ZEND_ME_MAPPING(assignElem, oci_collection_element_assign, arginfo_class_OCICollection_assignElem, ZEND_ACC_PUBLIC)
789789
ZEND_ME_MAPPING(size, oci_collection_size, arginfo_class_OCICollection_size, ZEND_ACC_PUBLIC)
790790
ZEND_ME_MAPPING(max, oci_collection_max, arginfo_class_OCICollection_max, ZEND_ACC_PUBLIC)
791791
ZEND_ME_MAPPING(trim, oci_collection_trim, arginfo_class_OCICollection_trim, ZEND_ACC_PUBLIC)

ext/oci8/oci8_interface.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -916,7 +916,7 @@ PHP_FUNCTION(oci_lob_export)
916916
/* }}} */
917917

918918
/* {{{ Writes temporary blob */
919-
PHP_METHOD(OCILob, writetemporary)
919+
PHP_METHOD(OCILob, writeTemporary)
920920
{
921921
zval *tmp, *z_descriptor;
922922
php_oci_descriptor *descriptor;

ext/oci8/tests/bug37220.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ $query = "UPDATE bug37220_tab
3131
$stmt = oci_parse ($c, $query);
3232
$clob = oci_new_descriptor($c, OCI_D_LOB);
3333
oci_bind_by_name($stmt, ':data', $clob, -1, OCI_B_CLOB);
34-
$clob->writetemporary("<MYTAG/>", OCI_TEMP_CLOB);
34+
$clob->writeTemporary("<MYTAG/>", OCI_TEMP_CLOB);
3535
$success = oci_execute($stmt, OCI_COMMIT_ON_SUCCESS);
3636
oci_free_statement($stmt);
3737
$clob->close();

ext/oci8/tests/bug43497.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ function fillxmltab($c)
122122
oci_bind_by_name($stmt, ":id", $id);
123123
$clob = oci_new_descriptor($c, OCI_D_LOB);
124124
oci_bind_by_name($stmt, ":xml", $clob, -1, OCI_B_CLOB);
125-
$clob->writetemporary($data);
125+
$clob->writeTemporary($data);
126126
oci_execute($stmt);
127127

128128
$clob->close();

ext/oci8/tests/define3.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ oci_bind_by_name($stmt,":id",$id);
2626
oci_bind_by_name($stmt,":fileimage",$fileimage,-1,OCI_B_BLOB);
2727
$id = 1;
2828
oci_execute($stmt, OCI_DEFAULT);
29-
$fileimage->savefile(__DIR__."/test.gif");
29+
$fileimage->saveFile(__DIR__."/test.gif");
3030
$data = $fileimage->load();
3131
var_dump(md5($data)); // original md5
3232
oci_commit($c);

ext/oci8/tests/null_byte_1.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ echo "Test 1: Import\n";
2323

2424
$lob = oci_new_descriptor($c, OCI_D_LOB);
2525
try {
26-
$lob->savefile("/tmp/abc\0def");
26+
$lob->saveFile("/tmp/abc\0def");
2727
} catch (ValueError $e) {
2828
echo $e->getMessage(), "\n";
2929
}

0 commit comments

Comments
 (0)