Skip to content

Commit

Permalink
Documentation for centralized config provider, JSON Relational Dualit…
Browse files Browse the repository at this point in the history
…y View and other updates with formatting improvements
  • Loading branch information
sharadraju committed Jul 23, 2024
1 parent 39bd3a1 commit c63115f
Show file tree
Hide file tree
Showing 13 changed files with 813 additions and 246 deletions.
6 changes: 6 additions & 0 deletions doc/src/.static/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,9 @@ li div.highlight-default.notranslate, li div.highlight-shell.notranslate, li div
font-size: 11pt;
font-weight: bold;
}

/* Added code to override the default content width in ReadtheDocs and break long words */
.wy-nav-content {
max-width: none;
word-break: break-word;
}
52 changes: 52 additions & 0 deletions doc/src/_ext/constants_table.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
#------------------------------------------------------------------------------
# Copyright (c) 2024, Oracle and/or its affiliates.
#
# This software is dual-licensed to you under the Universal Permissive License
# (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl and Apache License
# 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose
# either license.
#
# If you elect to accept the software under the Apache License, Version 2.0,
# the following applies:
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#------------------------------------------------------------------------------

#------------------------------------------------------------------------------
# constants_table.py
#
# Defines a directive (constants-table) that creates a table with a specific
# configuration on top of the extended "list-table-with-summary" directive.
#------------------------------------------------------------------------------

from docutils.statemachine import ViewList

import table_with_summary

class ConstantsTable(table_with_summary.ListTableWithSummary):

def run(self):
self.options["summary"] = \
"The first column displays the name of the constant. The " \
"second column displays the value of the constant. The third " \
"column displays the description of the constant."
self.options["header-rows"] = 1
self.options["class"] = ["wy-table-responsive"]
self.options["widths"] = [40, 15, 45]
self.options["width"] = "100%"
headings = ViewList(['* - Constant Name', ' - Value', ' - Description'])
self.content = headings + self.content
return super().run()

def setup(app):
app.add_directive('constants-table', ConstantsTable)
13 changes: 9 additions & 4 deletions doc/src/api_manual/connection.rst
Original file line number Diff line number Diff line change
Expand Up @@ -676,6 +676,7 @@ Connection Methods
:class: wy-table-responsive
:align: center
:widths: 10 10 30
:width: 100%
:summary: The first column displays the name of the parameter. The second column displays the data type of the parameter. The third column displays the description of the parameter.

* - Parameter
Expand Down Expand Up @@ -842,7 +843,7 @@ Connection Methods
:header-rows: 1
:class: wy-table-responsive
:align: center
:widths: 10 10 20 30
:widths: 10 15 20 25
:summary: The first column displays the Node.js Type. The second
column displays the Database type. The third column displays the
Bind type value. The fourth column displays the notes.
Expand Down Expand Up @@ -972,7 +973,7 @@ Connection Methods
:header-rows: 1
:class: wy-table-responsive
:align: center
:widths: 5 10 35
:widths: 10 10 30
:summary: The first column displays the property. The second column
displays the data type of the property. The third column displays
the description of the property.
Expand Down Expand Up @@ -1511,7 +1512,8 @@ Connection Methods
:header-rows: 1
:class: wy-table-responsive
:align: center
:widths: 10 12 45
:widths: 10 10 30
:width: 100%
:summary: The first column displays the parameter. The second column
displays the data type of the parameter. The third column displays
the description of the parameter.
Expand Down Expand Up @@ -1712,7 +1714,8 @@ Connection Methods
:header-rows: 1
:class: wy-table-responsive
:align: center
:widths: 10 15 40
:widths: 10 10 30
:width: 100%
:summary: The first column displays the parameter. The second column
displays the data type of the parameter. The third column displays
the description of the parameter.
Expand Down Expand Up @@ -2257,6 +2260,7 @@ Connection Methods
:class: wy-table-responsive
:align: center
:widths: 10 10 30
:width: 100%
:summary: The first column displays the parameter. The second column
displays the data type of the parameter. The third column displays
the description of the parameter.
Expand Down Expand Up @@ -2814,6 +2818,7 @@ Connection Methods
:class: wy-table-responsive
:align: center
:widths: 10 10 30
:width: 100%
:summary: The first column displays the parameter. The second column
displays the data type of the parameter. The third column displays the
description of the parameter.
Expand Down
2 changes: 1 addition & 1 deletion doc/src/api_manual/deprecations.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ desupported features are listed first.
:header-rows: 1
:class: wy-table-responsive
:align: center
:widths: 10 25 20
:widths: 20 20 15
:width: 100%
:summary: The first column displays the deprecated API method, property, or constant. The second column displays the node-oracledb version in which the API method, property, or constant was deprecated or desupported. The third column displays the API property, method, or constant to use instead, if applicable.

Expand Down
1 change: 1 addition & 0 deletions doc/src/api_manual/lob.rst
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ Lob Methods
:class: wy-table-responsive
:align: center
:widths: 15 30
:width: 100%
:summary: The first column displays the parameter. The second column
displays the data type of the parameter. The third column displays
the description of the parameter.
Expand Down
Loading

0 comments on commit c63115f

Please sign in to comment.