public function SuggestionCollection::addSuggestion in Linkit 8.5
Adds a suggestion to this collection.
Parameters
\Drupal\linkit\Suggestion\SuggestionInterface $suggestion: The suggestion to add to the collection.
File
- src/
Suggestion/ SuggestionCollection.php, line 33
Class
- SuggestionCollection
- Defines a suggestion collection used to avoid JSON Hijacking.
Namespace
Drupal\linkit\SuggestionCode
public function addSuggestion(SuggestionInterface $suggestion) {
$this->suggestions[] = $suggestion;
}