Get all the possible phrases
@return array
171670
public function getPhrases()
    {   
        $phrases = [];

        for($index = $this->nGramSize; $index >= 2; $index--)
        {                     
            $phrases = array_merge($phrases, NGramFactory::create($this->getTokens(), $index));                        
        }
        
        // you cannot use a phrase if it is a substring of a longer phrase
        // we must exclude all of the substring phrases        
        $add = [];
        $remove = [];
        foreach($phrases as $phrase) 
        {   
            if(isset($remove[$phrase])) {
                continue;
            } elseif (!isset($add[$phrase])) {
                $add[$phrase] = true;
                // remove the suffix word
                $remove[substr($phrase, 0, strrpos($phrase," "))] = true; 
                //remove the prefix            
                $remove[substr($phrase, strpos($phrase," ")+1)] = true;                 
            }
        }        
        return array_keys($add);        
    }
315783
private function getQueryText()
    {
        $terms = array_map(
            function (TermItem $termItem) {
                return $termItem->getTitle();
            },
            $this->termDataProvider->getItems()
        );

        if (empty($terms)) {
            $terms = [$this->queryFactory->get()->getQueryText()];
        }

        return $terms;
    }
1318684
private function getLanguages()
    {
        $allLanguages = $this->manager->languages();

        if (! $this->option('lang')) {
            return $allLanguages;
        }

        $userLanguages = explode(',', (string) $this->option('lang'));

        if ($missingLanguages = array_diff($userLanguages, $allLanguages)) {
            throw new InvalidArgumentException('Unknown Language(s) ['.implode(',', $missingLanguages).'].');
        }

        return $userLanguages;
    }
140908
protected function getContentLanguageCodes()
    {
        return array_map(
            function($language) {
                return $language->languageCode;
            },
            array_filter(
                $this->repository->getContentLanguageService()->loadLanguages(),
                function ($language) {
                    return $language->enabled;
                }
            )
        );
    }
817404
public function getLanguages()
    {
        $source = $this->server['HTTP_ACCEPT_LANGUAGE'];

        if (strpos($source, ',') !== false) {
            $langs = explode(',', $source);
            return $langs;
        } else {
            return array($source);
        }
    }
436559
protected function getFlags()
    {
        $tales = '';
        if (!empty($this->tales)) {
            $tales = ' -i ' . $this->phpci->buildPath . $this->tales;
        }

        $suffixes = '';
        if (count($this->suffixes)) {
            $suffixes = ' -e ' . implode(',', $this->suffixes);
        }

        return array($suffixes, $tales);
    }
1048486
public function getLanguages()
    {
        if ($this->_languages === null) {
            $this->_languages = Lang::getQuery();
        }
    
        return $this->_languages;
    }
635227
public function getVerbs() {
      if (sizeof($this->data) > 1) {
        return array_merge($this->data[0]->verbs, array_slice($this->data, 1, sizeof($this->data)));
      }
      return $this->data[0]->verbs;
    }
1050061
public function getCitations(): array
    {
        preg_match_all('/\n(2 SOUR @(' . Gedcom::REGEX_XREF . ')@(?:\n[3-9] .*)*)/', $this->gedcom(), $matches, PREG_SET_ORDER);
        $citations = [];
        foreach ($matches as $match) {
            $source = Source::getInstance($match[2], $this->record()->tree());
            if ($source && $source->canShow()) {
                $citations[] = $match[1];
            }
        }

        return $citations;
    }
1278639
public function getClauses()
    {
        return array(
            $this->getSelect(),
            $this->getFrom(),
            $this->getJoins(),
            $this->getWhere(),
            $this->getGroup(),
            $this->getOrder(),
            $this->getLimit(),
        );
    }
465619
public function getKeywords()
    {
        $results = [];
        $data = $this->getData();
        $text = strip_tags($data['content']);
        $words = str_word_count($text, 1);
        foreach ($words as $word) {
            if (strlen($word) < 4) {
                continue;
            }
            if (! array_key_exists($word, $results)) {
                $results[$word] = 0;
            }
            $results[$word]++;
        }

        arsort($results);
        $results = array_slice(array_keys($results), 0, 20);
        return implode(', ', $results);
    }
224653
public function getAllTranslations()
    {
        $this->loadTranslations($this->currentLanguage);

        if (!isset($this->translations[$this->currentLanguage])) {
            return array();
        }

        return $this->translations[$this->currentLanguage];
    }
807585
public function getTermsObjects()
    {
        $decodedContent = $this->jsonDecode();

        $results = [];

        foreach ($decodedContent['table']['rows'] as $row) {
            $term = new GoogleTrendsTerm();

            $term->term = $row['c'][0]['v'];
            $term->ranking = $row['c'][1]['v'];
            $term->productUrl = $row['c'][2]['v'];
            $term->searchUrl = $row['c'][3]['v'];

            $results[] = $term;
        }

        return $results;
    }
99880
public function getAllKeys() {
		$all_messages = array();

		// First, let's merge all the arrays in order to get all the keys:
		foreach ($this->messages as $language=>$message) {
			$all_messages = array_merge($all_messages, $message->getAllMessages());
		}

		return array_keys($all_messages);
	}
951931
public function getAll() {
		if ($this->hasAny()) {
			$messages = $_SESSION[self::SESSION_KEY_FLASH];

			$_SESSION[self::SESSION_KEY_FLASH] = [];

			return $messages;
		}
		else {
			return [];
		}
	}
690001
public function getSeverities()
    {
        return array(
            'info' => $this->translation->text('Info'),
            'danger' => $this->translation->text('Danger'),
            'warning' => $this->translation->text('Warning')
        );
    }
755478
public function getKeywords()
	{
		$keywords = $this->keywords ? : $this->getDefault('keywords');
		return (is_array($keywords)) ? implode(', ', $keywords) : $keywords;
	}