You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You need to split the configs based on their dependencies:
You can always read the config/config.php
In order to read app and user values you need to first read the config/config.php
->
Keep IConfig as is and let it read all values but inject the class that is required to read and write the config/config.php into it so you can also set system values. getSystemValue and setSystemValue on the IConfig class just call through to the one that reads the config/config.php
The rest is code duplication. We might want to add those methods to the IConfig interface and then kill it, that is if those methods are actually used in our code
IMHO makes no sense to put the setting of app config values in one class and the deletion of values in another class :)
I moved all missing methods over to IConfig and deprecated IAppConfig with #13938 ;) The question here is if we want to do it in this way, or if we want the AppConfig be a separate interface, but then I would remove the methods from IConfig.
Separate interface makes only sense if we have the exact same signatures. That way we could keep backwards compatibility and let iconfig inherit from iappconfig.
Activity
BernhardPosselt commentedon Nov 18, 2014
You need to split the configs based on their dependencies:
->
@MorrisJobke
MorrisJobke commentedon Jan 28, 2015
see also stuff like #13736 and #13104
MorrisJobke commentedon Feb 3, 2015
Drop of OC_Preferences: #13869
MorrisJobke commentedon Feb 3, 2015
Drop of \OC\Preferences #13870
DeepDiver1975 commentedon Feb 16, 2015
While reviewing #13938 I really wonder if IAppConfig shall die ❓
It's an isolated and easy to use object.
BernhardPosselt commentedon Feb 16, 2015
Stuff that is only available in IAppConfig:
The rest is code duplication. We might want to add those methods to the IConfig interface and then kill it, that is if those methods are actually used in our code
MorrisJobke commentedon Feb 16, 2015
@Raydiation see #13938 ;)
MorrisJobke commentedon Feb 16, 2015
@DeepDiver1975 We can also handle it all in IAppConfig, but we shouldn't provide two ways of doing this. Either in IConfig OR in IAppConfig.
MorrisJobke commentedon Feb 16, 2015
The "or" is an exclusive one ;) Read it as an XOR ;)
BernhardPosselt commentedon Feb 16, 2015
IMHO makes no sense to put the setting of app config values in one class and the deletion of values in another class :)
MorrisJobke commentedon Feb 16, 2015
I moved all missing methods over to IConfig and deprecated IAppConfig with #13938 ;) The question here is if we want to do it in this way, or if we want the AppConfig be a separate interface, but then I would remove the methods from IConfig.
BernhardPosselt commentedon Feb 16, 2015
Separate interface makes only sense if we have the exact same signatures. That way we could keep backwards compatibility and let iconfig inherit from iappconfig.
MorrisJobke commentedon Jan 8, 2016
Latest cleanups went into 9.0 -> closing
lock commentedon Aug 7, 2019
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.