24 lines
641 B
PHP
24 lines
641 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
declare(strict_types=1);
|
||
|
|
|
||
|
|
namespace App\Platform;
|
||
|
|
|
||
|
|
use Hyperf\Amqp\Message\ConsumerMessageInterface;
|
||
|
|
use App\Model\Company;
|
||
|
|
use App\Model\Platform;
|
||
|
|
use App\Model\Store;
|
||
|
|
use App\Model\Model as Entity;
|
||
|
|
|
||
|
|
interface EntityParseInterface
|
||
|
|
{
|
||
|
|
public function companyScopeMatch(ConsumerMessageInterface $message) : Company;
|
||
|
|
|
||
|
|
public function platformScopeMatch(ConsumerMessageInterface $message) : Platform;
|
||
|
|
|
||
|
|
public function storeScopeMatch(ConsumerMessageInterface $message) : Store;
|
||
|
|
|
||
|
|
public function entityMatch(ConsumerMessageInterface $message) : Entity;
|
||
|
|
|
||
|
|
public function entityMap(array $data, Entity $entity): Entity;
|
||
|
|
}
|