config/Param: split block-specific attributes to new struct ConfigBlock
The old struct config_param remains only for top-level string options.
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
|
||||
#include "Compiler.h"
|
||||
|
||||
struct config_param;
|
||||
struct ConfigBlock;
|
||||
class InputStream;
|
||||
struct tag_handler;
|
||||
class Path;
|
||||
@@ -44,7 +44,7 @@ struct DecoderPlugin {
|
||||
* @return true if the plugin was initialized successfully,
|
||||
* false if the plugin is not available
|
||||
*/
|
||||
bool (*init)(const config_param ¶m);
|
||||
bool (*init)(const ConfigBlock &block);
|
||||
|
||||
/**
|
||||
* Deinitialize a decoder plugin which was initialized
|
||||
@@ -112,9 +112,9 @@ struct DecoderPlugin {
|
||||
* @return true if the plugin was initialized successfully, false if
|
||||
* the plugin is not available
|
||||
*/
|
||||
bool Init(const config_param ¶m) const {
|
||||
bool Init(const ConfigBlock &block) const {
|
||||
return init != nullptr
|
||||
? init(param)
|
||||
? init(block)
|
||||
: true;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user