%PDF- %PDF-
Direktori : /lib/python3/dist-packages/pyrsistent/__pycache__/ |
Current File : //lib/python3/dist-packages/pyrsistent/__pycache__/_pmap.cpython-312.pyc |
� n�9e�J � �> � d dl mZmZ d dlmZ d dlmZmZ d dlm Z d dl mZ ed� Z edd� � Z G d � d� Z G d� d e� Z G d� de� Z G d� deee f � Z ej$ e� ej$ e� d� Z ei d � Zi d fd�Zd� Zy)� )�Mapping�Hashable)�chain)�Generic�TypeVar)�pvector�� transform�KT�VT_coT)� covariantc �( � e Zd ZdZd� Zd� Zd� Zd� Zy)�PMapViewa� View type for the persistent map/dict type `PMap`. Provides an equivalent of Python's built-in `dict_values` and `dict_items` types that result from expreessions such as `{}.values()` and `{}.items()`. The equivalent for `{}.keys()` is absent because the keys are instead represented by a `PSet` object, which can be created in `O(1)` time. The `PMapView` class is overloaded by the `PMapValues` and `PMapItems` classes which handle the specific case of values and items, respectively Parameters ---------- m : mapping The mapping/dict-like object of which a view is to be created. This should generally be a `PMap` object. c � � t |t � s't |t � rt |� }nt d� �t j | d|� y )Nz"PViewMap requires a Mapping object�_map)� isinstance�PMapr �pmap� TypeError�object�__setattr__)�self�ms �2/usr/lib/python3/dist-packages/pyrsistent/_pmap.py�__init__zPMapView.__init__ s= � ��!�T�"��!�W�%���G��� D�E�E����4���+� c �, � t | j � S �N)�lenr �r s r �__len__zPMapView.__len__&