File: //usr/lib/python3/dist-packages/duplicity/__pycache__/lazy.cpython-310.pyc
o
�~�_L; � @ s� d Z ddlmZ ddlmZ ddlmZ ddlmZ ddlmZ ddlZddl m
Z
dd l mZ dd
l mZ G dd� de�Z
G d
d� de�ZG dd� de�ZG dd� de�ZdS )z=Define some lazy data structures and functions acting on them� )�print_function)�map)�next)�range)�objectN)�log)�robust)�utilc @ s� e Zd ZdZedd� �Zedd� �Zedd� �Zedd � �Zed
d� �Z edd
� �Z
eddd� fdd��Zedd� �Zedd� �Z
edd� �Zedd� �Zedd� �Zeddd��ZdS ) �Iterz:Hold static methods for the manipulation of lazy iteratorsc c s � |D ] }| |�r|V qdS )z5Like filter in a lazy functional programming languageN� )� predicate�iterator�ir r �0/usr/lib/python3/dist-packages/duplicity/lazy.py�filter) s ���zIter.filterc c s � |D ]}| |�V qdS )z2Like map in a lazy functional programming languageNr ��functionr
r r r r r 0 s ��zIter.mapc C s |D ]}| |� qdS )z(Run function on each element in iteratorNr r r r r �foreach6 s
�zIter.foreachc g � � | D ]
}|D ]}|V qqdS )zLazily concatenate iteratorsNr )�iters�iterr r r r �cat<