forked from ezsystems/ezpublish-kernel
/
Action.php
42 lines (37 loc) · 1.01 KB
/
Action.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
/**
* File containing the content updater action class
*
* @copyright Copyright (C) eZ Systems AS. All rights reserved.
* @license For full copyright and license information view LICENSE file distributed with this source code.
* @version //autogentag//
*/
namespace eZ\Publish\Core\Persistence\Legacy\Content\Type\ContentUpdater;
use eZ\Publish\Core\Persistence\Legacy\Content\Gateway as ContentGateway;
/**
* Updater action base class
*/
abstract class Action
{
/**
* Content gateway
*
* @var \eZ\Publish\Core\Persistence\Legacy\Content\Gateway
*/
protected $contentGateway;
/**
* Creates a new action
*
* @param \eZ\Publish\Core\Persistence\Legacy\Content\Gateway $contentGateway
*/
public function __construct( ContentGateway $contentGateway )
{
$this->contentGateway = $contentGateway;
}
/**
* Applies the action to the given $content
*
* @param int $contentId
*/
abstract public function apply( $contentId );
}