Return a content object by it's id or null if there is none.
If the returned content implements RouteAwareInterface, it will be used
to get the route from it to generate an URL.
Parameters
string $id id of the content object:
Return value
object A content that matches this id.
File
- drupal/core/vendor/symfony-cmf/routing/Symfony/Cmf/Component/Routing/ContentRepositoryInterface.php, line 26
Class
- ContentRepositoryInterface
- Interface used by the DynamicRouter to retrieve content by it's id when
generating routes from content-id.
Namespace
Symfony\Cmf\Component\Routing
Code
public function findById($id);