diff options
| -rw-r--r-- | PHPINFO | 3 | ||||
| -rw-r--r-- | REFLECTION | 97 | ||||
| -rw-r--r-- | php-pecl-csv.spec | 21 | 
3 files changed, 75 insertions, 46 deletions
@@ -2,6 +2,7 @@  csv  CSV support => enabled -Version => 0.3.1 +Version => 0.4.0  Author => George Peter Banyard  Bug reports => https://gitlab.com/Girgias/csv-php-extension/issues +Sponsor me => https://github.com/sponsors/Girgias @@ -1,45 +1,76 @@ -Extension [ <persistent> extension #73 csv version 0.3.1 ] { +Extension [ <persistent> extension #69 csv version 0.4.0 ] { -  - Functions { -    Function [ <internal:csv> function csv_array_to_row ] { +  - Classes [1] { +    Class [ <internal:csv> final class CSV ] { -      - Parameters [4] { -        Parameter #0 [ <required> array $fields ] -        Parameter #1 [ <optional> string $delimiter ] -        Parameter #2 [ <optional> string $enclosure ] -        Parameter #3 [ <optional> string $eolSequence ] +      - Constants [0] {        } -      - Return [ string ] -    } -    Function [ <internal:csv> function csv_collection_to_file ] { -      - Parameters [4] { -        Parameter #0 [ <required> array $collection ] -        Parameter #1 [ <optional> string $delimiter ] -        Parameter #2 [ <optional> string $enclosure ] -        Parameter #3 [ <optional> string $eolSequence ] +      - Static properties [0] {        } -      - Return [ string ] -    } -    Function [ <internal:csv> function csv_file_to_collection ] { -      - Parameters [4] { -        Parameter #0 [ <required> string $file ] -        Parameter #1 [ <optional> string $delimiter ] -        Parameter #2 [ <optional> string $enclosure ] -        Parameter #3 [ <optional> string $eolSequence ] +      - Static methods [5] { +        Method [ <internal:csv> static public method arrayToRow ] { + +          - Parameters [4] { +            Parameter #0 [ <required> array $fields ] +            Parameter #1 [ <optional> string $delimiter = ',' ] +            Parameter #2 [ <optional> string $enclosure = '"' ] +            Parameter #3 [ <optional> string $eolSequence = "\r\n" ] +          } +          - Return [ string ] +        } + +        Method [ <internal:csv> static public method rowToArray ] { + +          - Parameters [4] { +            Parameter #0 [ <required> string $row ] +            Parameter #1 [ <optional> string $delimiter = ',' ] +            Parameter #2 [ <optional> string $enclosure = '"' ] +            Parameter #3 [ <optional> string $eolSequence = "\r\n" ] +          } +          - Return [ array ] +        } + +        Method [ <internal:csv> static public method collectionToBuffer ] { + +          - Parameters [4] { +            Parameter #0 [ <required> iterable $collection ] +            Parameter #1 [ <optional> string $delimiter = ',' ] +            Parameter #2 [ <optional> string $enclosure = '"' ] +            Parameter #3 [ <optional> string $eolSequence = "\r\n" ] +          } +          - Return [ string ] +        } + +        Method [ <internal:csv> static public method bufferToCollection ] { + +          - Parameters [4] { +            Parameter #0 [ <required> string $buffer ] +            Parameter #1 [ <optional> string $delimiter = ',' ] +            Parameter #2 [ <optional> string $enclosure = '"' ] +            Parameter #3 [ <optional> string $eolSequence = "\r\n" ] +          } +          - Return [ array ] +        } + +        Method [ <internal:csv> static public method bufferToCollectionLax ] { + +          - Parameters [4] { +            Parameter #0 [ <required> string $buffer ] +            Parameter #1 [ <optional> string $delimiter = ',' ] +            Parameter #2 [ <optional> string $enclosure = '"' ] +            Parameter #3 [ <optional> string $eolSequence = "\r\n" ] +          } +          - Return [ array ] +        } +      } + +      - Properties [0] {        } -      - Return [ array ] -    } -    Function [ <internal:csv> function csv_row_to_array ] { -      - Parameters [4] { -        Parameter #0 [ <required> string $row ] -        Parameter #1 [ <optional> string $delimiter ] -        Parameter #2 [ <optional> string $enclosure ] -        Parameter #3 [ <optional> string $eolSequence ] +      - Methods [0] {        } -      - Return [ array ]      }    }  } diff --git a/php-pecl-csv.spec b/php-pecl-csv.spec index dbde331..bc501d8 100644 --- a/php-pecl-csv.spec +++ b/php-pecl-csv.spec @@ -1,6 +1,6 @@  # remirepo spec file for php-pecl-csv  # -# Copyright (c) 2020 Remi Collet +# Copyright (c) 2020-2021 Remi Collet  # License: CC-BY-SA  # http://creativecommons.org/licenses/by-sa/4.0/  # @@ -21,16 +21,17 @@  Summary:        CSV PHP extension  Name:           %{?sub_prefix}php-pecl-%{pecl_name} -Version:        0.3.1 -Release:        2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Version:        0.4.0 +Release:        1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}  License:        PHP  URL:            https://pecl.php.net/package/%{proj_name}  Source0:        https://pecl.php.net/get/%{proj_name}-%{version}.tgz  Patch0:         0001-fix-c89.patch +BuildRequires:  make  BuildRequires:  %{?dtsprefix}gcc -BuildRequires:  %{?scl_prefix}php-devel > 7.3 +BuildRequires:  %{?scl_prefix}php-devel >= 8.0  BuildRequires:  %{?scl_prefix}php-pear  Requires:       %{?scl_prefix}php(zend-abi) = %{php_zend_api} @@ -49,20 +50,12 @@ Provides:       %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa}  = %{version}-%{rele  %if "%{?packager}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel}  # Other third party repo stuff  Obsoletes:      php73-pecl-%{pecl_name} <= %{version} -%if "%{php_version}" > "7.4"  Obsoletes:      php74-pecl-%{pecl_name} <= %{version} -%endif  %if "%{php_version}" > "8.0"  Obsoletes:      php80-pecl-%{pecl_name} <= %{version}  %endif  %endif -%if 0%{?fedora} < 20 && 0%{?rhel} < 7 -# Filter shared private -%{?filter_provides_in: %filter_provides_in %{_libdir}/.*\.so$} -%{?filter_setup} -%endif -  %description  A new and improved CSV file PHP extension which follows RFC 4180 instead of @@ -215,6 +208,10 @@ fi  %changelog +* Tue Feb 23 2021 Remi Collet <remi@remirepo.net> - 0.4.0-1 +- update to 0.4.0 +- raise dependency on PHP 8 +  * Wed Sep 30 2020 Remi Collet <remi@remirepo.net> - 0.3.1-2.7.3  - rebuild for PHP 8.0.0RC1  | 
