public function createIndex($label, $property)
    {
        $statements = [];
        if (is_array($property)) {
            foreach ($property as $prop) {
                $statements[] = 'CREATE INDEX ON :'.$label.'('.$prop.')';
            }
        } else {
            $statements[] = 'CREATE INDEX ON :'.$label.'('.$property.')';
        }
        foreach ($statements as $statement) {
            $this->sendCypherQuery($statement);
        }

        return true;
    }
public function createIndex($label, $property)
    {
        $statements = [];
        if (is_array($property)) {
            foreach ($property as $prop) {
                $statements[] = 'CREATE INDEX ON :'.$label.'('.$prop.')';
            }
        } else {
            $statements[] = 'CREATE INDEX ON :'.$label.'('.$property.')';
        }
        foreach ($statements as $statement) {
            $this->sendCypherQuery($statement);
        }

        return true;
    }
public function createIndex ( $ label , $ property ) { $ statements = [ ] ; if ( is_array ( $ property ) ) { foreach ( $ property as $ prop ) { $ statements [ ] = 'CREATE INDEX ON :' . $ label . '(' . $ prop . ')' ; } } else { $ statements [ ] = 'CREATE INDEX ON :' . $ label . '(' . $ property . ')' ; } foreach ( $ statements as $ statement ) { $ this -> sendCypherQuery ( $ statement ) ; } return true ; }
Creates an index on a label.

@param string       $label
@param string|array $property

@return bool

@deprecated will be removed in 4.0
Creates an index on a label .