A generator function generates values to iterate over.
Once a generator function is defined, it can be used by constructing an iterator as shown.
Une fois qu'une fonction génératrice est définie, elle peut être utilisée en construisant un itérateur comme indiqué.
The MELCO motor generator has a generator function similar to a regular alternator.
The password generator function was copied from this page, the author is Mark D. MacLachlan, You can find some other functions on the Web.
La fonction de génération de mot de passe aléatoire a été prise sur cette page, l'auteur est Mark D. MacLachlan, vous pouvez en trouver d'autres sur la toile.
That object then controls the execution of the generator function.
When a generator function is called, it returns an object that can be iterated over.
Starts the execution of a generator function or resumes it at the last executed yield expression.
Démarre l'exécution d'une fonction générateur ou la reprend à la dernière expression yield exécutée.
In an asynchronous generator function, yield expressions are allowed anywhere in a try construct.
Dans une fonction générateur asynchrone, les expressions yield sont autorisées n'importe où dans une construction try.
yield can only be called directly from the generator function that contains it.
The expression yield from <expr> is a syntax error when used in an asynchronous generator function.
L'expression yield from <expr> produit une erreur de syntaxe quand elle est utilisée dans une fonction générateur asynchrone.
As you can see using yield, each time we call next on generator function the value is yielded to output.
Comme vous pouvez le constater en utilisant le rendement, chaque fois que nous appelons la fonction générateur suivante, la valeur est renvoyée à la sortie.
The function* keyword can be used to define a generator function inside an expression.
Le mot-clé function* peut être utilisé pour définir une fonction génératrice à l'intérieur d'une expression.
serving as an electric power storage device is charged by means of the generator function of the generator-motor
servant de dispositif de stockage de puissance électrique est chargée au moyen d'une fonction génératrice du moteur-générateur