
    -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
 ddlmZ dd	lmZ d
dlmZ dZ G d de          ZdS )ao  
To generate the serialized JSON representation for a Bokeh application
from a single Python script, pass the script name to ``bokeh json`` on the
command line:

.. code-block:: sh

    bokeh json app_script.py

The generated JSON will be saved in the current working directory with
the name ``app_script.json``.

Applications can also be created from directories. The directory should
contain a ``main.py`` (and any other helper modules that are required) as
well as any additional assets (e.g., theme files). Pass the directory name
to ``bokeh json`` to generate the JSON:

.. code-block:: sh

    bokeh json app_dir

By default, the generated JSON is output as one line, with no indentation.
To generate "pretty printed" JSON on multiple lines, you can specify an
indentation level with the ``--indent`` argument:

.. code-block:: sh

    bokeh json app_script.py --indent=2

    )annotationsN)	Namespace   )serialize_json)Document   )Argument   )FileOutputSubcommand)JSONc                      e Zd ZdZdZdZdZ ej        d           d e	de
dd          fg ej                    R ZddZdS )r   z; Subcommand to output applications as serialized JSON

    jsonz.Create JSON files for one or more applicationsz--indentLEVELz indentation to use when printingN)metavartypehelpdefaultargsr   docr   returnstrc                R    t          |                                |j                  S )z


        )indent)r   to_jsonr   )selfr   r   s      >lib/python3.11/site-packages/bokeh/command/subcommands/json.pyfile_contentszJSON.file_contentsa   s!     ckkmmDK@@@@    )r   r   r   r   r   r   )__name__
__module____qualname____doc__name	extensionr   r   	files_argr	   int
other_argsr   r    r   r   r   r   G   s         
 D I;D 	'&v..	XX3	
 
 
 	 
)		(	*	* DA A A A A Ar   r   )r"   
__future__r   logging	getLoggerr   logargparser   core.json_encoderr   documentr   
subcommandr	   file_outputr   __all__r   r(   r   r   <module>r3      s    D # " " " " " g!!       0 / / / / /             ! ! ! ! ! ! - - - - - -A A A A A A A A A Ar   