|
Open Monograph Press
3.3.0
|
Public Member Functions | |
| _buildObject ($node, $paramArray=array()) | |
| _cacheMiss ($cache, $id) | |
| _getCache ($contextId, $pluginName) | |
| _performReplacement ($rawInput, $paramArray=array()) | |
| deleteByContextId ($contextId) | |
| deleteSetting ($contextId, $pluginName, $name) | |
| deleteSettingsByPlugin ($contextId, $pluginName) | |
| getPluginSettings ($contextId, $pluginName) | |
| getSetting ($contextId, $pluginName, $name) | |
| installSettings ($contextId, $pluginName, $filename, $paramArray=array()) | |
| settingExists ($contextId, $pluginName, $name) | |
| updateSetting ($contextId, $pluginName, $name, $value, $type=null) | |
Public Member Functions inherited from DAO | |
| __construct ($dataSource=null, $callHooks=true) | |
| concat () | |
| convertFromDB ($value, $type) | |
| convertToDB ($value, &$type) | |
| dateFromDB ($d) | |
| datetimeFromDB ($dt) | |
| datetimeToDB ($dt) | |
| dateToDB ($d) | |
| flushCache () | |
| formatDateToDB ($date, $defaultNumWeeks=null, $acceptPastDate=true) | |
| getAdditionalFieldNames () | |
| getAffectedRows () | |
| getDataObjectSettings ($tableName, $idFieldName, $idFieldValue, $dataObject) | |
| getDataSource () | |
| getDirectionMapping ($direction) | |
| getDriver () | |
| getLocaleFieldNames () | |
| getType ($value) | |
| handleError ($dataSource, $sql) | |
| nullOrInt ($value) | |
| replace ($table, $arrFields, $keyCols) | |
| & | retrieve ($sql, $params=false, $callHooks=true) |
| & | retrieveCached ($sql, $params=false, $secsToCache=3600, $callHooks=true) |
| & | retrieveLimit ($sql, $params=false, $numRows=false, $offset=false, $callHooks=true) |
| & | retrieveRange ($sql, $params=false, $dbResultRange=null, $callHooks=true) |
| setCacheDir () | |
| setDataSource ($dataSource) | |
| update ($sql, $params=false, $callHooks=true, $dieOnError=true) | |
| updateDataObjectSettings ($tableName, $dataObject, $idArray) | |
Additional Inherited Members | |
Static Public Member Functions inherited from DAO | |
| static | getDataChangedEvent ($elementId=null, $parentElementId=null, $content='') |
Data Fields inherited from DAO | |
| $_dataSource | |
Protected Member Functions inherited from DAO | |
| _getInsertId ($table='', $id='') | |
Operations for retrieving and modifying plugin settings.
Definition at line 17 of file PluginSettingsDAO.inc.php.
| PluginSettingsDAO::_buildObject | ( | $node, | |
$paramArray = array() |
|||
| ) |
Used internally by installSettings to recursively build nested arrays. Deals with translation and variable replacement calls.
| $node | object XMLNode <array> tag |
| $paramArray | array Parameters to be replaced in key/value contents |
Definition at line 221 of file PluginSettingsDAO.inc.php.
References _performReplacement().
Referenced by installSettings().
| PluginSettingsDAO::_cacheMiss | ( | $cache, | |
| $id | |||
| ) |
Callback for a cache miss.
| $cache | Cache object |
| $id | string Identifier to look up in cache |
Definition at line 83 of file PluginSettingsDAO.inc.php.
References getPluginSettings().
| PluginSettingsDAO::_getCache | ( | $contextId, | |
| $pluginName | |||
| ) |
Get the cache for plugin settings.
Definition at line 25 of file PluginSettingsDAO.inc.php.
References CacheManager\getManager().
Referenced by deleteSetting(), deleteSettingsByPlugin(), getPluginSettings(), getSetting(), and updateSetting().
| PluginSettingsDAO::_performReplacement | ( | $rawInput, | |
$paramArray = array() |
|||
| ) |
Used internally by installSettings to perform variable and translation replacements.
| $rawInput | string contains text including variable and/or translate replacements. |
| $paramArray | array contains variables for replacement |
Definition at line 207 of file PluginSettingsDAO.inc.php.
Referenced by _buildObject(), and installSettings().
| PluginSettingsDAO::deleteByContextId | ( | $contextId | ) |
Delete all settings for a context.
| $contextId | int |
Definition at line 195 of file PluginSettingsDAO.inc.php.
References DAO\update().
| PluginSettingsDAO::deleteSetting | ( | $contextId, | |
| $pluginName, | |||
| $name | |||
| ) |
Delete a plugin setting.
| $contextId | int |
| $pluginName | int |
| $name | string |
Definition at line 160 of file PluginSettingsDAO.inc.php.
References _getCache(), strtolower_codesafe(), and DAO\update().
| PluginSettingsDAO::deleteSettingsByPlugin | ( | $contextId, | |
| $pluginName | |||
| ) |
Delete all settings for a plugin.
| $contextId | int |
| $pluginName | string |
Definition at line 178 of file PluginSettingsDAO.inc.php.
References _getCache(), strtolower_codesafe(), and DAO\update().
| PluginSettingsDAO::getPluginSettings | ( | $contextId, | |
| $pluginName | |||
| ) |
Retrieve and cache all settings for a plugin.
Definition at line 101 of file PluginSettingsDAO.inc.php.
References _getCache(), DAO\convertFromDB(), DAO\retrieve(), and strtolower_codesafe().
Referenced by _cacheMiss(), and installSettings().
| PluginSettingsDAO::getSetting | ( | $contextId, | |
| $pluginName, | |||
| $name | |||
| ) |
Retrieve a plugin setting value.
Definition at line 51 of file PluginSettingsDAO.inc.php.
References _getCache(), and strtolower_codesafe().
| PluginSettingsDAO::installSettings | ( | $contextId, | |
| $pluginName, | |||
| $filename, | |||
$paramArray = array() |
|||
| ) |
Install plugin settings from an XML file.
| $pluginName | name of plugin for settings to apply to |
| $filename | string Name of XML file to parse and install |
| $paramArray | array Optional parameters for variable replacement in settings |
Definition at line 245 of file PluginSettingsDAO.inc.php.
References _buildObject(), _performReplacement(), getPluginSettings(), and updateSetting().
| PluginSettingsDAO::settingExists | ( | $contextId, | |
| $pluginName, | |||
| $name | |||
| ) |
Does the plugin setting exist.
Definition at line 67 of file PluginSettingsDAO.inc.php.
References DAO\retrieve(), and strtolower_codesafe().
| PluginSettingsDAO::updateSetting | ( | $contextId, | |
| $pluginName, | |||
| $name, | |||
| $value, | |||
$type = null |
|||
| ) |
Add/update a plugin setting.
| $contextId | int Context ID |
| $pluginName | string Symbolic plugin name |
| $name | string Setting name |
| $value | mixed Setting value |
| $type | string data type of the setting. If omitted, type will be guessed |
Definition at line 132 of file PluginSettingsDAO.inc.php.
References _getCache(), DAO\convertToDB(), DAO\replace(), and strtolower_codesafe().
Referenced by installSettings().