Render documentation pages as HTML

Introduced classes

class DocTopMenu

nitc :: DocTopMenu

Top menu bar template
class PiwikScript

nitc :: PiwikScript

JS script for Piwik Tracker

Redefined classes

redef class DocPage

nitc :: static_html $ DocPage

A documentation page abstraction
redef class DocSidebar

nitc :: static_html $ DocSidebar

Nitdoc sidebar abstraction
redef class DocTab

nitc :: static_html $ DocTab

A documentation tabulated view
redef class HtmlightVisitor

nitc :: static_html $ HtmlightVisitor

Visitor used to produce a HTML tree based on a AST on a Source
redef class MClass

nitc :: static_html $ MClass

A named class
redef class MClassDef

nitc :: static_html $ MClassDef

A definition (an introduction or a refinement) of a class in a module
redef abstract class MEntity

nitc :: static_html $ MEntity

A named and possibly documented entity in the model.
redef class MGroup

nitc :: static_html $ MGroup

A group of modules in a package
redef class MModule

nitc :: static_html $ MModule

A Nit module is usually associated with a Nit source file.
redef class MPackage

nitc :: static_html $ MPackage

A Nit package, that encompass a product
redef abstract class MPropDef

nitc :: static_html $ MPropDef

A definition of a property (local property)
redef abstract class MProperty

nitc :: static_html $ MProperty

A service (global property) that generalize method, attribute, etc.
redef class PageHome

nitc :: static_html $ PageHome

The Nitdoc overview page that displays the nit packages catalog
redef abstract class PageMEntity

nitc :: static_html $ PageMEntity

A DocPage documenting a MEntity
redef class PagePerson

nitc :: static_html $ PagePerson

A page that lists the packages maintained and contributed by a person
redef class PageTag

nitc :: static_html $ PageTag

A page that lists the packages related to a tab
redef class Person

nitc :: static_html $ Person

A contributor/author/etc.

All class definitions

redef class DocPage

nitc :: static_html $ DocPage

A documentation page abstraction
redef class DocSidebar

nitc :: static_html $ DocSidebar

Nitdoc sidebar abstraction
redef class DocTab

nitc :: static_html $ DocTab

A documentation tabulated view
class DocTopMenu

nitc $ DocTopMenu

Top menu bar template
redef class HtmlightVisitor

nitc :: static_html $ HtmlightVisitor

Visitor used to produce a HTML tree based on a AST on a Source
redef class MClass

nitc :: static_html $ MClass

A named class
redef class MClassDef

nitc :: static_html $ MClassDef

A definition (an introduction or a refinement) of a class in a module
redef abstract class MEntity

nitc :: static_html $ MEntity

A named and possibly documented entity in the model.
redef class MGroup

nitc :: static_html $ MGroup

A group of modules in a package
redef class MModule

nitc :: static_html $ MModule

A Nit module is usually associated with a Nit source file.
redef class MPackage

nitc :: static_html $ MPackage

A Nit package, that encompass a product
redef abstract class MPropDef

nitc :: static_html $ MPropDef

A definition of a property (local property)
redef abstract class MProperty

nitc :: static_html $ MProperty

A service (global property) that generalize method, attribute, etc.
redef class PageHome

nitc :: static_html $ PageHome

The Nitdoc overview page that displays the nit packages catalog
redef abstract class PageMEntity

nitc :: static_html $ PageMEntity

A DocPage documenting a MEntity
redef class PagePerson

nitc :: static_html $ PagePerson

A page that lists the packages maintained and contributed by a person
redef class PageTag

nitc :: static_html $ PageTag

A page that lists the packages related to a tab
redef class Person

nitc :: static_html $ Person

A contributor/author/etc.
class PiwikScript

nitc $ PiwikScript

JS script for Piwik Tracker
package_diagram nitc::static_html static_html nitc::static_structure static_structure nitc::static_html->nitc::static_structure json json nitc::static_html->json nitc::static_base static_base nitc::static_structure->nitc::static_base parser_base parser_base json->parser_base serialization serialization json->serialization ...nitc::static_base ... ...nitc::static_base->nitc::static_base ...parser_base ... ...parser_base->parser_base ...serialization ... ...serialization->serialization nitc::static_index static_index nitc::static_index->nitc::static_html nitc::static static nitc::static->nitc::static_index nitc::static... ... nitc::static...->nitc::static

Ancestors

module abstract_collection

core :: abstract_collection

Abstract collection classes and services.
module abstract_text

core :: abstract_text

Abstract class for manipulation of sequences of characters
module abstract_tree

trees :: abstract_tree

Introduce tree structures abstraction
module actors_injection_phase

nitc :: actors_injection_phase

Injects model for the classes annotated with "is actor" so
module annotation

nitc :: annotation

Management and utilities on annotations
module array

core :: array

This module introduces the standard array structure.
module astbuilder

nitc :: astbuilder

Instantiation and transformation of semantic nodes in the AST of expressions and statements
module astutil

nitc :: astutil

Additional features on Nit AST
module auto_super_init

nitc :: auto_super_init

Computing of super-constructors that must be implicitly called at the begin of constructors.
module bintree

trees :: bintree

Binary Tree data-structure
module bitset

core :: bitset

Services to handle BitSet
module bktree

trees :: bktree

Implementation of BKTree
module bootstrap

html :: bootstrap

HTML templates for Bootstrap components.
module bytes

core :: bytes

Services for byte streams and arrays
module caching

serialization :: caching

Services for caching serialization engines
module catalog

nitc :: catalog

Basic catalog generator for Nit packages
module check_annotation

nitc :: check_annotation

Check that annotation present in the AST are either primitive or user-declared
module circular_array

core :: circular_array

Efficient data structure to access both end of the sequence.
module codec_base

core :: codec_base

Base for codecs to use with streams
module codecs

core :: codecs

Group module for all codec-related manipulations
module collection

core :: collection

This module define several collection classes.
module commands_base

nitc :: commands_base

Documentation commands
module commands_catalog

nitc :: commands_catalog

Commands to retrieve Catalog related data
module commands_docdown

nitc :: commands_docdown

Doc down related queries
module commands_graph

nitc :: commands_graph

Graph commands
module commands_model

nitc :: commands_model

Doc commands about a Model or a MEntity
module commands_parser

nitc :: commands_parser

A parser that create DocCommand from a string
module commands_usage

nitc :: commands_usage

Commands about how mentities are used
module console

console :: console

Defines some ANSI Terminal Control Escape Sequences.
module core

core :: core

Standard classes and methods used by default by Nit programs and libraries.
module counter

counter :: counter

Simple numerical statistical analysis and presentation
module deriving

nitc :: deriving

Injection of automatic method definitions for standard methods, based on the attributes of the classes
module digraph

graph :: digraph

Implementation of directed graphs, also called digraphs.
module div_by_zero

nitc :: div_by_zero

Detection of divisions by zero in obvious cases
module dot

dot :: dot

Dot rendering library
module engine_tools

serialization :: engine_tools

Advanced services for serialization engines
module environ

core :: environ

Access to the environment variables of the process
module error

json :: error

Intro JsonParseError which is exposed by all JSON reading APIs
module error

core :: error

Standard error-management infrastructure.
module exec

core :: exec

Invocation and management of operating system sub-processes.
module file

core :: file

File manipulations (create, read, write, etc.)
module fixed_ints

core :: fixed_ints

Basic integers of fixed-precision
module fixed_ints_text

core :: fixed_ints_text

Text services to complement fixed_ints
module flat

core :: flat

All the array-based text representations
module flow

nitc :: flow

Intraprocedural static flow.
module frontend

nitc :: frontend

Collect and orchestration of main frontend phases
module gc

core :: gc

Access to the Nit internal garbage collection mechanism
module glsl_validation

nitc :: glsl_validation

Check shader code within Nit modules using the tool glslangValidator
module hash_collection

core :: hash_collection

Introduce HashMap and HashSet.
module highlight

nitc :: highlight

Highlighting of Nit AST
module html

html :: html

HTML output facilities
module html_commands

nitc :: html_commands

Render commands results as HTML
module html_model

nitc :: html_model

Translate mentities to html blocks.
module htmlight

nitc :: htmlight

Highlighting of Nit AST with HTML
module i18n_phase

nitc :: i18n_phase

Basic support of internationalization through the generation of id-to-string tables
module ini

ini :: ini

Read and write INI configuration files
module inspect

serialization :: inspect

Refine Serializable::inspect to show more useful information
module iso8859_1

core :: iso8859_1

Codec for ISO8859-1 I/O
module kernel

core :: kernel

Most basic classes and methods.
module lexer

nitc :: lexer

Lexer and its tokens.
module lexer_work

nitc :: lexer_work

Internal algorithm and data structures for the Nit lexer
module list

core :: list

This module handle double linked lists
module literal

nitc :: literal

Parsing of literal values in the abstract syntax tree.
module loader

nitc :: loader

Loading of Nit source files
module local_var_init

nitc :: local_var_init

Verify that local variables are initialized before their usage
module location

nitc :: location

Nit source-file and locations in source-file
module markdown

markdown :: markdown

Markdown parsing.
module math

core :: math

Mathematical operations
module md5

md5 :: md5

Native MD5 digest implementation as Text::md5
module md_commands

nitc :: md_commands

Render commands results as Markdown
module mdoc

nitc :: mdoc

Documentation of model entities
module meta

meta :: meta

Simple user-defined meta-level to manipulate types of instances as object.
module mmodule

nitc :: mmodule

modules and module hierarchies in the metamodel
module mmodule_data

nitc :: mmodule_data

Define and retrieve data in modules
module model

nitc :: model

Classes, types and properties
module model_base

nitc :: model_base

The abstract concept of model and related common things
module model_collect

nitc :: model_collect

Collect things from the model.
module model_examples

nitc :: model_examples

Examples for Model entities
module model_index

nitc :: model_index

Search things from the Model
module modelbuilder_base

nitc :: modelbuilder_base

Load nit source files and build the associated model
module modelize

nitc :: modelize

Create a model from nit source files
module modelize_class

nitc :: modelize_class

Analysis and verification of class definitions to instantiate model element
module modelize_property

nitc :: modelize_property

Analysis and verification of property definitions to instantiate model element
module more_collections

more_collections :: more_collections

Highly specific, but useful, collections-related classes.
module mpackage

nitc :: mpackage

Modelisation of a Nit package
module native

core :: native

Native structures for text and bytes
module nitpm_shared

nitc :: nitpm_shared

Services related to the Nit package manager
module no_warning

nitc :: no_warning

Fill toolcontext information about blacklisting of warnings.
module numeric

core :: numeric

Advanced services for Numeric types
module opts

opts :: opts

Management of options on the command line
module ordered_tree

ordered_tree :: ordered_tree

Manipulation and presentation of ordered trees.
module parallelization_phase

nitc :: parallelization_phase

Phase generating threads for functions annotated with threaded annotation
module parse_annotations

nitc :: parse_annotations

Simple annotation parsing
module parser

nitc :: parser

Parser.
module parser_base

parser_base :: parser_base

Simple base for hand-made parsers of all kinds
module parser_nodes

nitc :: parser_nodes

AST nodes of the Nit language
module parser_prod

nitc :: parser_prod

Production AST nodes full definition.
module parser_util

nitc :: parser_util

Utils and tools related to parsers and AST
module parser_work

nitc :: parser_work

Internal algorithm and data structures for the Nit parser
module phase

nitc :: phase

Phases of the processing of nit programs
module pipeline

pipeline :: pipeline

Pipelined filters and operations on iterators.
module poset

poset :: poset

Pre order sets and partial order set (ie hierarchies)
module protocol

core :: protocol

module queue

core :: queue

Queuing data structures and wrappers
module range

core :: range

Module for range of discrete objects.
module rbtree

trees :: rbtree

A red–black tree is a data structure which is a type of self-balancing binary search tree.
module re

core :: re

Regular expression support for all services based on Pattern
module regex_phase

nitc :: regex_phase

Check for error in regular expressions from string literals
module ropes

core :: ropes

Tree-based representation of a String.
module safe

serialization :: safe

Services for safer deserialization engines
module scope

nitc :: scope

Identification and scoping of local variables and labels.
module semantize

nitc :: semantize

Process bodies of methods in regard with the model.
module serialization

serialization :: serialization

General serialization services
module serialization_core

serialization :: serialization_core

Abstract services to serialize Nit objects to different formats
module serialization_model_phase

nitc :: serialization_model_phase

Phase generating methods (model-only) to serialize Nit objects
module serialization_read

json :: serialization_read

Services to read JSON: deserialize_json and JsonDeserializer
module serialization_write

json :: serialization_write

Services to write Nit objects to JSON strings: serialize_to_json and JsonSerializer
module simple_misc_analysis

nitc :: simple_misc_analysis

Simple vavious processing on a AST
module sorter

core :: sorter

This module contains classes used to compare things and sorts arrays.
module static

json :: static

Static interface to read Nit objects from JSON strings
module static_base

nitc :: static_base

Base entities shared by all the nitdoc code
module static_cards

nitc :: static_cards

Cards templates for the static documentation
module stream

core :: stream

Input and output streams of characters
module tables

nitc :: tables

Module that interfaces the parsing tables.
module template

template :: template

Basic template system
module text

core :: text

All the classes and methods related to the manipulation of text entities
module time

core :: time

Management of time and dates
module toolcontext

nitc :: toolcontext

Common command-line tool infrastructure than handle options and error messages
module trees

trees :: trees

General module for tree data structures
module trie

trees :: trie

A trie (or prefix tree) is a datastructure used to perform prefix searches.
module typing

nitc :: typing

Intraprocedural resolution of static types and OO-services
module uml

nitc :: uml

Group head module for UML generation services
module uml_base

nitc :: uml_base

Exposes the base class for UML generation of a Model
module uml_class

nitc :: uml_class

Provides facilities of exporting a Model to a UML class diagram
module uml_module

nitc :: uml_module

Services for generation of a UML package diagram based on a Model
module union_find

core :: union_find

union–find algorithm using an efficient disjoint-set data structure
module utf8

core :: utf8

Codec for UTF-8 I/O
module version

nitc :: version

This file was generated by git-gen-version.sh

Parents

module json

json :: json

Read and write JSON formatted text using the standard serialization services
module static_structure

nitc :: static_structure

Composes the pages of the static documentation

Children

module static_index

nitc :: static_index

Manage indexing of Nit model for Nitdoc QuickSearch.

Descendants

module a_star-m

a_star-m

module nitdoc

nitc :: nitdoc

Generator of static API documentation for the Nit language
module static

nitc :: static

Nitdoc generation framework
# Render documentation pages as HTML
module static_html

import static::static_structure
import json

redef class DocPage
	super Template

	# Page url
	var html_url: String is writable, noinit

	# Directory where css, js and other assets can be found
	var shareurl: String is writable, noinit

	# Top menu template if any
	var topmenu: DocTopMenu is writable, noinit

	# Footer content if any
	var footer: nullable Writable = null is writable

	# Render the page as a html template
	fun render(doc: DocModel): Writable do
		# init page options
		self.shareurl = doc.share_url or else "."
		self.footer = doc.custom_footer

		# build page
		init_title(doc)
		init_topmenu(doc)

		# piwik tracking
		var tracker_url = doc.tracker_url
		var site_id = doc.piwik_site_id
		if tracker_url != null and site_id != null then
			piwik_script = new PiwikScript(tracker_url, site_id)
		end
		return self
	end

	# Build page title string
	fun init_title(doc: DocModel) do end

	# Build top menu template if any
	fun init_topmenu(doc: DocModel) do
		topmenu = new DocTopMenu

		var home = new Link("index.html", "Nitdoc")

		var custom_brand = doc.custom_brand
		if custom_brand != null then
			topmenu.brand = new Link("index.html", custom_brand)
			topmenu.items.add new ListItem(home)
		else
			topmenu.brand = home
		end
	end

	# Renders the html `<head>`
	private fun render_head do
		var css = (self.shareurl / "css").html_escape
		var vendors = (self.shareurl / "vendors").html_escape

		addn "<!DOCTYPE html>"
		addn "<head>"
		addn " <meta charset='utf-8'/>"
		addn " <link rel='stylesheet' href='{vendors}/bootstrap/css/bootstrap.min.css'/>"
		addn " <link rel='stylesheet' href='{css}/nitdoc.bootstrap.css'/>"
		addn " <link rel='stylesheet' href='{css}/nitdoc.cards.css'/>"
		addn " <link rel='stylesheet' href='{css}/nitdoc.code.css'/>"
		addn " <link rel='stylesheet' href='{css}/nitdoc.css'/>"
		addn " <link rel='stylesheet' href='{css}/nitdoc.quicksearch.css'/>"
		addn " <title>{title.html_escape}</title>"
		addn "</head>"
		add "<body>"
	end

	# Renders the footer and content
	private fun render_content do
		if tabs.is_empty then return
		if tabs.length == 1 then
			addn tabs.first
			return
		end
		addn "<ul class='nav nav-tabs'>"
		for tab in tabs do
			if tab.is_empty and not tab isa DocTabLink then continue
			addn tab.tab_link
		end
		addn "</ul>"
		addn "<div class='tab-content'>"
		for tab in tabs do
			if tab.is_empty then continue
			addn tab
		end
		addn "</div>"
	end

	# Piwik script to append in the page scripts
	var piwik_script: nullable PiwikScript = null is writable

	# Render JS scripts
	private fun render_footer do
		if footer != null then
			addn "<div class='footer'>"
			add footer.as(not null)
			addn "</div>"
		end
		var vendors = (self.shareurl / "vendors").html_escape
		var js = (self.shareurl / "js").html_escape

		addn "<script src='quicksearch-list.js'></script>"
		addn "<script src='{vendors}/jquery/jquery-1.11.1.min.js'></script>"
		addn "<script src='{vendors}/jquery/jquery-ui-1.10.4.custom.min.js'></script>"
		addn "<script src='{vendors}/bootstrap/js/bootstrap.min.js'></script>"
		addn "<script src='{js}/nitdoc.utils.js'></script>"
		addn "<script src='{js}/nitdoc.quicksearch.js'></script>"

		var piwik_script = self.piwik_script
		if piwik_script != null then
			add piwik_script
		end
		addn "</body>"
		addn "</html>"
	end

	# Render the whole page
	redef fun rendering do
		render_head
		add topmenu
		addn "<div class='container-fluid'>"
		render_content
		addn "</div>"
		render_footer
	end
end

redef class PageHome
	redef var html_url = "index.html"

	redef fun render(doc) do
		main_tab.show_sidebar = false
		return super
	end

	redef fun init_title(doc) do
		title = doc.custom_title or else "Nitdoc"
	end

	redef fun render_content do
		addn "<div class='container'>"
		if tabs.not_empty then
			addn tabs.first
		end
		addn "</div>"
	end
end

redef class PageMEntity
	redef var html_url is lazy do return mentity.html_url
	redef fun init_title(doc) do title = mentity.html_name

	redef fun render_content do
		addn new CardPageHeader(
			mentity.html_declaration.write_to_string,
			mentity.html_namespace.write_to_string)
		super
	end

	redef fun init_topmenu(doc) do
		super
		for m in mentity.nitdoc_breadcrumbs do
			topmenu.add_li new ListItem(new Link(m.html_url, m.html_name))
		end
		topmenu.active_item = topmenu.items.last
	end
end

redef class PagePerson
	redef var html_url is lazy do return person.html_url
end

redef class PageTag
	redef var html_url is lazy do return "tag_{tag.to_cmangle}.html"
end

redef class HtmlightVisitor
	redef fun hrefto(mentity) do return mentity.html_url
end

redef class DocTab
	super Template

	# Show sidebar for this page?
	var show_sidebar = true is writable

	# Tab link for tab headers
	fun tab_link: Template do
		var tpl = new Template
		tpl.addn "<li class='{if is_active then "active" else ""}'>"
		tpl.addn " <a data-toggle='tab' href='#{id}'>"

		var icon = self.icon
		if icon != null then
			tpl.addn "  <span class='glyphicon glyphicon-{icon}'></span>"
		end
		tpl.addn " {title}"
		tpl.addn " </a>"
		tpl.addn "</li>"
		return tpl
	end

	redef fun rendering do
		var has_left = show_sidebar and sidebar.cards.not_empty
		var has_right = metadata.cards.not_empty

		addn "<div class='tab-pane {if is_active then "active" else ""}' id='{id}'>"
		if has_left then
			addn " <div class='col-sm-3'>"
			addn sidebar
			addn " </div>"
		end
		var cols = 12
		if has_left then cols -= 3
		if has_right then cols -= 3
		addn " <div class='col-sm-{cols}'>"
		for card in content do addn card
		addn " </div>"
		if has_right then
			addn " <div class='col-sm-3'>"
			addn metadata
			addn " </div>"
		end
		addn "</div>"
	end
end

redef class DocTabLink

	redef fun tab_link do
		var tpl = new Template
		tpl.addn "<li class='{if is_active then "active" else ""}'>"
		tpl.addn " <a href='{url.html_escape}'>"

		var icon = self.icon
		if icon != null then
			tpl.addn "  <span class='glyphicon glyphicon-{icon}'></span>"
		end
		tpl.addn " {title}"
		tpl.addn " </a>"
		tpl.addn "</li>"
		return tpl
	end

	redef fun rendering do end
end

# Top menu bar template
class DocTopMenu
	super UnorderedList

	# Brand link to display in first position of the top menu
	#
	# This is where you want to put your logo.
	var brand: nullable Link is noinit, writable

	# Active menu item
	#
	# Depends on the current page, this allows to hilighted the current item.
	var active_item: nullable ListItem is noinit, writable

	redef fun rendering do
		addn "<nav class='navbar navbar-default navbar-fixed-top'>"
		addn " <div class='container-fluid'>"
		addn "  <div class='navbar-header'>"
		add  "   <button type='button' class='navbar-toggle' "
		addn "       data-toggle='collapse' data-target='#topmenu-collapse'>"
		addn "    <span class='sr-only'>Toggle menu</span>"
		addn "    <span class='icon-bar'></span>"
		addn "    <span class='icon-bar'></span>"
		addn "    <span class='icon-bar'></span>"
		addn "   </button>"
		var brand = self.brand
		if brand != null then
			add "<span class='navbar-brand'>"
			add brand
			add "</span>"
		end
		addn "  </div>"
		addn "  <div class='collapse navbar-collapse' id='topmenu-collapse'>"
		addn "   <ul class='nav navbar-nav'>"
		for item in items do
			if item == active_item then item.css_classes.add "active"
			add item.write_to_string
		end
		addn "   </ul>"
		addn "   <div id='search-placeholder'>"
		addn "   </div>"
		addn "  </div>"
		addn " </div>"
		addn "</nav>"
	end
end

redef class DocSidebar
	super Template

	redef fun rendering do
		if cards.is_empty then return
		addn "<div id='sidebar'>"
		for card in cards do addn card
		addn "</div>"
	end
end

# JS script for Piwik Tracker
class PiwikScript
	super Template

	# Piwik URL to use for this tracker
	var tracker_url: String

	# Site ID used on Piwik system
	var site_id: String

	redef fun rendering do
		addn "<script>"

		var site_id = self.site_id.to_json
		var tracker_url = self.tracker_url.trim
		if tracker_url.chars.last != '/' then tracker_url += "/"
		tracker_url = "://{tracker_url}".to_json

		addn "<!-- Piwik -->"
		addn "var _paq = _paq || [];"
		addn " _paq.push([\"trackPageView\"]);"
		addn " _paq.push([\"enableLinkTracking\"]);"
		addn "(function() \{"
		addn " var u=((\"https:\" == document.location.protocol) ? \"https\" : \"http\") + {tracker_url};"
		addn " _paq.push([\"setTrackerUrl\", u+\"piwik.php\"]);"
		addn " _paq.push([\"setSiteId\", {site_id}]);"
		addn " var d=document, g=d.createElement(\"script\"), s=d.getElementsByTagName(\"script\")[0]; g.type=\"text/javascript\";"
		addn " g.defer=true; g.async=true; g.src=u+\"piwik.js\"; s.parentNode.insertBefore(g,s);"
		addn "\})();"

		addn "</script>"
	end
end

# Model redefs

redef class MEntity
	redef fun to_dot_node do
		var node = super
		node["URL"] = html_url
		return node
	end

	redef var html_url = "{html_id}.html" is lazy
end

redef class MPackage
	redef var html_url is lazy do return "package_{super}"
end

redef class MGroup
	redef var html_url is lazy do return "group_{super}"
end

redef class MModule
	redef var html_url is lazy do return "module_{super}"
end

redef class MClass
	redef var html_url is lazy do return "class_{super}"
end

redef class MClassDef
	redef var html_url is lazy do
		if is_intro then return mclass.html_url
		return "{mclass.html_url}?def=def_code_{html_id}#lin"
	end
end

redef class MProperty
	redef var html_url is lazy do return "property_{super}"
end

redef class MPropDef
	redef var html_url is lazy do
		if is_intro then return mproperty.html_url
		return "{mproperty.html_url}?def=def_code_{html_id}#lin"
	end
end

redef class Person
	redef var html_url = "person_{html_id}.html" is lazy
end
src/doc/static/static_html.nit:15,1--412,3