1
0
mirror of synced 2024-12-15 15:46:02 +03:00
doctrine2/tests/Doctrine/Tests/Models/Company/ContractSubscriber.php

92 lines
1.8 KiB
PHP
Raw Normal View History

2012-07-30 02:10:33 +04:00
<?php
namespace Doctrine\Tests\Models\Company;
class ContractSubscriber
{
2012-07-30 05:03:29 +04:00
static public $postPersistCalls;
2012-07-31 05:26:55 +04:00
static public $prePersistCalls;
static public $postUpdateCalls;
static public $preUpdateCalls;
static public $postRemoveCalls;
static public $preRemoveCalls;
static public $preFlushCalls;
static public $postLoadCalls;
2012-07-30 02:10:33 +04:00
static public $instances;
public function __construct()
{
self::$instances[] = $this;
}
/**
* @PostPersist
*/
2012-07-30 04:46:38 +04:00
public function postPersistHandler(CompanyContract $contract)
2012-07-30 02:10:33 +04:00
{
2012-07-30 05:03:29 +04:00
self::$postPersistCalls[] = func_get_args();
2012-07-30 02:10:33 +04:00
}
/**
* @PrePersist
*/
2012-07-30 04:46:38 +04:00
public function prePersistHandler(CompanyContract $contract)
2012-07-30 02:10:33 +04:00
{
self::$prePersistCalls[] = func_get_args();
}
2012-07-31 05:26:55 +04:00
/**
* @PostUpdate
*/
public function postUpdateHandler(CompanyContract $contract)
{
self::$postUpdateCalls[] = func_get_args();
}
/**
* @PreUpdate
*/
public function preUpdateHandler(CompanyContract $contract)
{
self::$preUpdateCalls[] = func_get_args();
}
/**
* @PostRemove
*/
public function postRemoveHandler(CompanyContract $contract)
{
self::$postRemoveCalls[] = func_get_args();
}
/**
* @PreRemove
*/
public function preRemoveHandler(CompanyContract $contract)
{
self::$preRemoveCalls[] = func_get_args();
}
/**
* @PreFlush
*/
public function preFlushHandler(CompanyContract $contract)
{
self::$preFlushCalls[] = func_get_args();
}
/**
* @PostLoad
*/
public function postLoadHandler(CompanyContract $contract)
{
self::$postLoadCalls[] = func_get_args();
}
2012-07-30 02:10:33 +04:00
}