@param mixed $item

@return string[]
346161
protected function getKeys($item)
    {
        if (is_array($item)) {
            return array_keys($item);
        } elseif ($this->header && is_object($item)) {
            return $this->header;
        }

        throw new InvalidArgumentException(sprintf(
            'Plum\PlumConsole\ConsoleTableWriter currently only supports array items or objects if headers '.
            'are set using the setHeader() method. You have passed an item of type "%s" to writeItem().',
            gettype($item)
        ));
    }
1216149
protected function getItemOrderOptions($item)
    {
        $result = array();
        if ($options = $item->getProductOptions()) {
            if (isset($options['options'])) {
                $result = array_merge($result, $options['options']);
            }
            if (isset($options['additional_options'])) {
                $result = array_merge($result, $options['additional_options']);
            }
            if (!empty($options['attributes_info'])) {
                $result = array_merge($options['attributes_info'], $result);
            }
        }
        return $result;
    }
200417
public static function get($item)
    {
        if (isset($_POST[$item])) {
            return $_POST[$item];
        } elseif (isset($_GET[$item])) {
            return $_GET[$item];
        } else {
            return '';
        }
    }
1242551
public function getDeleteUrlFor($item)
    {
        $params = array('id' => $item['id']);
        $params = array_merge($params, $this->getExtraParameters());

        return array(
            'path' => $this->getPathByConvention($this::SUFFIX_DELETE),
            'params' => $params,
        );
    }
1129519
public function get($item)
    {
        $key = $this->getItemKey($item);

        if (null !== $key) {
            if (isset($this->items[$key])) {
                $item = $this->items[$key];
            } else {
                $this->items[$key] = $item;
            }
        }

        return $item;
    }
274782
public function get($item)
    {
        $data = $this->getData();

        return empty($data->$item) ? null : $data->$item;
    }
321036
private function lookupRecursive($item)
    {
        if (is_array($item)) {
            $collection = [];
            foreach ($item as $k => $v) {
                $collection[$k] = $this->lookupRecursive($v);
            }

            return $collection;
        }

        return $this->lookup($item);
    }
393527
public static function extractValues($item, $key)
    {
        // Array of results
        $results = array();

        // Cast as array if object
        $item = is_object($item) ? (array) $item : $item;

        // Array of keys
        $keys = strstr($key, static::$key_split) ? explode(static::$key_split, $key) : array($key);
        $keys = array_filter($keys);

        // Key count
        $key_count = count($keys);

        // key count > 0
        if ($key_count > 0) {

                $curr_key = array_shift($keys);
                $arrayValues = array_values($item);
                $child = is_array($item) ? array_shift($arrayValues) : null;

                // it's an array
                if (is_array($item)) {
                    // Clean non-ASCII keys
                    foreach ($item as $k => $v) {
                        $sanitized = preg_replace('/[^(\x20-\x7F)]*/','', $k);
                        if ($sanitized !== $k) {
                            $item[$sanitized] = $v;
                            unset($item[$k]);
                        }
                    }

                    // it has the keys
                    if (array_key_exists($curr_key, $item)) {
                        $results = array_merge($results, static::extractValues($item[$curr_key], implode(static::$key_split, $keys)));
                    // else it's child has the key
                    } elseif ((is_array($child) || is_object($child))) {
                        if (array_key_exists($curr_key, $child)) {
                            foreach ($item as $child) {
                                $results = array_merge($results, static::extractValues($child, $key));
                            }
                        }
                    }
                }

        // no key
        } else {
            $results[] = $item;
        }
        return $results;
    }
948123
protected function getAllowedMethods($item) {
		$cls = get_class($item);
		$allowed = isset($this->allowedMethods[$cls]) ? $this->allowedMethods[$cls] : null;
		if (!$allowed) {
			$conf = Config::inst()->get(get_class($item), 'allowed_template_methods');
			if ($conf) {
				$allowed = $conf;
			} else {
				$methodsFromObject = function ($obj) {
					$cls = get_class($obj);
					$clazz = new ReflectionObject($obj);
					$declaredMethods = $clazz->getMethods(ReflectionMethod::IS_PUBLIC);
					$methods = array();
					foreach ($declaredMethods as $method) {
						/* @var $method  ReflectionMethod  */
						if ($method->class == $cls) {
							$methods[$method->getName()] = $method->getName();
						}
					}
					return $methods;
				};

				$allowed = $methodsFromObject($item);

				$extensions = $item->getExtensionInstances();
				foreach ($extensions as $ext) {
					$add = $methodsFromObject($ext);
					$allowed = array_merge($allowed, $add);
				}
			}
			$this->allowedMethods[$cls] = $allowed;
		}
		return $allowed;
	}
251766
public function parse(array $item): array
    {
        unset($item['permissions'], $item['groups']);
        $item['pending'] = true;

        $user = new User($item);

        $user->username = $item['email'];

        return [$user, $user->getErrors()];
    }
1074228
public function getItem($item)
	{
		return isset($this->items[$item]) ? $this->items[$item] : false;
	}
687004
private function _lookupRecursive($item)
        {
            if (Arrays::is($item)) {
                $collection = array();
                foreach ($item as $k => $v) {
                    $collection[$k] = $this->_lookupRecursive($v);
                }
                return $collection;
            } else {
                return $this->lookup($item);
            }
        }
1360284
public function renderItem($item)
    {
        $sectionItem   = array();
        $sectionItem[] = \CHtml::tag(
            'p',
            array('class' => 'title', 'data-section-title' => 'data-section-title'),
            \CHtml::link(ArrayHelper::getValue($item, 'label', 'Section Title'), '#')
        );
        $options       = ArrayHelper::getValue($item, 'options', array());
        Html::addCssClass($options, 'content');
        ArrayHelper::addValue('data-section-content', 'data-section-content', $options);
        $sectionOptions = array();
        if (ArrayHelper::getValue($item, 'active')) {
            ArrayHelper::addValue('class', 'active', $sectionOptions);
        }
        $sectionItem[] = \CHtml::tag('div', $options, ArrayHelper::getValue($item, 'content', 'Section Content'));
        return \CHtml::tag('section', $sectionOptions, implode("\n", $sectionItem));
    }
427484
protected function renderItemIcon($item)
    {
        $iconClass = ArrayHelper::getValue($item, 'icon');
        if ($iconClass !== null) {
            $class = [$this->iconClass];
            Html::addCssClass($class, $iconClass);
            return Html::tag('i', '', ['class' => $class]);
        } else {
            return '';
        }
    }
1011214
protected function validate(array $item)
    {
        $object = $this->objectFactory->factor($item);
        $list = $this->validator->validate($object);

        return $list;
    }
325896
public function __item($item = null)
    {
        $result['name'] = $this->getName();
        $result['content'] = '0';
        $result['active'] = is_null($item) ? true : $item['active'];
        $result['settings'] = Eresus_CMS::getLegacyKernel()->db->
            escape(is_null($item) ? encodeOptions($this->settings) : $item['settings']);
        $result['title'] = $this->title;
        $result['version'] = $this->version;
        $result['description'] = $this->description;
        return $result;
    }
229966
public function getPluginsThatCanFillItem(Item $item, $field)
    {
        $plugins = [];
        /* @var $plugin Refiller */
        foreach ($this->plugins as $plugin) {
            if ($plugin->isCanRefill($item, $field) || $plugin->isCanSearch($item, $field)) {
                $plugins[] = $plugin;
            }
        }

        return $plugins;
    }