src/Cortex/Commands/Trigger.php
protected function determineTriggerType($trigger)
    {
        $wildcards = [
            'alphabetic' => '/_/',
            'numeric'    => '/#/',
            'global'     => '/\*/',
        ];

        foreach ($wildcards as $type => $pattern) {
            if (@preg_match_all($pattern, $trigger, $stars)) {
                return $type;
            }
        }

        return 'atomic';
    }
protected function determineTriggerType($trigger)
    {
        $wildcards = [
            'alphabetic' => '/_/',
            'numeric'    => '/#/',
            'global'     => '/\*/',
        ];

        foreach ($wildcards as $type => $pattern) {
            if (@preg_match_all($pattern, $trigger, $stars)) {
                return $type;
            }
        }

        return 'atomic';
    }
protected function determineTriggerType ( $ trigger ) { $ wildcards = [ 'alphabetic' => '/_/' , 'numeric' => '/#/' , 'global' => '/\*/' , ] ; foreach ( $ wildcards as $ type => $ pattern ) { if ( @ preg_match_all ( $ pattern , $ trigger , $ stars ) ) { return $ type ; } } return 'atomic' ; }
Determine the type of trigger to aid in sorting.

@param string $trigger

@return string
Determine the type of trigger to aid in sorting .