{% if meta['author'] %}
- {{ meta['author'] }}
{% endif %}
{% if meta['date'] %}
- {{ meta['date'] }}
{% endif %}
{% if meta['license'] %}
- {{ meta['license'] }}
{% endif %}
{% if meta['version'] %}
- {{ meta['version'] }}
{% endif %}
{% if meta['category'] %}
- {{ meta['category'] }}
{% endif %}
{% if hierarchy[0] %}
- Source File
{% else %}
- Source File
{% endif %}
{% for item in hierarchy %}
- {{ item }}
{% endfor %}
- {{ name }}
{% endmacro %}
{% macro sidebar(project,self) %}
{% set count = 0 %}
{% if self.variables %}
{% set count = count + 1 %}
{% endif %}
{% if self.constructor %}
{% set count = count + 1 %}
Constructor
{% if self.constructor.obj == 'interface' %}{% set prefix = 'intr' %}{% else %}{% set prefix = 'proc' %}{% endif %}
{{ self.constructor.name }}
{% endif %}
{% if self.programs %}
{% set count = count + 1 %}
{% endif %}
{% if self.modules %}
{% set count = count + 1 %}
{% endif %}
{% if self.interfaces %}
{% set count = count + 1 %}
{% endif %}
{% if self.absinterfaces %}
{% set count = count + 1 %}
{% endif %}
{% if self.types %}
{% set count = count + 1 %}
{% endif %}
{% if self.functions %}
{% set count = count + 1 %}
{% endif %}
{% if self.subroutines %}
{% set count = count + 1 %}
{% endif %}
{% if self.finalprocs %}
{% set count = count + 1 %}
{% endif %}
{% if self.boundprocs %}
{% set count = count + 1 %}
{% endif %}
{% if self.modprocs %}
{% set count = count + 1 %}
{% endif %}
{% if self.src %}
{% set count = count + 1 %}
{% endif %}
{% if count > 0 %}
{% endif %}
{% if self.obj == 'program' %}
All Programs
{% for prog in project.programs|sort(attribute='name') %}
{{ prog.name }}
{% endfor %}
{% elif self.obj == 'module' %}
All Modules
{% for mod in project.modules|sort(attribute='name') %}
{{ mod.name }}
{% endfor %}
{% elif self.obj == 'proc' or (self.obj == 'interface' and (not self.abstract)) %}
All Procedures
{% for proc in project.procedures|sort(attribute='name') %}
{{ proc.name }}
{% endfor %}
{% elif self.obj == 'interface' %}
All Abstract Interfaces
{% for absint in project.absinterfaces|sort(attribute='name') %}
{{ absint.name }}
{% endfor %}
{% elif self.obj == 'type' %}
All Derived Types
{% for dtype in project.types|sort(attribute='name') %}
{{ dtype.name }}
{% endfor %}
{% elif self.obj == 'sourcefile' %}
All Source Files
{% for src in project.files|sort(attribute='name') %}
{{ src.name }}
{% endfor %}
{% endif %}
{% endmacro %}
{% macro var_list(variables,intent=False,permission=False,summary=False) %}
Type | {% if permission %}Visibility | {% endif %}
{% if intent %}Intent | Optional | {% endif %}
Attributes | | Name | {% if not intent %} | Initial | {% endif %} |
{% set colnum = 5 %}
{% if permission %}{% set colnum = colnum + 1%}{% endif %}
{% if intent %}{% set colnum = colnum + 2%}{% else %}{% set colnum = colnum + 1 %}{% endif %}
{% for var in variables %}
{% set args = 0 %}
{% if var.kind %}{% set args = args + 1 %}{% endif %}
{% if var.strlen %}{% set args = args + 1 %}{% endif %}
{% if var.proto %}{% set args = args + 1 %}{% endif %}
{% if var.obj == 'variable' %}
{{ var.vartype }}{% if args > 0 -%}({% if var.kind -%}kind={{ var.kind }}{%- endif %}{% if args > 1 -%},{%- endif %}{% if var.strlen -%}len={{ var.strlen }}{%- endif %}{% if var.proto -%}{% if not var.proto[0].permission or var.proto[0].permission in var.proto[0].parent.display -%}{{ var.proto[0] }}{% else %}{{ var.proto[0].name }}{%- endif %}{{ var.proto[1] }}{%- endif %}){%- endif %}{% if intent or permission or var.parameter or var.attribs|length > 0 -%},{%- endif %} |
{% if intent -%}intent({{ var.intent }}){% if var.optional or permission or var.parameter or var.attribs|length > 0 -%},{% endif %} |
{% if var.optional -%}optional{% if permission or var.parameter or var.attributes|length > 0 -%},{%- endif %}{%- endif %} | {%- endif %}
{% if permission %}{{ var.permission }}{% if var.parameter or var.attribs|length > 0 -%},{%- endif %} | {% endif %}
{% if var.parameter %}parameter{% if var.attribs|length > 0 %}, {% endif %}{% endif %}{% for attrib in var.attribs -%}{{ attrib }}{% if not loop.last -%}, {% endif %}{%- endfor %} | :: |
{{ var.name }}{{ var.dimension }} | {% if not intent %}{% if var.initial -%}{% if var.points -%} => {% else %} = {%- endif %}{% endif %} | {% if var.initial %}{{ var.initial }}{%- endif %} | {% endif %}{% if summary -%}{{ var.meta['summary'] }}{% else %}{{ var.doc }}{% endif %} |
{% elif var.obj == 'proc' %}
{{ proc_summary(var,title=True,small=True) }}
|
{% endif %}
{% endfor %}
{% endmacro %}
{% macro proc_summary(proc,title=True,small=False) %}
{% if title %}
{% if small %}
{% else %}{% endif %}{{ proc_line(proc) }}{% if small %}
{% else %}{% endif %}
{% endif %}
{% if small %}
{% else %}{% endif %}Arguments{% if small %}
{% else %}{% endif %}
{% if proc.args|length > 0 %}
{% if proc.permission in proc.parent.display %}
{{ var_list(proc.args,intent=True,summary=True) }}
{% else %}
{{ var_list(proc.args,intent=True) }}
{% endif %}
{% else %}
None
{% endif %}
{% if proc.retvar %}
{% set var = proc.retvar %}
{% set args = 0 %}
{% if var.kind %}{% set args = args + 1 %}{% endif %}
{% if var.strlen %}{% set args = args + 1 %}{% endif %}
{% if var.proto %}{% set args = args + 1 %}{% endif %}
{% if small %}
{% else %}{% endif %}Return Value {{ var.vartype }}{% if args > 0 -%}({% if var.kind -%}kind={{ var.kind }}{%- endif %}{% if args > 1 -%},{%- endif %}{% if var.strlen -%}len={{ var.strlen }}{%- endif %}{% if var.proto -%}{% if not var.proto[0].permission or var.proto[0].permission in var.proto[0].parent.display -%}{{ var.proto[0] }}{% else %}{{ var.proto[0].name }}{%- endif %}{{ var.proto[1] }}{%- endif %}){%- endif %}{% if var.attribs|length > 0 -%},{%- endif %}
{% for attrib in var.attribs -%}{{ attrib }}{% if not loop.last or var.dimension -%}, {%- endif %}{%- endfor %}{{ var.dimension }}{% if small %}
{% else %}{% endif %}
{{ var.meta['summary'] }}
{% endif %}
{% if proc.doc or (proc.meta and proc.permission not in proc.parent.display) %}
{% if small %}
{% else %}{% endif %}Description{% if small %}
{% else %}{% endif %}
{% if proc.parent and proc.permission not in proc.parent.display %}
{{ meta_list(proc.meta) }}
{% endif %}
{{ proc.meta['summary'] }}
{% endif %}
{% endmacro %}
{% macro bound_info(tb) %}
{% if tb.generic -%}generic,{% else %}procedure,{%- endif %} {{ tb.permission }}{% if tb.attribs -%}, {% for attrib in tb.attribs -%}{{ attrib }}{% if not loop.last -%}, {% endif %}{%- endfor %}{%- endif %} :: {{ tb.name }} {% if tb.generic or tb.name != tb.bindings[0].name %} => {% for bind in tb.bindings -%}{% if not bind.parent or bind.permission in bind.parent.display %}{{ bind }}{% else %}{{ bind.name }}{% endif %}{% if not loop.last -%}, {% endif %}{%- endfor %}{% endif %} {% if tb.binding|length == 1 %}{{ tb.bindings[0].proctype }}{% endif %}
{% if tb.meta['deprecated'] and tb.meta['deprecated'].lower() == 'true' %}
Deprecated
{% endif %}
{% if tb.doc or tb.meta %}
{{ meta_list(tb.meta) }}
{{ tb.meta['summary'] }}
{% endif %}
{% for bind in tb.bindings %}
-
{{ proc_summary(bind) }}
{% endfor %}
{% endmacro %}
{% macro interface(intr) %}
{% if intr.parobj == 'module' and intr.generic %}{{ intr.permission }} {% endif %}interface {% if intr.generic %}{% if intr.permission in intr.parent.display %}{{ intr }}{% else %}{{ intr.name }}{% endif %}{% endif %}
{% if intr.meta['deprecated'] and intr.meta['deprecated'].lower() == 'true' %}
Deprecated
{% endif %}
{% if intr.doc or (intr.meta and intr.permission not in intr.parent.display) %}
{% if intr.permission not in intr.parent.display %}
{{ meta_list(intr.meta) }}
{% endif %}
{{ intr.meta['summary'] }}
{% endif %}
{% if intr.generic %}
{% for proc in intr.functions + intr.subroutines %}
-
{{ proc_summary(proc) }}
{% endfor %}
{% for proc in intr.modprocs %}
-
{{ proc_summary(proc.procedure) }}
{% endfor %}
{% else %}
-
{{ proc_summary(intr.procedure) }}
{% endif %}
{% endmacro %}
{% macro absinterface(intr) %}
abstract interface
{% if intr.meta['deprecated'] and intr.meta['deprecated'].lower() == 'true' %}
Deprecated
{% endif %}
{% if intr.doc or intr.meta %}
{{ meta_list(intr.meta) }}
{{ intr.meta['summary'] }}
{% endif %}
-
{{ proc_summary(intr.procedure) }}
{% endmacro %}
{% macro proc_line(proc,link=True) %}
{% if proc.parobj == 'module' or (proc.parobj == 'interface' and proc.parent.parobj == 'module') %}{{ proc.permission }} {% endif %}{% for attrib in proc.attribs -%}{{ attrib }}{% if not loop.last -%}, {%- endif %}{%- endfor %} {{ proc.proctype|lower }} {% if not proc.parent or (proc.permission in proc.parent.display and link) %}{{ proc }}{% else %}{{ proc.name }}{% endif %}({% for arg in proc.args -%}{{ arg.name }}{% if not loop.last -%}, {% endif %}{%- endfor %}){% if proc.bindC -%}, bind(c)
{% if proc.meta['deprecated'] and proc.meta['deprecated'].lower() == 'true' %}
Deprecated
{% endif %}
{% endif %}
{% endmacro %}
{% macro final(finals) %}
{% for proc in finals %}
{{ proc_summary(proc,title=True) }}
{% endfor %}
{% endmacro %}
{% macro type_summary(dtype) %}
type{% if dtype.parobj == 'module' %}, {{ dtype.permission }}{% endif %}{% if dtype.sequence%}, sequence {% endif %}{% for attrib in dtype.attribs -%}, {{ attrib }}{%- endfor %}{% if dtype.extends %}, extends({{ dtype.extends }}){% endif %} :: {% if dtype.permission in dtype.parent.display %}{{ dtype }}{% else %}{{ dtype.name }}{% endif %}
{% if dtype.meta['deprecated'] and dtype.meta['deprecated'].lower() == 'true' %}
Deprecated
{% endif %}
{% if dtype.variables|length > 0 %}
Components
{{ var_list(dtype.variables,permission=True,summary=True) }}
{% endif %}
{% if dtype.constructor %}
Constructor
{% if dtype.constructor.obj == 'interface' %}
{{ dtype.constructor.meta['summary'] }}
{% endif %}
{% if dtype.constructor.obj == 'proc' %}
{{ proc_line(dtype.constructor) }} | {{ dtype.constructor.meta['summary'] }} |
{% elif dtype.constructor.obj == 'interface' %}
{% for proc in dtype.constructor.functions + dtype.constructor.subroutines %}
{% if proc.parobj == 'module' or (proc.parobj == 'interface' and proc.parent.parobj == 'module') %}{{ proc.permission }} {% endif %}{% for attrib in proc.attribs -%}{{ attrib }}{% if not loop.last -%}, {%- endif %}{%- endfor %} {{ proc.proctype|lower }} {% if proc.permission in proc.parent.display %}{{ proc }}{% else %}{{ proc.name }}{% endif %}({% for arg in proc.args -%}{{ arg }}{% if not loop.last -%}, {% endif %}{%- endfor %}){% if proc.bindC -%}, bind(c){% endif %} | {{ proc.meta['summary'] }} |
{% endfor %}
{% for mproc in dtype.constructor.modprocs %}
{% set proc = mproc.procedure %}
{% if proc.parobj == 'module' or (proc.parobj == 'interface' and proc.parent.parobj == 'module') %}{{ proc.permission }} {% endif %}{% for attrib in proc.attribs -%}{{ attrib }}{% if not loop.last -%}, {%- endif %}{%- endfor %} {{ proc.proctype|lower }} {% if proc.permission in proc.parent.display %}{{ proc }}{% else %}{{ proc.name }}{% endif %}({% for arg in proc.args -%}{{ arg }}{% if not loop.last -%}, {% endif %}{%- endfor %}){% if proc.bindC -%}, bind(c){% endif %} | {{ proc.meta['summary'] }} |
{% endfor %}
{% endif %}
{% endif %}
{% if dtype.finalprocs|length > 0 %}
Finalizations Procedures
{% for fin in dtype.finalprocs %}
final :: {{ fin.name }} | {{ fin.meta['summary'] }} |
{% endfor %}
{% endif %}
{% if dtype.boundprocs|length > 0 %}
Type-Bound Procedures
{% for tb in dtype.boundprocs %}
{% if tb.generic -%}generic,{% else %}procedure,{%- endif %} {{ tb.permission }}{% if tb.attribs -%}, {% for attrib in tb.attribs -%}{{ attrib }}{% if not loop.last -%}, {% endif %}{%- endfor %}{%- endif %} :: {{ tb.name }} {% if tb.generic or tb.name != tb.bindings[0].name %} => {% for bind in tb.bindings -%}{{ bind.name }}{% if not loop.last -%}, {% endif %}{%- endfor %}{% endif %} {% if tb.binding|length == 1 %}{{ tb.bindings[0].proctype }}{% endif %} |
{{ tb.meta['summary'] }} |
{% endfor %}
{% endif %}
{% if dtype.doc or (dtype.meta and dtype.permission not in dtype.parent.display) %}
Description
{% if dtype.permission not in dtype.parent.display %}
{{ meta_list(dtype.meta) }}
{% endif %}
{{ dtype.meta['summary'] }}
{% endif %}
{% endmacro %}
{% macro proc_entry(proc) %}
{{ proc_summary(proc,False) }}
{% endmacro %}
{% macro use_list(obj) %}
{% if obj.uses|length > 0 %}
Uses:
{% for use in obj.uses %}
- {{ use }}
{% endfor %}
{% endif %}
{% endmacro %}
{% macro meta_list(meta) %}
{% if meta['author'] or meta['date'] or meta['license'] or meta['version'] or meta['category'] %}
{% if meta['author'] %}
- Author
- {{ meta['author'] }}
{% endif %}
{% if meta['date'] %}
- Date
- {{ meta['date'] }}
{% endif %}
{% if meta['license'] %}
- License
- {{ meta['license'] }}
{% endif %}
{% if meta['version'] %}
- Version
- {{ meta['version'] }}
{% endif %}
{% if meta['category'] %}
- Category
- {{ meta['category'] }}
{% endif %}
{% endif %}
{% endmacro %}