codekingpro/portable-devtools
114k
1���r �sphinx.addnodes��document���)��}�(� rawsource�� ��children�]�(�docutils.nodes��target���)��}�(h�.. _code_overview:�h]��2attributes�}�(�ids�]��classes�]��names�]��dupnames�]��backrefs�]��refid��
code-overview�u�tagname�h3�line�K�parent�h� _document�h�source��hD:\a\pgadmin-packaging-foundation\pgadmin-packaging-foundation\pgadmin4-8.6\docs\en_US\code_overview.rst�ubh �section���)��}�(hhh]�(h �title���)��}�(h�`Code Overview`:index:�h]�(h �index���)��}�(hhh]�h}�(h]�h]�h]�h]�h]��entries�]�(�single��
Code Overview��index-0�hNt�auhh/h"h#hKh h+ubh)��}�(hhh]�h}�(h]�h>ah]�h]�h]�h]�uhh4h h+ubh �Text����
Code Overview�����}�(h h+h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhh)h h&h!hh"h#hKubh � paragraph���)��}�(hX The bulk of pgAdmin is a Python web application written using the Flask framework5on the backend, and HTML5 with CSS3,ReactJS on the front end. A6desktop runtime is also included for users that prefer a desktop application to7a web application, which is written using NWjs (Node Webkit).�h]�hJX The bulk of pgAdmin is a Python web application written using the Flask framework8on the backend, and HTML5 with CSS3,ReactJS on the front end. A9desktop runtime is also included for users that prefer a desktop application to10a web application, which is written using NWjs (Node Webkit).�����}�(h hWh!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hKh h&h!hubh%)��}�(hhh]�(h*)��}�(h�Runtime�h]�hJ�Runtime�����}�(h hhh!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h heh!hh"h#hK
ubhV)��}�(h��The runtime is based on NWjs which integrates a browser and the Python server11creating a standalone application. The source code can be found in the12**/runtime** directory in the source tree.�h]�(hJ��The runtime is based on NWjs which integrates a browser and the Python server13creating a standalone application. The source code can be found in the14�����}�(h hvh!hh"NhNubh �strong���)��}�(h�**/runtime**�h]�hJ�/runtime�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h hvubhJ� directory in the source tree.�����}�(h hvh!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKh heh!hubeh}�(h]��runtime�ah]�h]��runtime�ah]�h]�uhh$h h&h!hh"h#hK
ubh%)��}�(hhh]�(h*)��}�(h�Web Application�h]�hJ�Web Application�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h h�h!hh"h#hKubhV)��}�(h��The web application forms the bulk of pgAdmin and can be found in the **/web**15directory in the source tree. The main file is **pgAdmin4.py** which can be used16to run the built-in standalone web server, or as a WSGI application for production17use.�h]�(hJ�FThe web application forms the bulk of pgAdmin and can be found in the �����}�(h h�h!hh"NhNubh)��}�(h�**/web**�h]�hJ�/web�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h h�ubhJ�018directory in the source tree. The main file is �����}�(h h�h!hh"NhNubh)��}�(h�**pgAdmin4.py**�h]�hJ�pgAdmin4.py�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h h�ubhJ�j which can be used19to run the built-in standalone web server, or as a WSGI application for production20use.�����}�(h h�h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKh h�h!hubh%)��}�(hhh]�(h*)��}�(h�
Configuration�h]�hJ�
Configuration�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h h�h!hh"h#hKubhV)��}�(hX� The core application configuration is found in **config.py**. This file includes21all configurable settings for the application, along with descriptions of their22use. It is essential that various settings are configured prior to deployment on23a web server; these can be overridden in **config_local.py** or24**config_system.py** (see the :ref:`config.py <config_py>` documentation) to25avoid modifying the main configuration file.�h]�(hJ�/The core application configuration is found in �����}�(h h�h!hh"NhNubh)��}�(h�
**config.py**�h]�hJ� config.py�����}�(h h�h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h h�ubhJ��. This file includes26all configurable settings for the application, along with descriptions of their27use. It is essential that various settings are configured prior to deployment on28a web server; these can be overridden in �����}�(h h�h!hh"NhNubh)��}�(h�**config_local.py**�h]�hJ�config_local.py�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h h�ubhJ� or29�����}�(h h�h!hh"NhNubh)��}�(h�**config_system.py**�h]�hJ�config_system.py�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h h�ubhJ�30 (see the �����}�(h h�h!hh"NhNubh �pending_xref���)��}�(h�:ref:`config.py <config_py>`�h]�h �inline���)��}�(hj6 h]�hJ� config.py�����}�(h j: h!hh"NhNubah}�(h]�h]�(�xref��std��std-ref�eh]�h]�h]�uhj8 h j4 ubah}�(h]�h]�h]�h]�h]��refdoc��
code_overview�� refdomain�jE �reftype��ref��refexplicit���refwarn��� reftarget�� config_py�uhj2 h"h#hKh h�ubhJ�? documentation) to31avoid modifying the main configuration file.�����}�(h h�h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKh h�h!hubeh}�(h]��
configuration�ah]�h]��
configuration�ah]�h]�uhh$h h�h!hh"h#hKubh%)��}�(hhh]�(h*)��}�(h�
User Settings�h]�hJ�
User Settings�����}�(h jn h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h jk h!hh"h#hK&ubhV)��}�(hX� When running in desktop mode, pgAdmin has a single, default user account that is32used for the desktop user. When running in server mode, there may be unlimited33users who are required to login prior to using the application. pgAdmin utilised34the **Flask-Security** module to manage application security and users, and35provides options for self-service password reset and password changes etc.�h]�(hJ��When running in desktop mode, pgAdmin has a single, default user account that is36used for the desktop user. When running in server mode, there may be unlimited37users who are required to login prior to using the application. pgAdmin utilised38the �����}�(h j| h!hh"NhNubh)��}�(h�**Flask-Security**�h]�hJ�Flask-Security�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j| ubhJ�� module to manage application security and users, and39provides options for self-service password reset and password changes etc.�����}�(h j| h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hK(h jk h!hubhV)��}�(hX Whether in desktop or server mode, each user's settings are stored in a SQLite40OR external database which is also used to store the user accounts. This is initially41created using the **setup.py** script which will create the database file and42schema within it, and add the first user account (with administrative43privileges) and a default server group for them. A **settings** table is also44used to store user configuration settings in a key-value fashion. Although not45required, setting keys (or names) are typically formatted using forward slashes46to artificially namespace values, much like the pgAdmin 3 settings files on Linux47or Mac.�h]�(hJ��Whether in desktop or server mode, each user’s settings are stored in a SQLite48OR external database which is also used to store the user accounts. This is initially49created using the �����}�(h j� h!hh"NhNubh)��}�(h�**setup.py**�h]�hJ�setup.py�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j� ubhJ�� script which will create the database file and50schema within it, and add the first user account (with administrative51privileges) and a default server group for them. A �����}�(h j� h!hh"NhNubh)��}�(h�**settings**�h]�hJ�settings�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j� ubhJX table is also52used to store user configuration settings in a key-value fashion. Although not53required, setting keys (or names) are typically formatted using forward slashes54to artificially namespace values, much like the pgAdmin 3 settings files on Linux55or Mac.�����}�(h j� h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hK.h jk h!hubhV)��}�(h��Note that the local configuration must be setup prior to **setup.py** being run.56The local configuration will determine how the script sets up the database,57particularly with regard to desktop vs. server mode.�h]�(hJ�9Note that the local configuration must be setup prior to �����}�(h j� h!hh"NhNubh)��}�(h�**setup.py**�h]�hJ�setup.py�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j� ubhJ�� being run.58The local configuration will determine how the script sets up the database,59particularly with regard to desktop vs. server mode.�����}�(h j� h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hK8h jk h!hubeh}�(h]��
user-settings�ah]�h]��
user settings�ah]�h]�uhh$h h�h!hh"h#hK&ubeh}�(h]��web-application�ah]�h]��web application�ah]�h]�uhh$h h&h!hh"h#hKubh%)��}�(hhh]�(h*)��}�(h�pgAdmin Core�h]�hJ�pgAdmin Core�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h j� h!hh"h#hK=ubhV)��}�(h��The heart of pgAdmin is the **pgadmin** package. This contains the globally60available HTML templates used by the Jinja engine, as well as any global static61files such as images, Javascript and CSS files that are used in multiple modules.�h]�(hJ�The heart of pgAdmin is the �����}�(h j h!hh"NhNubh)��}�(h�**pgadmin**�h]�hJ�pgadmin�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j ubhJ�� package. This contains the globally62available HTML templates used by the Jinja engine, as well as any global static63files such as images, Javascript and CSS files that are used in multiple modules.�����}�(h j h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hK?h j� h!hubhV)��}�(h��The work of the package is handled in it's constructor, **__init__.py**. This64is responsible for setting up logging and authentication, dynamically loading65other modules, and a few other tasks.�h]�(hJ�:The work of the package is handled in it’s constructor, �����}�(h j/ h!hh"NhNubh)��}�(h�**__init__.py**�h]�hJ�__init__.py�����}�(h j7 h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j/ ubhJ�z. This66is responsible for setting up logging and authentication, dynamically loading67other modules, and a few other tasks.�����}�(h j/ h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKCh j� h!hubeh}�(h]��pgadmin-core�ah]�h]��pgadmin core�ah]�h]�uhh$h h&h!hh"h#hK=ubh%)��}�(hhh]�(h*)��}�(h�Modules�h]�hJ�Modules�����}�(h jZ h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h jW h!hh"h#hKHubhV)��}�(hXL Units of functionality are added to pgAdmin through the addition of modules.68Theses are Python object instance of classes, inherits the69PgAdminModule class (a Flask Blueprint implementation), found in70**web/pgadmin/utils.py**. It provide various hook points for other modules71to utilise (primarily the default module - the browser).�h]�(hJ��Units of functionality are added to pgAdmin through the addition of modules.72Theses are Python object instance of classes, inherits the73PgAdminModule class (a Flask Blueprint implementation), found in74�����}�(h jh h!hh"NhNubh)��}�(h�**web/pgadmin/utils.py**�h]�hJ�web/pgadmin/utils.py�����}�(h jp h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h jh ubhJ�k. It provide various hook points for other modules75to utilise (primarily the default module - the browser).�����}�(h jh h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKJh jW h!hubhV)��}�(h�JTo be recognised as a module, a Python package must be created. This must:�h]�hJ�JTo be recognised as a module, a Python package must be created. This must:�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hKPh jW h!hubh �enumerated_list���)��}�(hhh]�(h � list_item���)��}�(h�4Be placed within the **web/pgadmin/** directory, and�h]�hV)��}�(hj� h]�(hJ�Be placed within the �����}�(h j� h!hh"NhNubh)��}�(h�**web/pgadmin/**�h]�hJ�web/pgadmin/�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j� ubhJ� directory, and�����}�(h j� h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKRh j� ubah}�(h]�h]�h]�h]�h]�uhj� h"h#hKRh j� h!hubj� )��}�(h�,Implements pgadmin.utils.PgAdminModule class�h]�hV)��}�(hj� h]�hJ�,Implements pgadmin.utils.PgAdminModule class�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hKSh j� ubah}�(h]�h]�h]�h]�h]�uhj� h"h#hKSh j� h!hubj� )��}�(h�kAn instance variable (generally - named **blueprint**) representing that76particular class in that package.77�h]�hV)��}�(h�jAn instance variable (generally - named **blueprint**) representing that78particular class in that package.�h]�(hJ�(An instance variable (generally - named �����}�(h j� h!hh"NhNubh)��}�(h�
**blueprint**�h]�hJ� blueprint�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j� ubhJ�5) representing that79particular class in that package.�����}�(h j� h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKTh j� ubah}�(h]�h]�h]�h]�h]�uhj� h"h#hKTh j� h!hubeh}�(h]�h]�h]�h]�h]��enumtype��arabic��prefix�h�suffix��)�uhj� h jW h!hh"h#hKRubhV)��}�(hX� Each module may define a **template** and **static** directory for the Blueprint80that it implements. To avoid name collisions, templates should be stored under81a directory within the specified template directory, named after the module itself.82For example, the **browser** module stores it's templates in83**web/pgadmin/browser/templates/browser/**. This does not apply to static files84which may omit the second module name.�h]�(hJ�Each module may define a �����}�(h j h!hh"NhNubh)��}�(h�**template**�h]�hJ�template�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j ubhJ� and �����}�(h j h!hh"NhNubh)��}�(h�85**static**�h]�hJ�static�����}�(h j, h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j ubhJ�� directory for the Blueprint86that it implements. To avoid name collisions, templates should be stored under87a directory within the specified template directory, named after the module itself.88For example, the �����}�(h j h!hh"NhNubh)��}�(h�**browser**�h]�hJ�browser�����}�(h j> h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j ubhJ�# module stores it’s templates in89�����}�(h j h!hh"NhNubh)��}�(h�***web/pgadmin/browser/templates/browser/**�h]�hJ�&web/pgadmin/browser/templates/browser/�����}�(h jP h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j ubhJ�L. This does not apply to static files90which may omit the second module name.�����}�(h j h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKWh jW h!hubhV)��}�(hXl In addition to defining the Blueprint, the **views** module is typically91responsible for defining all the views that will be rendered in response to92client requests, we must provide a REST API url(s) for these views. These must93include appropriate route and security decorators. Take a look at the NodeView94class, which uses the same approach as Flask's MethodView, it can be found in95**web/pgadmin/browser/utils.py**. This specific class is used by browser nodes96for creating REST API url(s) for different operation on them. i.e. list, create,97update, delete, fetch children, get98statistics/reversed SQL/dependencies/dependents list for that node, etc. We can99use the same class for other purpose too. You just need to inherit that class,100and overload the member variables operations, parent_ids, ids, node_type, and101then register it as node view with PgAdminModule instance.�h]�(hJ�+In addition to defining the Blueprint, the �����}�(h jh h!hh"NhNubh)��}�(h� **views**�h]�hJ�views�����}�(h jp h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h jh ubhJXO module is typically102responsible for defining all the views that will be rendered in response to103client requests, we must provide a REST API url(s) for these views. These must104include appropriate route and security decorators. Take a look at the NodeView105class, which uses the same approach as Flask’s MethodView, it can be found in106�����}�(h jh h!hh"NhNubh)��}�(h� **web/pgadmin/browser/utils.py**�h]�hJ�web/pgadmin/browser/utils.py�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h jh ubhJX� . This specific class is used by browser nodes107for creating REST API url(s) for different operation on them. i.e. list, create,108update, delete, fetch children, get109statistics/reversed SQL/dependencies/dependents list for that node, etc. We can110use the same class for other purpose too. You just need to inherit that class,111and overload the member variables operations, parent_ids, ids, node_type, and112then register it as node view with PgAdminModule instance.�����}�(h jh h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hK^h jW h!hubhV)��}�(hX� Most pgAdmin modules will also implement the **hooks** provided by the113PgAdminModule class. This is responsible for providing hook points to integrate114the module into the rest of the application - for example, a hook might tell115the caller what CSS files need to be included on the rendered page, or what menu116options to include and what they should do. Hook points need not exist if they117are not required. It is the responsibility of the caller to ensure they are118present before attempting to utilise them.�h]�(hJ�-Most pgAdmin modules will also implement the �����}�(h j� h!hh"NhNubh)��}�(h� **hooks**�h]�hJ�hooks�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j� ubhJX� provided by the119PgAdminModule class. This is responsible for providing hook points to integrate120the module into the rest of the application - for example, a hook might tell121the caller what CSS files need to be included on the rendered page, or what menu122options to include and what they should do. Hook points need not exist if they123are not required. It is the responsibility of the caller to ensure they are124present before attempting to utilise them.�����}�(h j� h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hKkh jW h!hubhV)��}�(h� Hooks currently implemented are:�h]�hJ� Hooks currently implemented are:�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hKsh jW h!hubh �
literal_block���)��}�(hX8 class MyModule(PgAdminModule):125 """126 This is class implements the pgadmin.utils.PgAdminModule, and127 implements the hooks128 """129 130 ...131 132 def get_own_stylesheets(self):133 """134 Returns:135 list: the stylesheets used by this module, not including any136 stylesheet needed by the submodules.137 """138 return [url_for('static', 'css/mymodule.css')]139 140 def get_own_javascripts(self):141 """142 Returns:143 list of dict:144 - contains the name (representation for this javascript145 module), path (url for it without .js suffix), deps (array of146 dependents), exports window object by the javascript module,147 and when (would you like to load this javascript), etc148 information for this module, not including any script needed149 by submodules.150 """151 return [152 {153 'name': 'pgadmin.extension.mymodule',154 'path': url_for('static', filename='js/mymodule'),155 'exports': None,156 'when': 'server'157 }158 ]159 160 def get_own_menuitems(self):161 """162 Returns:163 dict: the menuitems for this module, not including164 any needed from the submodules.165 """166 return {167 'help_items': [168 MenuItem(169 name='mnu_mymodule_help',170 priority=999,171 # We need to create javascript, which registers itself172 # as module173 module="pgAdmin.MyModule",174 callback='about_show',175 icon='fa fa-info-circle',176 label=gettext('About MyModule'177 )178 ]179 }180 def get_panels(self):181 """182 Returns:183 list: a list of panel objects to add implemented in javascript184 module185 """186 return []187 ...188 189 190 191blueprint = MyModule('mymodule', __name__, static_url_path='/static')�h]�hJX8 class MyModule(PgAdminModule):192 """193 This is class implements the pgadmin.utils.PgAdminModule, and194 implements the hooks195 """196 197 ...198 199 def get_own_stylesheets(self):200 """201 Returns:202 list: the stylesheets used by this module, not including any203 stylesheet needed by the submodules.204 """205 return [url_for('static', 'css/mymodule.css')]206 207 def get_own_javascripts(self):208 """209 Returns:210 list of dict:211 - contains the name (representation for this javascript212 module), path (url for it without .js suffix), deps (array of213 dependents), exports window object by the javascript module,214 and when (would you like to load this javascript), etc215 information for this module, not including any script needed216 by submodules.217 """218 return [219 {220 'name': 'pgadmin.extension.mymodule',221 'path': url_for('static', filename='js/mymodule'),222 'exports': None,223 'when': 'server'224 }225 ]226 227 def get_own_menuitems(self):228 """229 Returns:230 dict: the menuitems for this module, not including231 any needed from the submodules.232 """233 return {234 'help_items': [235 MenuItem(236 name='mnu_mymodule_help',237 priority=999,238 # We need to create javascript, which registers itself239 # as module240 module="pgAdmin.MyModule",241 callback='about_show',242 icon='fa fa-info-circle',243 label=gettext('About MyModule'244 )245 ]246 }247 def get_panels(self):248 """249 Returns:250 list: a list of panel objects to add implemented in javascript251 module252 """253 return []254 ...255 256 257 258blueprint = MyModule('mymodule', __name__, static_url_path='/static')�����}�h j� sbah}�(h]�h]�h]�h]�h]�� xml:space��preserve��force���language��python��highlight_args�}�uhj� h"h#hKuh jW h!hubhV)��}�(hX pgAdmin Modules may include any additional Python modules that are required to259fulfill their purpose, as required. They may also reference other dynamically260loaded modules, but must use the defined hook points and fail gracefully in the261event that a particular module is not present.�h]�hJX pgAdmin Modules may include any additional Python modules that are required to262fulfill their purpose, as required. They may also reference other dynamically263loaded modules, but must use the defined hook points and fail gracefully in the264event that a particular module is not present.�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hK�h jW h!hubeh}�(h]��modules�ah]�h]��modules�ah]�h]�uhh$h h&h!hh"h#hKHubh%)��}�(hhh]�(h*)��}�(h�Nodes�h]�hJ�Nodes�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h j� h!hh"h#hK�ubhV)��}�(h��Nodes are very similar to modules, it represents an individual node or,265collection object on the object explorer treeview. To recognised as a node module, a266Python package (along with javascript modules) must be created. This must:�h]�hJ��Nodes are very similar to modules, it represents an individual node or,267collection object on the object explorer treeview. To recognised as a node module, a268Python package (along with javascript modules) must be created. This must:�����}�(h j h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hK�h j� h!hubj� )��}�(hhh]�(j� )��}�(h�<Be placed within the **web/pgadmin/browser/** directory, and�h]�hV)��}�(hj h]�(hJ�Be placed within the �����}�(h j h!hh"NhNubh)��}�(h�**web/pgadmin/browser/**�h]�hJ�web/pgadmin/browser/�����}�(h j" h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh~h j ubhJ� directory, and�����}�(h j h!hh"NhNubeh}�(h]�h]�h]�h]�h]�uhhUh"h#hK�h j ubah}�(h]�h]�h]�h]�h]�uhj� h"h#hK�h j h!hubj� )��}�(h�eImplements the BrowserPluginModule, and registers the node view, which269exposes required the REST APIs�h]�hV)��}�(h�eImplements the BrowserPluginModule, and registers the node view, which270exposes required the REST APIs�h]�hJ�eImplements the BrowserPluginModule, and registers the node view, which271exposes required the REST APIs�����}�(h jD h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hK�h j@ ubah}�(h]�h]�h]�h]�h]�uhj� h"h#hK�h j h!hubj� )��}�(h� An instance of the class object272�h]�hV)��}�(h�An instance of the class object�h]�hJ�An instance of the class object�����}�(h j\ h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hK�h jX ubah}�(h]�h]�h]�h]�h]�uhj� h"h#hK�h j h!hubeh}�(h]�h]�h]�h]�h]�j
j j hj j uhj� h j� h!hh"h#hK�ubeh}�(h]��nodes�ah]�h]��nodes�ah]�h]�uhh$h h&h!hh"h#hK�ubh%)��}�(hhh]�(h*)��}�(h� Front End�h]�hJ� Front End�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhh)h j~ h!hh"h#hK�ubhV)��}�(hX% pgAdmin uses javascript extensively for the front-end implementation. It uses273require.js to allow the lazy loading (or, say load only when required),274ReactJS with CSS and MaterialUI for UI look and feel. We have275divided each module in small chunks as much as possible. Not all javascript276modules are required to be loaded (i.e. loading a javascript module for277database will make sense only when a server node is loaded completely.) Please278look at the javascript files node.js, browser.js, menu.js, panel.js, etc for279better understanding of the code.�h]�hJX% pgAdmin uses javascript extensively for the front-end implementation. It uses280require.js to allow the lazy loading (or, say load only when required),281ReactJS with CSS and MaterialUI for UI look and feel. We have282divided each module in small chunks as much as possible. Not all javascript283modules are required to be loaded (i.e. loading a javascript module for284database will make sense only when a server node is loaded completely.) Please285look at the javascript files node.js, browser.js, menu.js, panel.js, etc for286better understanding of the code.�����}�(h j� h!hh"NhNubah}�(h]�h]�h]�h]�h]�uhhUh"h#hK�h j~ h!hubeh}�(h]�� front-end�ah]�h]�� front end�ah]�h]�uhh$h h&h!hh"h#hK�ubeh}�(h]�(h�id1�eh]�h]�(�
code overview��
code_overview�eh]�h]�uhh$h hh!hh"h#hK�expect_referenced_by_name�}�j� hs�expect_referenced_by_id�}�hhsubeh}�(h]�h]�h]�h]�h]��source�h#�translation_progress�}�(�total�K �287translated�K uuhh�current_source�N�current_line�N�settings��docutils.frontend��Values���)��}�(�output�Nh)N� generator�N� datestamp�N�root_prefix��/��source_link�N�288source_url�N�
toc_backlinks��entry��footnote_backlinks���
sectnum_xform���strip_comments�N�strip_elements_with_classes�N�
strip_classes�N�report_level�K�289halt_level�K�exit_status_level�K�debug�N�warning_stream�N� traceback���input_encoding�� utf-8-sig��input_encoding_error_handler��strict��output_encoding��utf-8��output_encoding_error_handler�j� �error_encoding��cp1252��error_encoding_error_handler��backslashreplace��
language_code��en��record_dependencies�N�config�N� id_prefix�h�auto_id_prefix��id��
dump_settings�N�dump_internals�N�dump_transforms�N�dump_pseudo_xml�N�expose_internals�N�strict_visitor�N�_disable_config�N�_source�h#�_destination�N�
_config_files�]��file_insertion_enabled���raw_enabled�K�line_length_limit�M'�pep_references�N�pep_base_url��https://peps.python.org/��pep_file_url_template��pep-%04d��rfc_references�N�rfc_base_url��&https://datatracker.ietf.org/doc/html/�� tab_width�K�trim_footnote_reference_space���syntax_highlight��long��smart_quotes���smartquotes_locales�]��character_level_inline_markup���doctitle_xform���
docinfo_xform���sectsubtitle_xform���
image_loading��link��embed_stylesheet���cloak_email_addresses���section_self_link���env�Nub�reporter�N�indirect_targets�]��substitution_defs�}��substitution_names�}��refnames�}��refids�}�h]�has�nameids�}�(j� hj� j� h�h�j� j� jh je j� j� jT jQ j� j� j{ jx j� j� u� nametypes�}�(j� �j� �h��j� �jh �j� �jT �j� �j{ �j� �uh}�(hh&j� h&h�hej� h�je h�j� jk jQ j� j� jW jx j� j� j~ u�
footnote_refs�}��
citation_refs�}��
autofootnotes�]��autofootnote_refs�]��symbol_footnotes�]��symbol_footnote_refs�]�� footnotes�]�� citations�]��autofootnote_start�K�symbol_footnote_start�K �290id_counter��collections��Counter���}�j� Ks��R��parse_messages�]��transform_messages�]�(h �system_message���)��}�(hhh]�hV)��}�(hhh]�hJ�3Hyperlink target "code-overview" is not referenced.�����}�h jE sbah}�(h]�h]�h]�h]�h]�uhhUh jB ubah}�(h]�h]�h]�h]�h]��level�K�type��INFO��source�h#�line�Kuhj@ ubjA )��}�(hhh]�hV)��}�(hhh]�hJ�-Hyperlink target "index-0" is not referenced.�����}�h j` sbah}�(h]�h]�h]�h]�h]�uhhUh j] ubah}�(h]�h]�h]�h]�h]��level�K�type�jZ �source�h#�line�Kuhj@ ube�transformer�N�include_log�]��291decoration�Nh!hub.