Get item name

@param array $item

@return string
195708
public function getItemName(array $item)
    {
        if ($this->locale == 'ru' && $item['russian']) {
            return $item['russian'];
        }
        if ($this->locale == 'ja' && $item['japanese']) {
            return $item['japanese'][0];
        }
        if ($this->locale == 'en' && $item['english']) {
            return $item['english'][0];
        }
        return $item['name'];
    }
200417
public static function get($item)
    {
        if (isset($_POST[$item])) {
            return $_POST[$item];
        } elseif (isset($_GET[$item])) {
            return $_GET[$item];
        } else {
            return '';
        }
    }
1235651
public function prepare($item)
    {
        $prepared = array();

        foreach($item as $key => $value) {
            //if it's null
            if($value === null) {
                //set it and continue
                $prepared[$key] = null;
                continue;
            }

            //if is array
            if(is_array($value)) {
                //recursive
                $prepared[$key] = $this->prepare($value);
                continue;
            }

            //if it can be converted
            if(is_scalar($value)) {
                $prepared[$key] = (string) $value;
                continue;
            }

            //we tried our best ...
            $prepared[$key] = $value;
        }

        return $prepared;
    }
383569
public function getIndex( $item )
	{
		$index	= array_search( $item, $this->list );
		if( $index === FALSE )
			throw new DomainException( 'Item "'.$item.'" is not in List.' );
		return $index;
	}
314056
protected function getFeeLine($item)
    {
        $quantity = $item->get_quantity();
        $feeEx = $item->get_total() / $quantity;
        $feeVat = $item->get_total_tax() / $quantity;

        $result = array(
                Tag::Product => $this->t($item->get_name()),
                Tag::UnitPrice => $feeEx,
                Tag::Quantity => $item->get_quantity(),
            ) + $this->getVatRangeTags($feeVat, $feeEx, $this->precision, $this->precision);

        return $result;
    }
509880
protected function getArrayItemsSeparator($item)
    {
        $cfg = $this->file->getRequire($this->configFile);

        if (!$cfg) {
            return $this->defaultSeparator;
        }

        $file = $this->getFileContents();

        $arr = array_get($cfg, $item);

        $lastItem = end($arr);
        $preLastItem = prev($arr);

        if (!$lastItem or !$preLastItem) {
            return $this->defaultSeparator;
        }

        preg_match('/\,/', $file, $matchStart, PREG_OFFSET_CAPTURE, strpos($file, $preLastItem));
        $start = array_get(reset($matchStart), 1);

        $searchEnd = preg_match('/[\'"]/', $file, $matchEnd, PREG_OFFSET_CAPTURE, $start);
        $end = array_get(reset($matchEnd), 1);

        $separator = substr($file, $start, $end - $start);

        // remove comments
        $separator = preg_replace('/\/\/.*/ui', '', $separator);
        $separator = preg_replace('/#.*/ui', '', $separator);
        $separator = preg_replace('/\/\*(.*)\*\//ui', '', $separator);

        return $separator;
    }
404219
public function getItemAction(Item $item) {
        // TODO : Check if requesting user has access to the corresponding meeting container

        $view = $this->view($item, Response::HTTP_OK);

        return $this->handleView($view);
    }
761157
private function resolveRouteToLink(array $item)
    {
        $param = !empty($item['param']) ? $item['param'] : [];

        if (isset($item['add'])) {
            Deprecated::warn('Menu item property "add"', null, 'Use "#" under "param" instead.');

            $add = $item['add'];
            if (!empty($add) && $add[0] !== '?') {
                $add = '?' . $add;
            }

            parse_str(parse_url($add, PHP_URL_QUERY), $query);
            $param = array_merge($param, $query);
            $param['_fragment'] = parse_url($add, PHP_URL_FRAGMENT);
        }

        return $this->app['url_generator']->generate($item['route'], $param);
    }
1236317
private function getUsage($item)
    {
        return $this->getCacheItem(self::CACHE_USAGE, $item, function () {
            return $this->getContext()->invokeApiGet('SHOW_USER_USAGE', ['user' => $this->getUsername()]);
        });
    }
1011214
protected function validate(array $item)
    {
        $object = $this->objectFactory->factor($item);
        $list = $this->validator->validate($object);

        return $list;
    }
338468
public static function GetSchemaType( $item )
	{
		if ( $nav instanceof XPath2Item )
		{
			return $item->getSchemaType();
		}

		if ( $nav instanceof XPathNavigator )
		{
			/**
			 * @var XPathNavigator $nav
			 */
			$nav = $item;
			$xmlType = $nav->getSchemaType();
			if ( is_null( $xmlType ) )
			{
				return XmlSchema::$UntypedAtomic;
			}
			return $xmlType;
		}
		return $item->getSchemaType();
	}
426143
public static function point(array $item): string
    {
        if (empty($item['file'])) {
            $result = '[internal function]';
        } else {
            $result = $item['file'];
            if (!empty($item['line'])) {
                $result .= '('.$item['line'].')';
            }
        }
        return $result;
    }
19229
private function parseOption(array $item) : Option
    {
        $name = $item['option'];

        $characteristic = $item['characteristic'] ?? null;

        if (isset($characteristic))
        {
            $characteristic = self::optionCharacteristic($characteristic);
        }

        $type = $item['type'] ?? null;

        $default = $item['default'] ?? null;

        $description = $item['description'] ?? null;

        $fixedName = $item['name'] ?? null;

        $option = new Option($name, $characteristic, $type, $default);

        if (isset($description))
        {
            $option->setDescription($description);
        }

        if (isset($fixedName))
        {
            if ($fixedName[0] === '-')
            {
                throw new OptionLoaderException(
                    "An option's fixed name may not start with a `-`.",
                    $item
                );
            }

            $option->setFixedName($fixedName);
        }

        if (isset($item['aliases']))
        {
            foreach ($item['aliases'] as $alias)
            {
                $aliasCharacteristic = $alias['characteristic'] ?? null;

                if (isset($aliasCharacteristic))
                {
                    $aliasCharacteristic = self::optionCharacteristic(
                        $aliasCharacteristic
                    );
                }

                $aliasName = $alias['option'] ?? null;

                if ( ! isset($aliasName))
                {
                    throw new OptionLoaderException(
                        "An alias must contain its own option name.",
                        $alias
                    );
                }

                new AliasOption($aliasName, $aliasCharacteristic, $option);
            }
        }

        if (isset($fixedName))
        {
            $this->optionCatalogue[$fixedName] = $option;
        }

        $this->optionCatalogue[$option->getPrintableName()] = $option;

        return $option;
    }
140893
protected function htmlEntityEncode($item)
    {
        if (is_array($item)) {
            array_walk_recursive($item, function (&$value) {
                $value = htmlentities($value);
            });
        } else {
            $item = htmlentities($item);
        }

        return $item;
    }
398249
protected function getType( $item )
    {
        $type = gettype( $item );
        if ( is_object( $item ) )
            $type .= "[" . get_class( $item ) . "]";

        return $type;
    }
1124795
public function isArray($item=null) {
    list($item) = self::_wrapArgs(func_get_args(), 1);
    return self::_wrap(is_array($item));
  }
512774
protected function getInvocation(array $item)
    {
        $invocation = '';

        if (isset($item['class']) && isset($item['type'])) {
            $invocation.= $item['class'].$item['type'];
        }

        $invocation.= $item['function'];
        $invocation.= '(';

        if (isset($item['args'])) {
            $args = [];

            foreach ($item['args'] as $arg) {
                $args[] = $this->varToString($arg);
            }

            $invocation.= implode(', ', $args);
        }

        $invocation.= ')';

        return $invocation;
    }