You are here

public function SimpleMegaMenuHelper::getSimpleMegaMenu in Simple Mega Menu 8

Same name and namespace in other branches
  1. 2.0.x src/SimpleMegaMenuHelper.php \Drupal\simple_megamenu\SimpleMegaMenuHelper::getSimpleMegaMenu()

Get a SimpleMegaMenu entity.

Parameters

string $id: The SimpleMegaMenu id.

Return value

\Drupal\simple_megamenu\Entity\SimpleMegaMenuInterface The SimpleMegaMenuInterface entity.

Overrides SimpleMegaMenuHelperInterface::getSimpleMegaMenu

File

src/SimpleMegaMenuHelper.php, line 81

Class

SimpleMegaMenuHelper
Class SimpleMegaMenuHelper.

Namespace

Drupal\simple_megamenu

Code

public function getSimpleMegaMenu($id) {
  $simpleMegaMenu = $this->entityTypeManager
    ->getStorage('simple_mega_menu')
    ->load($id);
  return $simpleMegaMenu;
}