本文整理汇总了PHP中Doctrine_Event::skipOperation方法的典型用法代码示例。如果您正苦于以下问题:PHP Doctrine_Event::skipOperation方法的具体用法?PHP Doctrine_Event::skipOperation怎么用?PHP Doctrine_Event::skipOperation使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Doctrine_Event
的用法示例。
在下文中一共展示了Doctrine_Event::skipOperation方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: postSave
public function postSave(Doctrine_Event $event)
{
$record = $event->getInvoker();
if (array_key_exists($model = get_class($record), $this->configuration) && !$this->isRecordProcessed($record)) {
$this->processCacheInvalidation($record, $this->configuration[$model]);
$this->setRecordProcessed($record);
$event->skipOperation();
}
}
开发者ID:jeremyb,项目名称:akDoctrineTemplateCacheInvaliderPlugin,代码行数:9,代码来源:akTemplateCacheInvaliderListener.class.php
示例2: preDelete
/**
* Skip the normal delete options so we can override it with our own
*
* @param Doctrine_Event $event
* @return void
*/
public function preDelete(Doctrine_Event $event)
{
$name = $this->_options['name'];
$invoker = $event->getInvoker();
if ($this->_options['type'] == 'timestamp') {
$invoker->{$name} = date('Y-m-d H:i:s', time());
} else {
if ($this->_options['type'] == 'boolean') {
$invoker->{$name} = true;
}
}
$event->skipOperation();
}
示例3: processEvent
public function processEvent(Doctrine_Event $event, $skip = false)
{
if (!self::$enabled) {
return;
}
$record = $event->getInvoker();
if (!array_key_exists(get_class($record), $this->configuration) || $this->isRecordProcessed($record)) {
return;
}
$this->processCacheInvalidation($record);
$this->setRecordProcessed($record);
if (true === $skip) {
$event->skipOperation();
}
}
开发者ID:n1k0,项目名称:akDoctrineTemplateCacheInvaliderPlugin,代码行数:15,代码来源:akTemplateCacheInvaliderListener.class.php
示例4: preDelete
/**
* Skip the normal delete options so we can override it with our own
*
* @param Doctrine_Event $event
* @return void
*/
public function preDelete(Doctrine_Event $event)
{
$event->skipOperation();
}
示例5: preDelete
/**
* Skip the normal delete options so we can override it with our own
*
* @param Doctrine_Event $event
* @return void
*/
public function preDelete(Doctrine_Event $event)
{
$name = $this->_options['name'];
$event->getInvoker()->{$name} = date('Y-m-d H:i:s', time());
$event->skipOperation();
}
示例6: preSavepointCreate
public function preSavepointCreate(Doctrine_Event $event)
{
$this->_messages[] = __FUNCTION__;
$event->skipOperation();
}