AllConfig¶
- 
class OC\AllConfig¶
- Class to combine all the configuration options ownCloud offersSource: lib/private/AllConfig.php#43 Implements: OCP\IConfig
Properties¶
Methods¶
- 
public OC\AllConfig::__construct($systemConfig)¶
- Source: - Parameters: - $systemConfig (OC\SystemConfig)
 
- $systemConfig (
- 
public OC\AllConfig::setSystemValues($configs)¶
- Sets and deletes system wide valuesSource: Parameters: - $configs (array) Associative array with key => value pairs
 If value is null, the config key will be deleted 
- 
public OC\AllConfig::setSystemValue($key, $value)¶
- Sets a new system wide valueSource: Parameters: - $key (string) the key of the value, under which will be saved
- $value (mixed) the value that should be stored
 
- 
public OC\AllConfig::getSystemValue($key, $default="")¶
- Looks up a system wide defined valueSource: Parameters: - $key (string) the key of the value, under which it was saved
- $default (mixed) the default value to be returned if the value isn’t set
 Returns: mixed the value or $default 
- 
public OC\AllConfig::getSystemValueBool($key, $default=false)¶
- Looks up a boolean system wide defined valueSource: Parameters: - $key (string) the key of the value, under which it was saved
- $default (bool) the default value to be returned if the value isn’t set
 Returns: bool Since: 16.0.0 
- 
public OC\AllConfig::getSystemValueInt($key, $default=0)¶
- Looks up an integer system wide defined valueSource: Parameters: - $key (string) the key of the value, under which it was saved
- $default (int) the default value to be returned if the value isn’t set
 Returns: int Since: 16.0.0 
- 
public OC\AllConfig::getSystemValueString($key, $default="")¶
- Looks up a string system wide defined valueSource: Parameters: - $key (string) the key of the value, under which it was saved
- $default (string) the default value to be returned if the value isn’t set
 Returns: string Since: 16.0.0 
- 
public OC\AllConfig::getFilteredSystemValue($key, $default="")¶
- Looks up a system wide defined value and filters out sensitive dataSource: Parameters: - $key (string) the key of the value, under which it was saved
- $default (mixed) the default value to be returned if the value isn’t set
 Returns: mixed the value or $default 
- 
public OC\AllConfig::deleteSystemValue($key)¶
- Delete a system wide defined valueSource: Parameters: - $key (string) the key of the value, under which it was saved
 
- 
public OC\AllConfig::getAppKeys($appName)¶
- Get all keys stored for an appSource: Parameters: - $appName (string) the appName that we stored the value under
 Returns: string[] the keys stored for the app 
- 
public OC\AllConfig::setAppValue($appName, $key, $value)¶
- Writes a new app wide valueSource: Parameters: - $appName (string) the appName that we want to store the value under
- $key (string) the key of the value, under which will be saved
- $value (string | float | int) the value that should be stored
 
- 
public OC\AllConfig::getAppValue($appName, $key, $default="")¶
- Looks up an app wide defined valueSource: Parameters: - $appName (string) the appName that we stored the value under
- $key (string) the key of the value, under which it was saved
- $default (string) the default value to be returned if the value isn’t set
 Returns: string the saved value 
- 
public OC\AllConfig::deleteAppValue($appName, $key)¶
- Delete an app wide defined valueSource: Parameters: - $appName (string) the appName that we stored the value under
- $key (string) the key of the value, under which it was saved
 
- 
public OC\AllConfig::deleteAppValues($appName)¶
- Removes all keys in appconfig belonging to the appSource: Parameters: - $appName (string) the appName the configs are stored under
 
- 
public OC\AllConfig::setUserValue($userId, $appName, $key, $value, $preCondition=null)¶
- Set a user defined valueSource: Parameters: - $userId (string) the userId of the user that we want to store the value under
- $appName (string) the appName that we want to store the value under
- $key (string) the key under which the value is being stored
- $value (string | float | int) the value that you want to store
- $preCondition (string) only update if the config value was previously the value passed as $preCondition
 Throws: \OCP\PreConditionNotMetExceptionif a precondition is specified and is not metThrows: \UnexpectedValueExceptionwhen trying to store an unexpected valueThrows: \OCP\PreConditionNotMetExceptionif a precondition is specified and is not metThrows: \UnexpectedValueExceptionwhen trying to store an unexpected value
- 
public OC\AllConfig::getUserValue($userId, $appName, $key, $default="")¶
- Getting a user defined valueSource: Parameters: - $userId (string) the userId of the user that we want to store the value under
- $appName (string) the appName that we stored the value under
- $key (string) the key under which the value is being stored
- $default (mixed) the default value to be returned if the value isn’t set
 Returns: string 
- 
public OC\AllConfig::getUserKeys($userId, $appName)¶
- Get the keys of all stored by an app for the userSource: Parameters: - $userId (string) the userId of the user that we want to store the value under
- $appName (string) the appName that we stored the value under
 Returns: string[] 
- 
public OC\AllConfig::deleteUserValue($userId, $appName, $key)¶
- Delete a user valueSource: Parameters: - $userId (string) the userId of the user that we want to store the value under
- $appName (string) the appName that we stored the value under
- $key (string) the key under which the value is being stored
 
- 
public OC\AllConfig::deleteAllUserValues($userId)¶
- Delete all user valuesSource: Parameters: - $userId (string) the userId of the user that we want to remove all values from
 
- 
public OC\AllConfig::deleteAppFromAllUsers($appName)¶
- Delete all user related values of one appSource: Parameters: - $appName (string) the appName of the app that we want to remove all values from
 
- 
public OC\AllConfig::getUserValueForUsers($appName, $key, $userIds)¶
- Fetches a mapped list of userId -> value, for a specified app and key and a list of user IDs.Source: Parameters: - $appName (string) app to get the value for
- $key (string) the key to get the value for
- $userIds (array) the user IDs to fetch the values for
 Returns: array Mapped values: userId => value 
- 
public OC\AllConfig::getUsersForUserValue($appName, $key, $value)¶
- Determines the users that have the given value set for a specific app-key-pairSource: Parameters: - $appName (string) the app to get the user for
- $key (string) the key to get the user for
- $value (string) the value to get the user for
 Returns: array of user IDs 
- 
public OC\AllConfig::getUsersForUserValueCaseInsensitive($appName, $key, $value)¶
- Determines the users that have the given value set for a specific app-key-pairSource: Parameters: - $appName (string) the app to get the user for
- $key (string) the key to get the user for
- $value (string) the value to get the user for
 Returns: array of user IDs 
- 
public OC\AllConfig::getSystemConfig()¶
- Source: - lib/private/AllConfig.php#538