Shouldn't we add a "real" type hint on the method's signature ? Like :
```public function addDocument(DocumentInterface $document,
                                 $overwrite = null,
                                 $commitWithin = null)```