
    -e%                    "   d Z ddlmZ ddlZ ej        e          ZddlmZ ddl	m
Z
mZ ddlmZ d	Ze G d
 de                      Z G d de          Z G d de          Z G d de          Z G d de          Z G d de          ZdS )z

    )annotationsN   )abstract)InstanceRequired   )	Transform)CategoricalScaleCompositeScaleLinearScaleLogScaleScalec                  $     e Zd ZdZd fdZ xZS )r   a   Base class for ``Scale`` models that represent an invertible
    computation to be carried out on the client-side.

    JavaScript implementations should implement the following methods:

    .. code-block

        compute(x: number): number {
            # compute and return the transform of a single value
        }

        v_compute(xs: Arrayable<number>): Arrayable<number> {
            # compute and return the transform of an array of values
        }

        invert(sx: number): number {
            # compute and return the inverse transform of a single value
        }

        v_invert(sxs: Arrayable<number>): Arrayable<number> {
            # compute and return the inverse transform of an array of values
        }

    returnNonec                :     t                      j        |i | d S Nsuper__init__selfargskwargs	__class__s      3lib/python3.11/site-packages/bokeh/models/scales.pyr   zScale.__init__H   %    $)&)))))    r   r   __name__
__module____qualname____doc__r   __classcell__r   s   @r   r   r   ,   sG         4* * * * * * * * * *r   r   c                  $     e Zd ZdZd fdZ xZS )ContinuousScalezB Represent a scale transformation between continuous ranges.

    r   r   c                :     t                      j        |i | d S r   r   r   s      r   r   zContinuousScale.__init__R   r   r   r   r    r&   s   @r   r(   r(   L   G         
* * * * * * * * * *r   r(   c                  $     e Zd ZdZd fdZ xZS )r   zI Represent a linear scale transformation between continuous ranges.

    r   r   c                :     t                      j        |i | d S r   r   r   s      r   r   zLinearScale.__init__\   r   r   r   r    r&   s   @r   r   r   V   r*   r   r   c                  $     e Zd ZdZd fdZ xZS )r   zF Represent a log scale transformation between continuous ranges.

    r   r   c                :     t                      j        |i | d S r   r   r   s      r   r   zLogScale.__init__e   r   r   r   r    r&   s   @r   r   r   _   r*   r   r   c                  $     e Zd ZdZd fdZ xZS )r
   zk Represent a scale transformation between a categorical source range and
    continuous target range.

    r   r   c                :     t                      j        |i | d S r   r   r   s      r   r   zCategoricalScale.__init__o   r   r   r   r    r&   s   @r   r
   r
   h   sG         * * * * * * * * * *r   r
   c                  |     e Zd ZdZd fdZ e ee          d          Z e ee          d          Z	 xZ
S )	r   zc Represent a composition of two scales, which useful for defining
    sub-coordinate systems.

    r   r   c                :     t                      j        |i | d S r   r   r   s      r   r   zCompositeScale.__init__y   r   r   z
    The source scale.
    )helpz
    The target scale.
    r   )r!   r"   r#   r$   r   r   r   r   source_scaletarget_scaler%   r&   s   @r   r   r   r   s         * * * * * * 8HHUOO 3 	 	 	L 8HHUOO 3 	 	 	LLLLLr   r   )r$   
__future__r   logging	getLoggerr!   logcore.has_propsr   core.propertiesr   r   
transformsr	   __all__r   r(   r   r   r
   r    r   r   <module>r?      s    # " " " " " g!! & % % % % % 0 0 0 0 0 0 0 0 ! ! ! ! ! ! 
* * * * *I * * 
*>* * * * *e * * ** * * * */ * * ** * * * * * * ** * * * *u * * *	 	 	 	 	U 	 	 	 	 	r   