3
$ßL]$  ã               @   sŽ   d dl mZmZ ddlmZmZmZmZ ddlm	Z	 G dd„ dƒZ
e
ƒ Zejeje	eeeeƒ dd„ Zdd
d„Zejdƒdd„ ƒZdd„ Zd	S )é   )ÚaxesÚcbooké   )Ú
AitoffAxesÚ
HammerAxesÚLambertAxesÚMollweideAxes)Ú	PolarAxesc               @   s0   e Zd ZdZdd„ Zdd„ Zdd„ Zdd	„ Zd
S )ÚProjectionRegistryzA
    Manages the set of projections available to the system.
    c             C   s
   i | _ d S )N)Ú_all_projection_types)Úself© r   úG/tmp/pip-install-edjban26/matplotlib/matplotlib/projections/__init__.pyÚ__init__
   s    zProjectionRegistry.__init__c             G   s"   x|D ]}|j }|| j|< qW dS )z4
        Register a new set of projections.
        N)Únamer   )r   ZprojectionsÚ
projectionr   r   r   r   Úregister   s    
zProjectionRegistry.registerc             C   s
   | j | S )z9
        Get a projection class from its *name*.
        )r   )r   r   r   r   r   Úget_projection_class   s    z'ProjectionRegistry.get_projection_classc             C   s
   t | jƒS )zR
        Get a list of the names of all projections currently registered.
        )Úsortedr   )r   r   r   r   Úget_projection_names   s    z'ProjectionRegistry.get_projection_namesN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r   r   r   r   r   r   r
      s
   r
   c             C   s   t j| ƒ d S )N)Úprojection_registryr   )Úclsr   r   r   Úregister_projection,   s    r   Nc             C   s<   | dkrd} y
t j| ƒS  tk
r6   td|  ƒ‚Y nX dS )z|
    Get a projection class from its name.

    If *projection* is None, a standard rectilinear projection is returned.
    NZrectilinearzUnknown projection %r)r   r   ÚKeyErrorÚ
ValueError)r   r   r   r   r   0   s    
r   z3.1c             O   s   | j ||ŽS )N)Z _process_projection_requirements)ÚfigureÚargsÚkwargsr   r   r   Úprocess_projection_requirements?   s    r"   c               C   s   t jƒ S )z4
    Get a list of acceptable projection names.
    )r   r   r   r   r   r   r   D   s    r   )N)Ú r   r   Zgeor   r   r   r   Zpolarr	   r
   r   r   ZAxesr   r   Ú
deprecatedr"   r   r   r   r   r   Ú<module>   s   
