polem/departements

Simple french departments and areas library

0.0.11 2016-05-30 16:59 UTC

README

Installation

composer require polem/departements

Usage

use Departements\Datasource\JsonDatasource;
use Departements\Provider;

$file = __DIR__ . '/datas.json';
$datasource = new JsonDatasource($file);
$provider = new Provider($datasource);

// will return all departments
$provider->findAllDepartements();

// will return all departments
$provider->findAllRegions();