31 lines
479 B
PHP
31 lines
479 B
PHP
<?php
|
|
|
|
namespace Dipper\Foundation\Repository;
|
|
|
|
/**
|
|
* Interface TransformableInterface.
|
|
*/
|
|
interface TransformableInterface
|
|
{
|
|
/**
|
|
* 开启格式数据格式转化
|
|
*
|
|
* @return $this
|
|
*/
|
|
public function withTransform();
|
|
|
|
/**
|
|
* 数据处理中间件.
|
|
*
|
|
* @param mixed $result
|
|
*
|
|
* @return mixed
|
|
*/
|
|
public function parserResult($result);
|
|
|
|
/**
|
|
* @return array
|
|
*/
|
|
public function transform($model);
|
|
}
|