src/QCheck/Annotation.php
public static function register($type, Generator $generator)
    {
        if (array_key_exists($type, self::$generators)) {
            throw new DuplicateGeneratorException("A generator is already registred for $type.");
        }

        self::$generators[$type] = $generator;
    }
public static function register($type, Generator $generator)
    {
        if (array_key_exists($type, self::$generators)) {
            throw new DuplicateGeneratorException("A generator is already registred for $type.");
        }

        self::$generators[$type] = $generator;
    }
public static function register ( $ type , Generator $ generator ) { if ( array_key_exists ( $ type , self :: $ generators ) ) { throw new DuplicateGeneratorException ( "A generator is already registred for $type." ) ; } self :: $ generators [ $ type ] = $ generator ; }
Associate a generator to a given type.

@param string $type
@param Generator $generator Tĥe generator associated with the type
@throws DuplicateGeneratorException
Associate a generator to a given type .