public function writeSchema(WriterInterface $writer)
    {
        $this->getDocument()->addLog(sprintf('Processing schema %s:', $this->name));
        $this->getDocument()->addLog('Processing tables:');
        $this->getTables()->write($writer);
        $this->getDocument()->addLog('Processing views:');
        $this->getViews()->write($writer);

        return $this;
    }