private function generate()
    {
        $schema = [];

        foreach ($this->getTables() as $table) {
            $schema[$table] = $this->getTableDefinition($table);
        };

        foreach (array_keys($schema) as $table) {
            $constraints = $this->driver->getConstraints($table);

            foreach ($constraints as $constraint) {
                if (false === empty($constraint['REF_TABLE'])) {
                    $schema[$table]['properties'][$constraint['REF_TABLE']] = $this->mapConstraint($constraint);
                }
            }
        }

        return $schema;
    }