-
-
Notifications
You must be signed in to change notification settings - Fork 373
function.rst standard
cvvergara edited this page Oct 18, 2013
·
31 revisions
<function>.rst for the pgRouting functions are located on
- src/<section>/doc/<function>.rst
- src/<section>/doc/<subdivision>/<function>.rst (when applicable)
The following is the standard of the structure for the <function>.rst files (including examples for the links and or code).
You can copy/paste an change things acordingly.
..
****************************************************************************
pgRouting Manual
Copyright(c) pgRouting Contributors
This documentation is licensed under a Creative Commons Attribution-Share
Alike 3.0 License: http://creativecommons.org/licenses/by-sa/3.0/
****************************************************************************
.. _pgr_function_name:
pgr_functionName
===============================================================================
.. index::
single: pgr_functionName( list of [parameter type])
module: <module name>
Name
------------------------------------------------------------------------------
``pgr_functionName`` - <Same One line description as in index.rst>
Description
-----------------------------------------------------------------------------
Description of the Function which may include:
how to setup data for the inputs
expected results
.. warning::
Notes and warnings may go where appropiate if needed
Synopsis
------------------------------------------------------------------------------
.. code-block:: sql
type pgr_functionName( list of: [parameter type])
.. rubric:: Parameters
The function accepts the following parameters:
:parameter: ``type`` <One line description as in the example bellow>.
:tol: ``float8`` The maximum search distance for an edge.
Comments on the preparation of the input data may go here.
The function returns:
:parameterName: ``type`` <One/two line description as in the example above>.
Comments on the interpretation of the results may go here.
Prerequisites
------------------------------------------------------------------------------
Preparation of the input data may go here and may include:
Other pgr functions that help prepare the data
Column naming of the input table
Examples
-----------------------------------------------------------------------------
.. code-block:: sql
select pgr_pointtoedgenode('edge_table', 'POINT(2 0)'::geometry, 0.02);
pgr_pointtoedgenode
-------------------
1
(1 row)
The example uses the :ref:`sampledata` network.
See Also
-----------------------------------------------------------------------------
* :ref:`pgr_name_of_other_function` - <same one line comment as in the index.rst of the other function>
.. rubric:: History
* New in version 2.1.0