OpenQuizz
Une application de gestion des contenus pédagogiques
AsyncLoopContext Class Reference
Inheritance diagram for AsyncLoopContext:
Collaboration diagram for AsyncLoopContext:

Public Member Functions

def length (self)
 
def revindex0 (self)
 
def revindex (self)
 
def last (self)
 
def nextitem (self)
 
def __aiter__ (self)
 
def __anext__ (self)
 
- Public Member Functions inherited from LoopContext
def __init__ (self, iterable, undefined, recurse=None, depth0=0)
 
def __len__ (self)
 
def depth (self)
 
def index (self)
 
def first (self)
 
def previtem (self)
 
def cycle (self, *args)
 
def changed (self, *value)
 
def __iter__ (self)
 
def __next__ (self)
 
def __call__ (self, iterable)
 
def __repr__ (self)
 

Additional Inherited Members

- Data Fields inherited from LoopContext
 depth0
 
- Static Public Attributes inherited from LoopContext
 index0
 

Member Function Documentation

◆ __aiter__()

def __aiter__ (   self)

◆ __anext__()

def __anext__ (   self)

◆ last()

def last (   self)
Whether this is the last iteration of the loop.

Causes the iterable to advance early. See
:func:`itertools.groupby` for issues this can cause.
The :func:`groupby` filter avoids that issue.

Reimplemented from LoopContext.

◆ length()

def length (   self)
Length of the iterable.

If the iterable is a generator or otherwise does not have a
size, it is eagerly evaluated to get a size.

Reimplemented from LoopContext.

◆ nextitem()

def nextitem (   self)
The item in the next iteration. Undefined during the last
iteration.

Causes the iterable to advance early. See
:func:`itertools.groupby` for issues this can cause.
The :func:`groupby` filter avoids that issue.

Reimplemented from LoopContext.

◆ revindex()

def revindex (   self)
Number of iterations from the end of the loop, ending at 1.

Requires calculating :attr:`length`.

Reimplemented from LoopContext.

◆ revindex0()

def revindex0 (   self)
Number of iterations from the end of the loop, ending at 0.

Requires calculating :attr:`length`.

Reimplemented from LoopContext.


The documentation for this class was generated from the following file: