zfcampus/zf-console — pull request #8 by slaff (2014-06-18 09:09:15+00:00)
Title: Supplied useful filters

Suggested implementation for issue #6:

QueryString: to allow arguments such as --directives=session.save_handler=cluster&something=else, which would be parsed to the array ["session.save_handler" => "cluster", "something" => "else"]. PHP's parse_str() could be used for an initial implementation; however, it munges keys to valid PHP variable names, and thus a custom implementation should likely be used.

JSON: to allow arguments such as --directives='{"session.save_handler": "cluster", "something": "else"}', which would parse to the same value as in the QueryString example above.

Explode: to allow delimited arguments to be parsed to an array: --modules=foo,bar,baz would be come ['foo', 'bar', 'baz']. The delimiter would be a comma by default, but could be specified during instantiation (or, if using the FilterPluginManager, when requesting the filter).