当前位置: 首页>>代码示例>>PHP>>正文


PHP Zend_Pdf_ElementFactory::registerObject方法代码示例

本文整理汇总了PHP中Zend_Pdf_ElementFactory::registerObject方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_Pdf_ElementFactory::registerObject方法的具体用法?PHP Zend_Pdf_ElementFactory::registerObject怎么用?PHP Zend_Pdf_ElementFactory::registerObject使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Zend_Pdf_ElementFactory的用法示例。


在下文中一共展示了Zend_Pdf_ElementFactory::registerObject方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: _dereference

 /**
  * Dereference.
  * Take inderect object, take $value member of this object (must be Zend_Pdf_Element),
  * take reference to the $value member of this object and assign it to
  * $value member of current PDF Reference object
  * $obj can be null
  *
  * @throws Zend_Pdf_Exception
  */
 private function _dereference()
 {
     $obj = $this->_context->getParser()->getObject($this->_context->getRefTable()->getOffset($this->_objNum . ' ' . $this->_genNum . ' R'), $this->_context);
     if ($obj === null) {
         $this->_ref = new Zend_Pdf_Element_Null();
         return;
     }
     if ($obj->toString() != $this->_objNum . ' ' . $this->_genNum . ' R') {
         throw new Zend_Pdf_Exception('Incorrect reference to the object');
     }
     $this->_ref = $obj;
     $this->setParentObject($obj);
     $this->_factory->registerObject($this);
 }
开发者ID:VUW-SIM-FIS,项目名称:emiemi,代码行数:23,代码来源:Reference.php

示例2: __construct

 /**
  * Object constructor
  *
  * @param Zend_Pdf_Element $val
  * @param integer $objNum
  * @param integer $genNum
  * @param Zend_Pdf_ElementFactory $factory
  * @throws Zend_Pdf_Exception
  */
 public function __construct(Zend_Pdf_Element $val, $objNum, $genNum, Zend_Pdf_ElementFactory $factory)
 {
     if ($val instanceof self) {
         throw new Zend_Pdf_Exception('Object number must not be instance of Zend_Pdf_Element_Object.');
     }
     if (!(is_integer($objNum) && $objNum > 0)) {
         throw new Zend_Pdf_Exception('Object number must be positive integer.');
     }
     if (!(is_integer($genNum) && $genNum >= 0)) {
         throw new Zend_Pdf_Exception('Generation number must be non-negative integer.');
     }
     $this->_value = $val;
     $this->_objNum = $objNum;
     $this->_genNum = $genNum;
     $this->_factory = $factory;
     $factory->registerObject($this);
 }
开发者ID:Mendim,项目名称:gtv-resources,代码行数:26,代码来源:Object.php

示例3: __construct

 /**
  * Object constructor
  *
  * @param Zend_Pdf_Element $val
  * @param integer $objNum
  * @param integer $genNum
  * @param Zend_Pdf_ElementFactory $factory
  * @throws Zend_Pdf_Exception
  */
 public function __construct(Zend_Pdf_Element $val, $objNum, $genNum, Zend_Pdf_ElementFactory $factory)
 {
     if ($val instanceof self) {
         require_once PHP_LIBRARY_PATH . 'Zend/Pdf/Exception.php';
         throw new Zend_Pdf_Exception('Object number must not be an instance of Zend_Pdf_Element_Object.');
     }
     if (!(is_integer($objNum) && $objNum > 0)) {
         require_once PHP_LIBRARY_PATH . 'Zend/Pdf/Exception.php';
         throw new Zend_Pdf_Exception('Object number must be positive integer.');
     }
     if (!(is_integer($genNum) && $genNum >= 0)) {
         require_once PHP_LIBRARY_PATH . 'Zend/Pdf/Exception.php';
         throw new Zend_Pdf_Exception('Generation number must be non-negative integer.');
     }
     $this->_value = $val;
     $this->_objNum = $objNum;
     $this->_genNum = $genNum;
     $this->_factory = $factory;
     $this->setParentObject($this);
     $factory->registerObject($this, $objNum . ' ' . $genNum);
 }
开发者ID:netixx,项目名称:Stock,代码行数:30,代码来源:Object.php


注:本文中的Zend_Pdf_ElementFactory::registerObject方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。