public function setName($name)
    {
        $index_prefix = Config::get('larasearch.elasticsearch.index_prefix', '');
        if ($index_prefix && !Str::startsWith($name, $index_prefix)) $name = $index_prefix . $name;

        $this->name = $name;

        return $this;
    }
public function setName($name)
    {
        $index_prefix = Config::get('larasearch.elasticsearch.index_prefix', '');
        if ($index_prefix && !Str::startsWith($name, $index_prefix)) $name = $index_prefix . $name;

        $this->name = $name;

        return $this;
    }
public function setName ( $ name ) { $ index_prefix = Config :: get ( 'larasearch.elasticsearch.index_prefix' , '' ) ; if ( $ index_prefix && ! Str :: startsWith ( $ name , $ index_prefix ) ) $ name = $ index_prefix . $ name ; $ this -> name = $ name ; return $ this ; }
Set index name

@param string
@return Index
Set index name