Mongolid\Cursor\EmbeddedCursor::getSchemaForEntity PHP Метод

getSchemaForEntity() защищенный Метод

Retrieve a schema based on Entity Class.
protected getSchemaForEntity ( ) : Schema
Результат Mongolid\Schema\Schema
    protected function getSchemaForEntity() : Schema
    {
        if ($this->entityClass instanceof Schema) {
            return $this->entityClass;
        }
        $model = new $this->entityClass();
        if ($model instanceof ActiveRecord) {
            return $model->getSchema();
        }
        return new DynamicSchema();
    }