Php 默认API平台操作存储在哪里?

Php 默认API平台操作存储在哪里?,php,api,symfony,platform,api-platform.com,Php,Api,Symfony,Platform,Api Platform.com,我想知道默认的API平台操作(CRUD方法)存储在哪里,以便我可以在任何需要的地方调用它们 我需要它,因为当我定义自定义操作时,我想调用它们(默认操作),这样我就不需要重写代码(比如,获取资源集合) 例如: class GetResourceListAction { public function __invoke() { //Do my things here //And finally call default operation which

我想知道默认的API平台操作(CRUD方法)存储在哪里,以便我可以在任何需要的地方调用它们

我需要它,因为当我定义自定义操作时,我想调用它们(默认操作),这样我就不需要重写代码(比如,获取资源集合)

例如:

class GetResourceListAction
{
    public function __invoke()
    {
        //Do my things here

        //And finally call default operation which return collection
    }    
}
谢谢

如中所述,您可以直接返回您的收藏,剩下的工作将由API平台操作完成

例:

public function\u调用(Book$data):Book
{
$this->bookPublishingHandler->handle($data);
返回$data;
}

谢谢。我在想什么:')