Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
a25913ab
Commit
a25913ab
authored
Sep 21, 2006
by
zYne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed deprecated events, fixes #97
parent
270bf922
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
41 additions
and
42 deletions
+41
-42
EventListener.php
Doctrine/EventListener.php
+0
-8
Chain.php
Doctrine/EventListener/Chain.php
+14
-27
Interface.php
Doctrine/EventListener/Interface.php
+27
-7
No files found.
Doctrine/EventListener.php
View file @
a25913ab
...
@@ -28,8 +28,6 @@ Doctrine::autoload('Doctrine_EventListener_Interface');
...
@@ -28,8 +28,6 @@ Doctrine::autoload('Doctrine_EventListener_Interface');
* @package Doctrine ORM
* @package Doctrine ORM
* @url www.phpdoctrine.com
* @url www.phpdoctrine.com
* @license LGPL
* @license LGPL
* @version 1.0 alpha
*
*/
*/
abstract
class
Doctrine_EventListener
implements
Doctrine_EventListener_Interface
{
abstract
class
Doctrine_EventListener
implements
Doctrine_EventListener_Interface
{
...
@@ -65,12 +63,6 @@ abstract class Doctrine_EventListener implements Doctrine_EventListener_Interfac
...
@@ -65,12 +63,6 @@ abstract class Doctrine_EventListener implements Doctrine_EventListener_Interfac
public
function
onEvict
(
Doctrine_Record
$record
)
{
}
public
function
onEvict
(
Doctrine_Record
$record
)
{
}
public
function
onPreEvict
(
Doctrine_Record
$record
)
{
}
public
function
onPreEvict
(
Doctrine_Record
$record
)
{
}
public
function
onSaveCascade
(
Doctrine_Record
$record
)
{
}
public
function
onPreSaveCascade
(
Doctrine_Record
$record
)
{
}
public
function
onDeleteCascade
(
Doctrine_Record
$record
)
{
}
public
function
onPreDeleteCascade
(
Doctrine_Record
$record
)
{
}
public
function
onClose
(
Doctrine_Connection
$connection
)
{
}
public
function
onClose
(
Doctrine_Connection
$connection
)
{
}
public
function
onPreClose
(
Doctrine_Connection
$connection
)
{
}
public
function
onPreClose
(
Doctrine_Connection
$connection
)
{
}
...
...
Doctrine/EventListener/Chain.php
View file @
a25913ab
...
@@ -238,43 +238,30 @@ class Doctrine_EventListener_Chain extends Doctrine_Access {
...
@@ -238,43 +238,30 @@ class Doctrine_EventListener_Chain extends Doctrine_Access {
$listener
->
onPreDelete
(
$record
);
$listener
->
onPreDelete
(
$record
);
}
}
}
}
/**
* onEvict
* an event invoked after Doctrine_Record is evicted from record repository
*
* @param Doctrine_Record $record
* @return void
*/
public
function
onEvict
(
Doctrine_Record
$record
)
{
public
function
onEvict
(
Doctrine_Record
$record
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
$listener
->
onEvict
(
$record
);
$listener
->
onEvict
(
$record
);
}
}
}
}
/**
* onPreEvict
* an event invoked before Doctrine_Record is evicted from record repository
*
* @param Doctrine_Record $record
* @return void
*/
public
function
onPreEvict
(
Doctrine_Record
$record
)
{
public
function
onPreEvict
(
Doctrine_Record
$record
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
$listener
->
onPreEvict
(
$record
);
$listener
->
onPreEvict
(
$record
);
}
}
}
}
public
function
onSaveCascade
(
Doctrine_Record
$record
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
$listener
->
onSaveCascade
(
$record
);
}
}
public
function
onPreSaveCascade
(
Doctrine_Record
$record
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
$listener
->
onPreSaveCascade
(
$record
);
}
}
public
function
onDeleteCascade
(
Doctrine_Record
$record
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
$listener
->
onDeleteCascade
(
$record
);
}
}
public
function
onPreDeleteCascade
(
Doctrine_Record
$record
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
$listener
->
onPreDeleteCascade
(
$record
);
}
}
public
function
onClose
(
Doctrine_Connection
$connection
)
{
public
function
onClose
(
Doctrine_Connection
$connection
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
foreach
(
$this
->
listeners
as
$listener
)
{
$listener
->
onClose
(
$connection
);
$listener
->
onClose
(
$connection
);
...
...
Doctrine/EventListener/Interface.php
View file @
a25913ab
<?php
<?php
/*
* $Id$
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.com>.
*/
/**
/**
* Doctrine_EventListener_Interface
*
* interface for event listening, forces all classes that extend
* interface for event listening, forces all classes that extend
* Doctrine_EventListener to have the same method arguments as their parent
* Doctrine_EventListener to have the same method arguments as their parent
*
* @author Konsta Vesterinen
* @package Doctrine ORM
* @url www.phpdoctrine.com
* @license LGPL
*/
*/
interface
Doctrine_EventListener_Interface
{
interface
Doctrine_EventListener_Interface
{
...
@@ -29,12 +55,6 @@ interface Doctrine_EventListener_Interface {
...
@@ -29,12 +55,6 @@ interface Doctrine_EventListener_Interface {
public
function
onEvict
(
Doctrine_Record
$record
);
public
function
onEvict
(
Doctrine_Record
$record
);
public
function
onPreEvict
(
Doctrine_Record
$record
);
public
function
onPreEvict
(
Doctrine_Record
$record
);
public
function
onSaveCascade
(
Doctrine_Record
$record
);
public
function
onPreSaveCascade
(
Doctrine_Record
$record
);
public
function
onDeleteCascade
(
Doctrine_Record
$record
);
public
function
onPreDeleteCascade
(
Doctrine_Record
$record
);
public
function
onSleep
(
Doctrine_Record
$record
);
public
function
onSleep
(
Doctrine_Record
$record
);
public
function
onWakeUp
(
Doctrine_Record
$record
);
public
function
onWakeUp
(
Doctrine_Record
$record
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment