Skip to content

Commit

Permalink
Add doc about version update on write operation
Browse files Browse the repository at this point in the history
  • Loading branch information
julienfastre committed Dec 29, 2022
1 parent f127f24 commit 5d93145
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/Contract/Service/DocumentManagerInterface.php
Expand Up @@ -47,5 +47,15 @@ public function read(Document $document): StreamInterface;

public function remove(Document $document): void;

/**
* Write the content into the document.
*
* **Important**: any implementation should also ensure to update the version and timestamp
* of the Document, after writing data.
*
* @param Document $document
* @param array{body: string, size: int} $properties
* @return void
*/
public function write(Document $document, array $properties = []): void;
}

0 comments on commit 5d93145

Please sign in to comment.