public function embedded(GenericReadModelMapper $readModelMapper) : EmbeddedReadModelAliasDefiner
    {
        $this->verifyClassDefined(__METHOD__);
        $this->verifyMapperDefined(__METHOD__);

        return new EmbeddedReadModelAliasDefiner(function ($alias) use ($readModelMapper) {
            $mapper = $readModelMapper->loadMapperFor($this->mapper);

            $this->readDefinition->embedded($alias)->using($mapper);
        });
    }
public function embedded(GenericReadModelMapper $readModelMapper) : EmbeddedReadModelAliasDefiner
    {
        $this->verifyClassDefined(__METHOD__);
        $this->verifyMapperDefined(__METHOD__);

        return new EmbeddedReadModelAliasDefiner(function ($alias) use ($readModelMapper) {
            $mapper = $readModelMapper->loadMapperFor($this->mapper);

            $this->readDefinition->embedded($alias)->using($mapper);
        });
    }
public function embedded ( GenericReadModelMapper $ readModelMapper ) : EmbeddedReadModelAliasDefiner { $ this -> verifyClassDefined ( __METHOD__ ) ; $ this -> verifyMapperDefined ( __METHOD__ ) ; return new EmbeddedReadModelAliasDefiner ( function ( $ alias ) use ( $ readModelMapper ) { $ mapper = $ readModelMapper -> loadMapperFor ( $ this -> mapper ) ; $ this -> readDefinition -> embedded ( $ alias ) -> using ( $ mapper ) ; } ) ; }
Defines an embedded read model.

@param GenericReadModelMapper $readModelMapper

@return EmbeddedReadModelAliasDefiner
Defines an embedded read model .