From 95caad1ac699e356b424cc9151ce8c91e1cb6221 Mon Sep 17 00:00:00 2001 From: ewinslow Date: Tue, 1 Feb 2011 01:36:25 +0000 Subject: Refs #2839: moved deprecated functions from access.php - private_settings.php to deprecated.php. Still have to do relationships.php - xml.php. Deleted documentation for these functions since 1) it was using up precious bytes, and 2) documentation should not be needed since people should not be trying to use these if they are using 1.8, and 3) I assume the documentation will exist as archived 1.7 docs. git-svn-id: http://code.elgg.org/elgg/trunk@7975 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/private_settings.php | 163 ---------------------------------------- 1 file changed, 163 deletions(-) (limited to 'engine/lib/private_settings.php') diff --git a/engine/lib/private_settings.php b/engine/lib/private_settings.php index bf81e4a3a..77641e122 100644 --- a/engine/lib/private_settings.php +++ b/engine/lib/private_settings.php @@ -8,169 +8,6 @@ * @subpackage PrivateSettings */ -/** - * Get entities based on their private data. - * - * @param string $name The name of the setting - * @param string $value The value of the setting - * @param string $type The type of entity (eg "user", "object" etc) - * @param string $subtype The arbitrary subtype of the entity - * @param int $owner_guid The GUID of the owning user - * @param string $order_by The field to order by; by default, time_created desc - * @param int $limit The number of entities to return; 10 by default - * @param int $offset The indexing offset, 0 by default - * @param boolean $count Return a count of entities - * @param int $site_guid The site to get entities for. 0 for current, -1 for any - * @param mixed $container_guid The container(s) GUIDs - * - * @return array A list of entities. - * @deprecated 1.8 - */ -function get_entities_from_private_setting($name = "", $value = "", $type = "", $subtype = "", -$owner_guid = 0, $order_by = "", $limit = 10, $offset = 0, $count = false, $site_guid = 0, -$container_guid = null) { - elgg_deprecated_notice('get_entities_from_private_setting() was deprecated by elgg_get_entities_from_private_setting()!', 1.8); - - $options = array(); - - $options['private_setting_name'] = $name; - $options['private_setting_value'] = $value; - - // set container_guid to owner_guid to emulate old functionality - if ($owner_guid != "") { - if (is_null($container_guid)) { - $container_guid = $owner_guid; - } - } - - if ($type) { - $options['types'] = $type; - } - - if ($subtype) { - $options['subtypes'] = $subtype; - } - - if ($owner_guid) { - if (is_array($owner_guid)) { - $options['owner_guids'] = $owner_guid; - } else { - $options['owner_guid'] = $owner_guid; - } - } - - if ($container_guid) { - if (is_array($container_guid)) { - $options['container_guids'] = $container_guid; - } else { - $options['container_guid'] = $container_guid; - } - } - - $options['limit'] = $limit; - - if ($offset) { - $options['offset'] = $offset; - } - - if ($order_by) { - $options['order_by']; - } - - if ($site_guid) { - $options['site_guid']; - } - - if ($count) { - $options['count'] = $count; - } - - return elgg_get_entities_from_private_settings($options); -} - -/** - * Get entities based on their private data by multiple keys. - * - * @param string $name The name of the setting - * @param mixed $type Entity type - * @param string $subtype Entity subtype - * @param int $owner_guid The GUID of the owning user - * @param string $order_by The field to order by; by default, time_created desc - * @param int $limit The number of entities to return; 10 by default - * @param int $offset The indexing offset, 0 by default - * @param bool $count Count entities - * @param int $site_guid Site GUID. 0 for current, -1 for any. - * @param mixed $container_guid Container GUID - * - * @return array A list of entities. - * @deprecated 1.8 - */ -function get_entities_from_private_setting_multi(array $name, $type = "", $subtype = "", -$owner_guid = 0, $order_by = "", $limit = 10, $offset = 0, $count = false, -$site_guid = 0, $container_guid = null) { - - elgg_deprecated_notice('get_entities_from_private_setting_multi() was deprecated by elgg_get_entities_from_private_setting()!', 1.8); - - $options = array(); - - $pairs = array(); - foreach ($name as $setting_name => $setting_value) { - $pairs[] = array('name' => $setting_name, 'value' => $setting_value); - } - $options['private_setting_name_value_pairs'] = $pairs; - - // set container_guid to owner_guid to emulate old functionality - if ($owner_guid != "") { - if (is_null($container_guid)) { - $container_guid = $owner_guid; - } - } - - if ($type) { - $options['types'] = $type; - } - - if ($subtype) { - $options['subtypes'] = $subtype; - } - - if ($owner_guid) { - if (is_array($owner_guid)) { - $options['owner_guids'] = $owner_guid; - } else { - $options['owner_guid'] = $owner_guid; - } - } - - if ($container_guid) { - if (is_array($container_guid)) { - $options['container_guids'] = $container_guid; - } else { - $options['container_guid'] = $container_guid; - } - } - - $options['limit'] = $limit; - - if ($offset) { - $options['offset'] = $offset; - } - - if ($order_by) { - $options['order_by']; - } - - if ($site_guid) { - $options['site_guid']; - } - - if ($count) { - $options['count'] = $count; - } - - return elgg_get_entities_from_private_settings($options); -} - /** * Returns entities based upon private settings. Also accepts all * options available to elgg_get_entities(). Supports -- cgit v1.2.3