2017 © Pedro Peláez
 

library interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

image

data-values/interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  • Friday, March 16, 2018
  • by addshore
  • Repository
  • 12 Watchers
  • 3 Stars
  • 309,453 Installations
  • PHP
  • 13 Dependents
  • 0 Suggesters
  • 1 Forks
  • 1 Open issues
  • 16 Versions
  • 3 % Grown

The README.md

DataValues Interfaces

The design of this library is poor and its reason for existing is questionable. Most of the time you are likely better served by creating dedicated interfaces within your project., (*1)

DataValues Interfaces is a small PHP library that defines a set of interfaces for parsers, formatters and validators. It is part of the DataValues set of libraries., (*2)

Code Coverage Scrutinizer Quality Score, (*3)

On Packagist: Latest Stable Version Download count, (*4)

Installation

To use this library in your project, simply add a dependency on data-values/interfaces to your project's composer.json file. Here is a minimal example of a composer.json file that just defines a dependency on Interfaces 1.x:, (*5)

{
    "require": {
        "data-values/interfaces": "^1.0"
    }
}

Tests

This library comes with a set up PHPUnit tests that cover all non-trivial code. You can run these tests using the PHPUnit configuration file found in the root directory. The tests can also be run via Github Actions., (*6)

Release notes

1.1.0 (dev)

  • Introduced ParserOptions::withDefaultOption() and FormatterOptions::withDefaultOption(), which return a copy of the options with the default applied; the defaultOption() methods, which modify the options in place, are deprecated.

1.0.0 (2021-01-20)

  • Updated minimum required PHP version from 5.5.9 to 7.2
  • Removed ValueFormatterBase
  • Removed ValueFormatterTestBase
  • Removed ValueValidator::setOptions
  • Removed ValueValidatorObject
  • Removed DATAVALUES_INTERFACES_VERSION constant
  • ValueValidators\Result is now final
  • The properties of ValueValidators\Error are now private instead of protected

0.2.5 (2017-08-09)

  • Removed MediaWiki extension credits registration

0.2.4 (2017-08-02)

  • Fixed ValueFormatterTestBase not being installable via Composer.

0.2.3 (2017-08-02)

  • Updated minimal required PHP version from 5.3 to 5.5.9.
  • Minor fixes to code documentation.
  • Added PHPCS support.

0.2.2 (2016-07-15)

  • Fixed ValueFormatterTestBase not doing strict string comparisons.

0.2.1 (2016-01-13)

  • Fixed an issue when using this component with HHVM 1.11.0 (see #21).

0.2.0 (2015-08-11)

  • Dropped deprecated ErrorObject, use Error instead
  • Dropped deprecated ResultObject, use Result instead
  • Dropped deprecated constant DataValuesInterfaces_VERSION, use DATAVALUES_INTERFACES_VERSION instead
  • Dropped ValueFormatterTestBase::getFormatterClass
  • Made ValueFormatterTestBase::getInstance abstract
  • The options in ValueFormatterTestBase::getInstance are now optional

0.1.5 (2015-02-14)

  • The options in the ValueFormatterBase constructor are now optional
  • The MediaWiki extension registration now includes the license

0.1.4 (2014-04-14)

  • Added rawValue and expectedFormat arguments to ValueParsers\ParseException

0.1.3 (2014-03-31)

  • Added ValueFormatters\FormattingException

0.1.2 (2013-11-22)

  • Improved autoloading code
  • Fixed link in MediaWiki credits
  • Renamed entry point from DataValuesInterfaces.php to Interfaces.php

0.1.0 (2013-11-16)

Initial release with these features:, (*7)

  • ValueFormatters\ValueFormatter interface
  • ValueParsers\ValueParser interface
  • ValueValidators\ValueValidator interface

The Versions

16/03 2018

dev-master

9999999-dev https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+ GPL-2.0-or-later

The Requires

  • php >=5.5.9

 

The Development Requires

wikidata datavalues valueparsers valueformatters valuevalidators

28/09 2017

dev-upbootstrap

dev-upbootstrap https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.5.9

 

The Development Requires

wikidata datavalues valueparsers valueformatters valuevalidators

09/08 2017

0.2.5

0.2.5.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.5.9

 

The Development Requires

wikidata datavalues valueparsers valueformatters valuevalidators

02/08 2017

0.2.4

0.2.4.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.5.9

 

The Development Requires

wikidata datavalues valueparsers valueformatters valuevalidators

02/08 2017

0.2.3

0.2.3.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.5.9

 

The Development Requires

wikidata datavalues valueparsers valueformatters valuevalidators

15/05 2017

dev-php55

dev-php55 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.5.9

 

The Development Requires

wikidata datavalues valueparsers valueformatters valuevalidators

06/03 2017

dev-setOptions

dev-setOptions https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

The Development Requires

wikidata datavalues valueparsers valueformatters valuevalidators

15/07 2016

0.2.2

0.2.2.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

13/01 2016

0.2.1

0.2.1.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

11/08 2015

0.2.0

0.2.0.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

14/02 2015

0.1.5

0.1.5.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

14/04 2014

0.1.4

0.1.4.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

31/03 2014

0.1.3

0.1.3.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

22/11 2013

0.1.2

0.1.2.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

22/11 2013

0.1.1

0.1.1.0 https://github.com/DataValues/Interfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.3.0

 

wikidata datavalues valueparsers valueformatters valuevalidators

16/11 2013

0.1

0.1.0.0 https://github.com/JeroenDeDauw/DataValuesInterfaces

Defines interfaces for ValueParsers, ValueFormatters and ValueValidators

  Sources   Download

GPL-2.0+

The Requires

 

wikidata datavalues valueparsers valueformatters valuevalidators