lib/Elastica/Query/Match.php
public function setFieldMaxExpansions(string $field, int $maxExpansions): self
    {
        return $this->setFieldParam($field, 'max_expansions', $maxExpansions);
    }
public function setFieldMaxExpansions(string $field, int $maxExpansions): self
    {
        return $this->setFieldParam($field, 'max_expansions', $maxExpansions);
    }
public function setFieldMaxExpansions ( string $ field , int $ maxExpansions ) : self { return $ this -> setFieldParam ( $ field , 'max_expansions' , $ maxExpansions ) ; }
Set field max expansions.

@param string $field
@param int    $maxExpansions

@return $this
Set field max expansions .