public function CompiledRoute::serialize

public CompiledRoute::serialize()

Overrides CompiledRoute::serialize

File

core/lib/Drupal/Core/Routing/CompiledRoute.php, line 143

Class

CompiledRoute
A compiled route contains derived information from a route object.

Namespace

Drupal\Core\Routing

Code

public function serialize() {
  // Calling the parent method is safer than trying to optimize out the extra
  // function calls.
  $data = unserialize(parent::serialize());
  $data['fit'] = $this->fit;
  $data['patternOutline'] = $this->patternOutline;
  $data['numParts'] = $this->numParts;

  return serialize($data);
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Routing!CompiledRoute.php/function/CompiledRoute::serialize/8.1.x