public function relations($embedded = false)
    {
        $result = [];
        foreach ($this->_relations as $field => $config) {
            if (!$config['embedded'] || $embedded) {
                $result[] = $field;
            }
        }
        return $result;
    }