source/Spiral/ORM/Schemas/RecordSchema.php
public function getIndexes(): \Generator
    {
        $definitions = $this->reflection->getProperty('indexes') ?? [];

        foreach ($definitions as $definition) {
            yield $this->castIndex($definition);
        }
    }
public function getIndexes(): \Generator
    {
        $definitions = $this->reflection->getProperty('indexes') ?? [];

        foreach ($definitions as $definition) {
            yield $this->castIndex($definition);
        }
    }
public function getIndexes ( ) : \ Generator { $ definitions = $ this -> reflection -> getProperty ( 'indexes' ) ?? [ ] ; foreach ( $ definitions as $ definition ) { yield $ this -> castIndex ( $ definition ) ; } }
Returns set of declared indexes.

Example:
const INDEXES = [
[self::UNIQUE, 'email'],
[self::INDEX, 'status', 'balance'],
[self::INDEX, 'public_id']
];

@do generator

@return \Generator|IndexDefinition[]

@throws DefinitionException
Returns set of declared indexes .