Skip to content

Commit

Permalink
Merge pull request #17 from thephpleague/update-namespace
Browse files Browse the repository at this point in the history
Update namespace
  • Loading branch information
nyamsprod committed Feb 28, 2014
2 parents 4f1ed58 + ef58410 commit f895356
Show file tree
Hide file tree
Showing 26 changed files with 97 additions and 94 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Contributions are **welcome** and will be fully **credited**.

We accept contributions via Pull Requests on [Github](https://github.com/nyamsprod/Bakame.url).
We accept contributions via Pull Requests on [Github](https://github.com/theleague/csv).


## Pull Requests
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ This package is compliant with [PSR-1], [PSR-2], and [PSR-4].
System Requirements
-------

You need **PHP >= 5.4.0** and the `mbstring` extension to use `Bakame\Csv` but the latest stable version of PHP is recommended.
You need **PHP >= 5.4.0** and the `mbstring` extension to use `League\Csv` but the latest stable version of PHP is recommended.

Install
-------
Expand Down Expand Up @@ -54,8 +54,8 @@ Usage
* If you have your LC_CTYPE set to a locale that's using UTF-8 and you try to parse a file that's not in UTF-8, PHP will cut your fields the moment it encounters a byte it can't understand (i.e. any outside of ASCII that doesn't happen to be part of a UTF-8 character which it likely isn't). [This gist will show you a possible solution](https://gist.github.com/pilif/9137146) to this problem by using [PHP stream filter](http://www.php.net/manual/en/stream.filters.php). This tip is from [Philip Hofstetter](https://github.com/pilif)

* When merging multiples CSV documents don't forget to set the main CSV object
as a `Bakame\Csv\Writer` object with the `$open_mode = 'a+'` to preserve its content.
This setting is of course not required when your main `Bakame\Csv\Writer` object is
as a `League\Csv\Writer` object with the `$open_mode = 'a+'` to preserve its content.
This setting is of course not required when your main `League\Csv\Writer` object is
created from String

* **If you are on a Mac OS X Server**, add the following lines before using the library to help [PHP detect line ending in Mac OS X](http://php.net/manual/en/function.fgetcsv.php#refsect1-function.fgetcsv-returnvalues).
Expand All @@ -69,7 +69,7 @@ if (! ini_get("auto_detect_line_endings")) {
Documentation
-------------

Fractal has [full documentation](http://csv.thephpleague.com), powered by [Sculpin](https://sculpin.io).
Csv has [full documentation](http://csv.thephpleague.com), powered by [Sculpin](https://sculpin.io).

Contribute to this documentation in the [sculpin branch](https://github.com/thephpleague/csv/tree/sculpin/source).

Expand Down
9 changes: 6 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "bakame/csv",
"name": "league/csv",
"type": "library",
"description" : "Csv data manipulation made easy in PHP 5.4+",
"keywords": ["csv", "import", "export", "read", "write", "filter"],
Expand All @@ -18,8 +18,11 @@
},
"autoload": {
"psr-4": {
"Bakame\\Csv\\": "src",
"Bakame\\CSv\\": "test"
"League\\Csv\\": "src",
"League\\CSv\\": "test"
}
},
"replaces": {
"bakame/csv": "*"
}
}
2 changes: 1 addition & 1 deletion examples/download.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

use Bakame\Csv\Reader;
use League\Csv\Reader;

require '../vendor/autoload.php';

Expand Down
6 changes: 3 additions & 3 deletions examples/extract.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

use Bakame\Csv\Reader;
use League\Csv\Reader;

require '../vendor/autoload.php';

Expand All @@ -18,11 +18,11 @@
<html lang="fr">
<head>
<meta charset="<?=$inputCsv->getEncoding()?>">
<title>\Bakame\Csv\Reader simple usage</title>
<title>\League\Csv\Reader simple usage</title>
<link rel="stylesheet" href="example.css">
</head>
<body>
<h1>\Bakame\Csv\Reader simple usage</h1>
<h1>\League\Csv\Reader simple usage</h1>
<table class="table-csv-data">
<caption>Part of the CSV from the 801th row with at most 25 rows</caption>
<thead>
Expand Down
6 changes: 3 additions & 3 deletions examples/filtering.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

use Bakame\Csv\Reader;
use League\Csv\Reader;

require '../vendor/autoload.php';

Expand Down Expand Up @@ -36,11 +36,11 @@
<html lang="fr">
<head>
<meta charset="<?=$inputCsv->getEncoding()?>">
<title>\Bakame\Csv\Reader filtering method</title>
<title>\League\Csv\Reader filtering method</title>
<link rel="stylesheet" href="example.css">
</head>
<body>
<h1>Using the Bakame\Csv\Reader class filtering capabilities</h1>
<h1>Using the League\Csv\Reader class filtering capabilities</h1>
<table class="table-csv-data">
<caption>Statistics for the 20 least used female name in the year 2010</caption>
<thead>
Expand Down
2 changes: 1 addition & 1 deletion examples/json.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

use Bakame\Csv\Reader;
use League\Csv\Reader;

require '../vendor/autoload.php';

Expand Down
10 changes: 5 additions & 5 deletions examples/merge.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

use Bakame\Csv\Writer;
use Bakame\Csv\Reader;
use League\Csv\Writer;
use League\Csv\Reader;

require '../vendor/autoload.php';

Expand Down Expand Up @@ -42,7 +42,7 @@

/*
When merging multiples CSV documents don't forget to set the main CSV object
as a `Bakame\Csv\Writer` object with the $open_mode = 'a+' to preserve its content.
as a `League\Csv\Writer` object with the $open_mode = 'a+' to preserve its content.
This setting is of course not required when your main CSV object is created from String
*/

Expand All @@ -55,7 +55,7 @@
<link rel="stylesheet" href="example.css">
</head>
<body>
<h1>Using the Bakame\Csv\Writer class to merge two CSV documents</h1>
<h1>Using the League\Csv\Writer class to merge two CSV documents</h1>
<h3>The main Raw CSV</h3>
<p><em>The delimiter is a ";"</em></p>
<pre>
Expand All @@ -74,7 +74,7 @@
</pre>
<h3>Tips</h3>
<p> When merging multiples CSV documents don't forget to set the main CSV object
as a <code>Bakame\Csv\Writer</code> object with the <code>$open_mode = 'a+'</code>
as a <code>League\Csv\Writer</code> object with the <code>$open_mode = 'a+'</code>
to preserve its content. This setting is of course not required when your main CSV object
is created from String</p>
</body>
Expand Down
6 changes: 3 additions & 3 deletions examples/switchmode.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

use Bakame\Csv\Writer;
use League\Csv\Writer;

require '../vendor/autoload.php';

Expand Down Expand Up @@ -56,11 +56,11 @@
<html lang="fr">
<head>
<meta charset="utf-8">
<title>Bakame\Csv\Writer and Bakame\Csv\Reader switching mode</title>
<title>League\Csv\Writer and League\Csv\Reader switching mode</title>
<link rel="stylesheet" href="example.css">
</head>
<body>
<h1>Using createFromString method and converting the Bakame\Csv\Writer into a Bakame\Csv\Reader</h1>
<h1>Using createFromString method and converting the League\Csv\Writer into a League\Csv\Reader</h1>
<h3>The table representation of the csv to be save</h3>
<?=$writer->toHTML();?>
<h3>The Raw CSV as it will be saved</h3>
Expand Down
2 changes: 1 addition & 1 deletion examples/table.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

use Bakame\Csv\Reader;
use League\Csv\Reader;

require '../vendor/autoload.php';

Expand Down
4 changes: 2 additions & 2 deletions examples/writing.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

use Bakame\Csv\Writer;
use League\Csv\Writer;

require '../vendor/autoload.php';

Expand All @@ -27,7 +27,7 @@
<html lang="fr">
<head>
<meta charset="<?=$writer->getEncoding()?>">
<title>Using the \Bakame\Writer object</title>
<title>Using the \League\Writer object</title>
<link rel="stylesheet" href="example.css">
</head>
<body>
Expand Down
2 changes: 1 addition & 1 deletion examples/xml.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
error_reporting(-1);
ini_set('display_errors', 1);

use Bakame\Csv\Reader;
use League\Csv\Reader;

require '../vendor/autoload.php';

Expand Down
2 changes: 1 addition & 1 deletion phpunit.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
stopOnFailure="false">

<testsuites>
<testsuite name="Bakame CSV Test Suite">
<testsuite name="League CSV Test Suite">
<directory>test</directory>
</testsuite>
</testsuites>
Expand Down
12 changes: 6 additions & 6 deletions src/AbstractCsv.php
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?php
/**
* Bakame.csv - A lightweight CSV Coder/Decoder library
* League.csv - A lightweight CSV Coder/Decoder library
*
* @author Ignace Nyamagana Butera <[email protected]>
* @copyright 2014 Ignace Nyamagana Butera
* @link https://github.com/nyamsprod/Bakame.csv
* @link https://github.com/nyamsprod/League.csv
* @license http://opensource.org/licenses/MIT
* @version 4.2.1
* @package Bakame.csv
* @version 5.0.0
* @package League.csv
*
* MIT LICENSE
*
Expand All @@ -30,7 +30,7 @@
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
namespace Bakame\Csv;
namespace League\Csv;

use IteratorAggregate;
use JsonSerializable;
Expand All @@ -43,7 +43,7 @@
/**
* A abstract class to enable basic CSV manipulation
*
* @package Bakame.csv
* @package League.csv
* @since 4.0.0
*
*/
Expand Down
14 changes: 7 additions & 7 deletions src/ConverterTrait.php
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?php
/**
* Bakame.csv - A lightweight CSV Coder/Decoder library
* League.csv - A lightweight CSV Coder/Decoder library
*
* @author Ignace Nyamagana Butera <[email protected]>
* @copyright 2014 Ignace Nyamagana Butera
* @link https://github.com/nyamsprod/Bakame.csv
* @link https://github.com/nyamsprod/League.csv
* @license http://opensource.org/licenses/MIT
* @version 4.2.1
* @package Bakame.csv
* @version 5.0.0
* @package League.csv
*
* MIT LICENSE
*
Expand All @@ -30,16 +30,16 @@
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
namespace Bakame\Csv;
namespace League\Csv;

use DomDocument;
use SplTempFileObject;
use Bakame\Csv\Iterator\MapIterator;
use League\Csv\Iterator\MapIterator;

/**
* A abstract class to enable basic CSV manipulation
*
* @package Bakame.csv
* @package League.csv
* @since 4.2.0
*
*/
Expand Down
12 changes: 6 additions & 6 deletions src/Iterator/IteratorFilter.php
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?php
/**
* Bakame.csv - A lightweight CSV Coder/Decoder library
* League.csv - A lightweight CSV Coder/Decoder library
*
* @author Ignace Nyamagana Butera <[email protected]>
* @copyright 2014 Ignace Nyamagana Butera
* @link https://github.com/nyamsprod/Bakame.csv
* @link https://github.com/nyamsprod/League.csv
* @license http://opensource.org/licenses/MIT
* @version 4.2.1
* @package Bakame.csv
* @version 5.0.0
* @package League.csv
*
* MIT LICENSE
*
Expand All @@ -30,15 +30,15 @@
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
namespace Bakame\Csv\Iterator;
namespace League\Csv\Iterator;

use CallbackFilterIterator;
use Iterator;

/**
* A Trait to filter Iterators
*
* @package Bakame.csv
* @package League.csv
* @since 4.2.1
*
*/
Expand Down
12 changes: 6 additions & 6 deletions src/Iterator/IteratorInterval.php
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?php
/**
* Bakame.csv - A lightweight CSV Coder/Decoder library
* League.csv - A lightweight CSV Coder/Decoder library
*
* @author Ignace Nyamagana Butera <[email protected]>
* @copyright 2014 Ignace Nyamagana Butera
* @link https://github.com/nyamsprod/Bakame.csv
* @link https://github.com/nyamsprod/League.csv
* @license http://opensource.org/licenses/MIT
* @version 4.2.1
* @package Bakame.csv
* @version 5.0.0
* @package League.csv
*
* MIT LICENSE
*
Expand All @@ -30,7 +30,7 @@
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
namespace Bakame\Csv\Iterator;
namespace League\Csv\Iterator;

use InvalidArgumentException;
use Iterator;
Expand All @@ -39,7 +39,7 @@
/**
* A Trait to Set a LimitIterator object
*
* @package Bakame.csv
* @package League.csv
* @since 4.2.1
*
*/
Expand Down
Loading

0 comments on commit f895356

Please sign in to comment.