ApiPlatform\Core\Metadata\Resource\ResourceMetadata::withItemOperations PHP Method

withItemOperations() public method

Returns a new instance with the given item operations.
public withItemOperations ( array $itemOperations ) : self
$itemOperations array
return self
    public function withItemOperations(array $itemOperations) : self
    {
        $metadata = clone $this;
        $metadata->itemOperations = $itemOperations;
        return $metadata;
    }