Releases: thephpleague/csv
version 6.0.0
New API
- Stream Filter API added to enable the use of PHP stream filters on CSV objects.
New Methods
- To simplify CSV objects instantiation new named constructors are added
League\Csv\AbstractCsv::createFromPath
andLeague\Csv\AbstractCsv::createFromFileObject
- New methods allow creating CSV objects from already created CSV objects:
League\Csv\AbstractCsv::newWriter
andLeague\Csv\AbstractCsv::newReader
methods can be call on both classes
Bug Fixes
League\Csv\Reader::each
is now more strict$callable
MUST returns true
Removed Methods
League\Csv\AbstractCsv::detectDelimiter
replaced byLeague\Csv\AbstractCsv::detectDelimiterList
League\Csv\AbstractCsv::set/getEncoding
replaced byLeague\Csv\AbstractCsv::set/getEncodingFrom
League\Csv\Reader::getWriter
replaced byLeague\Csv\AbstractCsv::newWriter
League\Csv\Writer::getReader
replaced byLeague\Csv\AbstractCsv::newReader
League\Csv\Reader::setSortBy
deprecated since version 5.2League\Csv\Reader::setFilter
deprecated since version 5.1
Miscellaneous
- Since
HHVM 3.2+
supports PHPFilterCallbackIterator
, the library now works on HHVM. - Code quality improved
- Adding a changelog to the library
Please refers to the documentation or the library CHANGELOG for more details
version 5.4.0
New Methods
the \League\Csv\Writer
class gets 3 new methods to deal with issue #34
Writer::setColumnsCount
Writer::getColumnsCount
Writer::autodetectColumnsCount
To deal with column consistency check when inserting rows.
Deprecated Method
the \League\Csv\Reader::fetchCol
method is renamed the \League\Csv\fetchColumn
. The old method remains as a alias of the new method but will be remove on the next major version release. The change is made to add consistency with the new Writer
methods.
Please refers to the documentation to see how the new methods work.
version 5.3.1
- bug fixes in
League\Csv\AbstractCSV
- internal code refactoring
- now
League\Csv\Reader
andLeague\Csv\Writer
class both use ther+
$open_mode
by default
version 5.3.0
New methods
Writer::setNullHandlingMode
and Writer::getNullHandlingMode
to better handle null
insertion and/or conversion into a CSV field data #28
Bug fix
You don't need to set the ini_set("auto_detect_line_endings", true);
anymore has the library will automatically do it for you. It is needed to be correctly work with a CSV built on a OSX machines.
This version features also internal code improvements.
Please refers to the official documentation for a full explication on the new features.
version 5.2.0
New methods
Reader::addSortBy
,Reader::removeSortBy
,Reader::hasSortBy
,Reader::clearSortBy
to enhance sorting capabilities #12Reader::clearFilter
to enhance filtering capabilities #11
Improved Methods
Reader::setOffset
now default to0
;Reader::setLimit
now default to-1
;
Bug fix
AbstractCsv::detectDelimiter
#16
Deprecated methods
Reader::setSortBy
is deprecated and will be remove in the next major release. The method is now an alias ofReader::addSortBy
. #12
Please review the documentation for more details on how to use these new features
version 5.1.0
New methods
Reader::each
to apply a callable to each CSV rowReader::addFilter
,Reader::removeFilter
,Reader::hasFilter
to enhance filtering capabilitiesReader::detectDelimiter
andWriter::detectDelimiter
to ease working with unknown CSV data
Deprecated methods
Reader::setFilter
is deprecated and will be remove in the next major release. The method is now an alias ofReader::addFilter
.
Please review the documentation for more details on how to use these new features
version 5.0.0
- Updated to reflect new GitHub username (changed from
nyamsprod
tothephpleague
). - Updated to reflect new namespace (changed from
Bakame
toLeague
).
version 4.2.1
Bug Fix
Remove $open_mode
validation. Now the validation is done by PHP Internals
New Traits
\Bakame\Csv\Iterator\IteratorFilter
to enable Iterator filtering
\Bakame\Csv\Iterator\IteratorSortBy
to enable Iterator sorting
\Bakame\Csv\Iterator\IteratorInterval
to enable setting Iterator intervals
Update Trait
\Bakame\Csv\Iterator\IteratorQuery
uses all the new Traits to enable CSV filtering
version 4.2.0
New Trait
\Bakame\Csv\ConverterTrait
to better deal with Csv conversion
New Method
\Bakame\Csv\AbstractCsv::toXML
which convert the Csv into aDomDocument
object
Method improved
\Bakame\Csv\AbstractCsv::toHTML
\Bakame\Csv\AbstractCsv::jsonSerialize
\Bakame\Csv\AbstractCsv::output
now can take a optional$filename
argument. When present the function will output all needed HTTP headers.\Bakame\Csv\AbstractCsv::getIterator
method improved\Bakame\Csv\Reader::fetchCol
method now default to$columnIndex
= 0\Bakame\Csv\Reader::fetchOne
method now default to$offset
= 0
version 4.1.2
- Adding PHP 5.6 test in travis.yml
- Dropping PSR-0 in favor of PSR-4