/**
  * Registers this renderer class to the registry.
  *
  * @param RendererFactoryRegistry $registry
  */
 public static function onRegister(RendererFactoryRegistry $registry)
 {
     // We have to register this class to the registry.
     // Only if the class is registered, it can be found by the
     // registry and you will see it in the application.
     $registry->registerFactory(new SimpleRendererFactory("Zebra Label Renderer", "PartKeepr\\Printing\\Renderer\\ZebraLabelWriterRenderer\\ZebraLabelWriterRenderer", array("PartKeepr\\Part\\Part", "PartKeepr\\StorageLocation\\StorageLocation"), array()));
 }
Пример #2
0
 /**
  * Retrieve the needed parameters for the renderer class.
  */
 public function getNeededParameters()
 {
     $this->requireParameter("renderer");
     $rendererName = $this->getParameter("renderer", "");
     $data = array();
     $factory = RendererFactoryRegistry::getInstance()->getRendererFactory($rendererName);
     return array("data" => $factory->getParameterObjectTypes());
 }
Пример #3
0
 /**
  * Registers this renderer class to the registry.
  *
  * @param RendererFactoryRegistry $registry
  */
 public static function onRegister(RendererFactoryRegistry $registry)
 {
     // We have to register this class to the registry.
     // Only if the class is registered, it can be found by the
     // registry and you will see it in the application.
     $registry->registerFactory(new SimpleRendererFactory("Default PDF renderer", "PartKeepr\\Printing\\Renderer\\PDFDefaultRenderer\\PDFDefaultRenderer", array("PartKeepr\\StorageLocation\\StorageLocation", "PartKeepr\\Part\\Part"), array("PartKeepr\\Printing\\PageBasicLayout\\PageBasicLayout")));
 }