Skip to content

Instantly share code, notes, and snippets.

View EclipseGc's full-sized avatar

Kris Vanderwater EclipseGc

View GitHub Profile
<?php
/**
* @file
* Definition of Drupal\Core\Annotation\Plugin.
*/
namespace Drupal\Core\Annotation;
use Drupal\Core\Annotation\AnnotationInterface;
<?php
namespace Drupal\user\Plugin\block\block;
use Drupal\block\BlockBase;
use Drupal\Core\Annotation\Plugin;
use Drupal\Core\Annotation\Translation;
/**
* @Plugin(
<?php
/**
* @file
* Definition of Drupal\Component\Plugin\Discovery\AnnotatedClassDiscovery.
*/
namespace Drupal\Core\Plugin\Discovery;
use Drupal\Component\Plugin\Discovery\DiscoveryInterface;
<?php
/**
* @file
* Definition of Drupal\Core\Annotation\Plugin.
*/
namespace Drupal\Core\Annotation;
use Drupal\Core\Annotation\AnnotationInterface;
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName d8_testing.webserver.com
ServerAlias www.d8_testing.webserver.com
DocumentRoot /var/www/d8_testing
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
[Fri Jun 22 16:18:06 2012] [error] [client 127.0.0.1] Uncaught PHP Exception Symfony\\Component\\HttpKernel\\Exception\\NotFoundHttpException: "No route found for "POST /http%3A//example.com"" at /var/www/d8_testing/core/lib/Drupal/Core/EventSubscriber/RouterListener.php line 88
[Fri Jun 22 16:18:14 2012] [error] [client 127.0.0.1] Uncaught PHP Exception Symfony\\Component\\HttpKernel\\Exception\\AccessDeniedHttpException: "" at /var/www/d8_testing/core/lib/Drupal/Core/EventSubscriber/AccessSubscriber.php line 34
[Fri Jun 22 16:18:16 2012] [error] [client 192.168.9.1] Uncaught PHP Exception Symfony\\Component\\HttpKernel\\Exception\\AccessDeniedHttpException: "" at /var/www/d8_testing/core/lib/Drupal/Core/EventSubscriber/AccessSubscriber.php line 34
[Fri Jun 22 16:19:38 2012] [error] [client 192.168.9.1] Uncaught PHP Exception Symfony\\Component\\HttpKernel\\Exception\\AccessDeniedHttpException: "" at /var/www/d8_testing/core/lib/Drupal/Core/EventSubscriber/AccessSubscriber.php line 34, referer: http://d8_tes
<?php
namespace Drupal\user\Plugin\block\block;
use Drupal\block\BlockBase;
use Drupal\Core\Annotation\Plugin;
use Drupal\Core\Annotation\Translation;
/**
* @Plugin(
Re: Translations
I'm not sure I see the point is processing translations separately every time they need displaying.
Some plugin types (blocks for instance) will likely have hundreds of implementations in a typical
system, translating all the various titles and descriptions every time they're displayed instead of
simply asking for a different language cache of blocks seems like a lot of additional overhead to
me, especially when we expect to typically have a cache for any plugin type anyway. This is what
the menu system does currently for what I assume are likely the same reasons.
<?php
namespace Drupal\system\Plugin\block\block;
use Drupal\block\BlockBase;
use Drupal\Core\Annotation\Plugin;
use Drupal\Core\Annotation\Translation;
/**
* @Plugin(
WD php: Symfony\Component\DependencyInjection\Exception\InvalidArgumentException: The service definition "plugin.manager.block" does not exist. in [error]
Symfony\Component\DependencyInjection\ContainerBuilder->getDefinition() (line 690 of
/Applications/MAMP/htdocs/d8annoblocks/core/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/ContainerBuilder.php).
Symfony\Component\DependencyInjection\Exception\InvalidArgumentException: The service definition "plugin.manager.block" does not exist. in Symfony\Component\DependencyInjection\ContainerBuilder->getDefinition() (line 690 of /Applications/MAMP/htdocs/d8annoblocks/core/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/ContainerBuilder.php).