src/Categories.php
public function uniqueAliases(string $string) : array
    {
        $return = [];
        foreach (preg_split('//u', $string, -1, PREG_SPLIT_NO_EMPTY) as $char) {
            $alias = $this->alias($char);
            if (! in_array($alias, $return)) {
                array_push($return, $alias);
            }
        }
        return $return;
    }
public function uniqueAliases(string $string) : array
    {
        $return = [];
        foreach (preg_split('//u', $string, -1, PREG_SPLIT_NO_EMPTY) as $char) {
            $alias = $this->alias($char);
            if (! in_array($alias, $return)) {
                array_push($return, $alias);
            }
        }
        return $return;
    }
public function uniqueAliases ( string $ string ) : array { $ return = [ ] ; foreach ( preg_split ( '//u' , $ string , - 1 , PREG_SPLIT_NO_EMPTY ) as $ char ) { $ alias = $ this -> alias ( $ char ) ; if ( ! in_array ( $ alias , $ return ) ) { array_push ( $ return , $ alias ) ; } } return $ return ; }
Retrieves all unique script block aliases used in a unicode string.

e.g.

uniqueAliases('ABC') -> ['LATIN']
uniqueAliases('ρAτ-') -> ['GREEK', 'LATIN', 'COMMON']

@param string $string A unicode string
@return array A set of the script block aliases used in a unicode string.
Retrieves all unique script block aliases used in a unicode string .