gamnit: extract Cuboid as super class to cube and intro Boxed3d::to_mesh
[nit.git] / src / doc / doc_commands.nit
index 7241742..1537704 100644 (file)
@@ -19,8 +19,6 @@
 # * `nitdoc` wikilinks like `[[doc: MEntity::name]]`
 module doc_commands
 
-import doc_base
-
 # A command aimed at a documentation tool like `nitdoc` or `nitx`.
 #
 # `DocCommand` are generally of the form `command: args`.
@@ -45,6 +43,8 @@ interface DocCommand
                        return new ArticleCommand(command_string)
                else if command_string.has_prefix("comment:") then
                        return new CommentCommand(command_string)
+               else if command_string.has_prefix("list:") then
+                       return new ListCommand(command_string)
                else if command_string.has_prefix("param:") then
                        return new ParamCommand(command_string)
                else if command_string.has_prefix("return:") then
@@ -55,6 +55,8 @@ interface DocCommand
                        return new CallCommand(command_string)
                else if command_string.has_prefix("code:") then
                        return new CodeCommand(command_string)
+               else if command_string.has_prefix("graph:") then
+                       return new GraphCommand(command_string)
                end
                return new UnknownCommand(command_string)
        end
@@ -107,6 +109,13 @@ class CommentCommand
        super AbstractDocCommand
 end
 
+# A `DocCommand` that includes a list of something.
+#
+# Syntax: `list:kind: <arg>`.
+class ListCommand
+       super AbstractDocCommand
+end
+
 # A `DocCommand` that includes the list of methods tanking a `MType` as parameter.
 #
 # Syntax: `param: MType`.
@@ -144,3 +153,11 @@ end
 class CodeCommand
        super AbstractDocCommand
 end
+
+# A `DocCommand` that display an graph for a `MEntity`.
+#
+# Syntax:
+# * `graph: MEntity::name`
+class GraphCommand
+       super AbstractDocCommand
+end