2017 © Pedro Peláez
 

library sports-open-data-response-parser

Allows to map responses provided by the Sports Open Data API.

image

astronati/sports-open-data-response-parser

Allows to map responses provided by the Sports Open Data API.

  • Wednesday, May 9, 2018
  • by Andrea Stronati
  • Repository
  • 1 Watchers
  • 0 Stars
  • 317 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 8 Versions
  • 19 % Grown

The README.md

Build Status Codacy Badge Codacy Badge Latest Stable Version License, (*1)

Sports Open Data Response Parser

Allows to map responses provided by the Sports Open Data API., (*2)

Supported Responses

Not all responses are currently supported but we are happy to work for you if you need some of them., (*3)

NOTE: To add another response into the supported list, please file a new issue., (*4)

To do that please file a new issue., (*5)

Installation

You can install the library and its dependencies using composer running:, (*6)

$ composer require astronati/sports-open-data-response-parser

Usage

The library allows to return a model per each response and its content (season, round, match, etc...)., (*7)

Example

The following snippet can be helpful:, (*8)

use SODRP\Response\ResponseParser;
...
// Obtain a Response
$apiResponse = ... // Save this the response from the Sports Open Data API
$response = ResponseParser::create($apiResponse, ResponseParser::GET_SEASONS_AVAILABLE);
...
// Get 2017-2018 season
$season = $response->findOneBySlug('17-18');
echo $season->getStartDate(); // 2017-07-01...

For more details please take a look at Response., (*9)

Development

The environment requires phpunit, that has been already included in the dev-dependencies of the composer.json., (*10)

Dependencies

To install all modules you just need to run following command:, (*11)

$ composer install

Testing

Tests files are created in dedicates folders that replicate the src structure as follows:, (*12)

.
+-- src
|   +-- [folder-name]
|   |   +-- [file-name].php
|   ...
+-- tests
|   +-- [folder-name]
|   |   +-- [file-name]Test.php

Execute following command to run the tests suite:, (*13)

$ composer test

Run what follows to see the code coverage:, (*14)

$ composer coverage

License

This package is released under the MIT license., (*15)

The Versions

09/05 2018

dev-master

9999999-dev

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati

09/05 2018

1.1.1

1.1.1.0

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati

09/05 2018

dev-issues/13

dev-issues/13

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati

08/05 2018

1.1.0

1.1.0.0

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati

29/03 2018

dev-issues/9

dev-issues/9

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati

21/03 2018

1.0.0

1.0.0.0

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati

15/02 2018

0.2.0

0.2.0.0

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati

14/02 2018

0.1.0

0.1.0.0

Allows to map responses provided by the Sports Open Data API.

  Sources   Download

MIT

The Requires

  • php >=7.1.0

 

The Development Requires

by Avatar Andrea Stronati