protected function newGeneratorFromAlias($alias, $length = null)
	{
		$generatorAliases = [
			'numeric' => 'numeric',
			'alphanum' => 'alphaNumeric',
			'token' => 'token',
			'bytes' => 'randomByte'
		];

		if (array_key_exists($alias, $generatorAliases)) {
			return $this->newGenerator($generatorAliases[$alias], $length);
		}
	}
protected function newGeneratorFromAlias($alias, $length = null)
	{
		$generatorAliases = [
			'numeric' => 'numeric',
			'alphanum' => 'alphaNumeric',
			'token' => 'token',
			'bytes' => 'randomByte'
		];

		if (array_key_exists($alias, $generatorAliases)) {
			return $this->newGenerator($generatorAliases[$alias], $length);
		}
	}
protected function newGeneratorFromAlias ( $ alias , $ length = null ) { $ generatorAliases = [ 'numeric' => 'numeric' , 'alphanum' => 'alphaNumeric' , 'token' => 'token' , 'bytes' => 'randomByte' ] ; if ( array_key_exists ( $ alias , $ generatorAliases ) ) { return $ this -> newGenerator ( $ generatorAliases [ $ alias ] , $ length ) ; } }
Creates a new generator instance from the given alias.

@param string $alias Generator type alias
@param mixed $length
@return Keygen\Generator | null

@throws \InvalidArgumentException
Creates a new generator instance from the given alias .