1 # This file is part of NIT ( http://www.nitlanguage.org ).
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
15 # Create DocPage instances for each documentated Mentity.
20 # ExtractionPhase populates the DocModel with DocPage.
24 # Instanciates documentation pages for the given DocModel.
26 doc
.pages
.add
new OverviewPage("Overview")
27 doc
.pages
.add
new SearchPage("Index")
28 for mgroup
in doc
.mgroups
do
29 doc
.pages
.add
new MGroupPage(mgroup
.nitdoc_id
, mgroup
)
31 for mmodule
in doc
.mmodules
do
32 doc
.pages
.add
new MModulePage(mmodule
.nitdoc_id
, mmodule
)
34 for mclass
in doc
.mclasses
do
35 doc
.pages
.add
new MClassPage(mclass
.nitdoc_id
, mclass
)
37 for mproperty
in doc
.mproperties
do
38 doc
.pages
.add
new MPropertyPage(mproperty
.nitdoc_id
, mproperty
)
43 # The Nitdoc overview page.
48 # The Nidoc full index page.
53 # A DocPage documenting a MEntity.
57 # Type of MEntity documented by this page.
60 # MEntity documented by this page.
64 # A documentation page about a MGroup.
68 redef type MENTITY: MGroup
71 # A documentation page about a MModule.
75 redef type MENTITY: MModule
78 # A documentation page about a MClass.
82 redef type MENTITY: MClass
85 # A documentation page about a MProperty.
89 redef type MENTITY: MProperty