Most common interfaces I use in apps. Mostly for teaching OOP.
You can use this library in your app to create your classes designed by contract.
After you go into the app directory, you should execute following commands. OS X & Linux:
composer require midorikocak/interfaces
You should use the interfaces, and your class should implement the interface you want to use. An interface has only public methods. I use php 7 in this lib, so that all methods should have exact parameter and return types, defined in the interfaces.
To run all tests of the app, execute these commands in the app directory.
composer install phpunit
- Work in progress
- packagist auto update
- better interface organization
- tests are not finished yet
Distributed under the MIT license. See
LICENSE for more information.