Download the PHP package code-foundation/flow-config without Composer
On this page you can find all versions of the php package code-foundation/flow-config. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download code-foundation/flow-config
More information about code-foundation/flow-config
Files in code-foundation/flow-config
Package flow-config
Short Description Cascading key/value configuration of preferences for platforms, installs, and users.
License MIT
Homepage https://github.com/code-foundation/flow-config
Informations about the package flow-config
Status
Introduction
Flow Config is a key value configuration platform built on top of doctrine. It provides an PHP API for setting configuration at the platform that can be set by an install, and then set for a user, or other entity. Defaults are set in a single location, rather than scattering them through the code.
Installation
Usage
Attach the EntityIdentifier interface to user classes
This allows EntityConfig classes to use the above
Build configuration classes
If you don't want the Config services to automatically flush changes to the database, pass a false for $autoFlush
in
the constructor of the service.
Control key access using the AccessControlInterface
In some cases, you may wish to control each specific attempt to get/set specific keys, and this is where implementing the AccessControlInterface is useful.
By default, the NullAccessControl
class is instantiated, which defaults to allowing all get
and set
attempts.
By implementing the interface, you have control over allowing or denying get and set access to keys based on the key itself, or optionally the entity associated with the key, or one of its method values.
Examples
Supported platforms
- PHP 7.3+
- Doctrine
- Symfony - https://github.com/code-foundation/flow-config-symfony
Future plans
- Validation
- Allowed values
- Factories
- Eloquent backend
Contact
Github: https://github.com/code-foundation/flow-config Email: [email protected]
License
Flow Config is distributed under the MIT license.