neo_doxygen: Read the `prot` attribute of the `innerclass` elements.
[nit.git] / contrib / neo_doxygen / src / doxml / compounddef.nit
index 64a301d..5f00313 100644 (file)
@@ -94,16 +94,17 @@ class CompoundDefListener
        redef fun entity: Entity do return compound
 
        redef fun start_dox_element(local_name: String, atts: Attributes) do
-               if ["compoundname", "innerclass", "innernamespace"].has(local_name) then
+               if "compoundname" == local_name then
                        text.listen_until(dox_uri, local_name)
-                       if ["innerclass", "innernamespace"].has(local_name) then
-                               refid = get_required(atts, "refid")
-                       end
-               else if "basecompoundref" == local_name then
-                       refid = get_optional(atts, "refid", "")
+               else if ["innerclass", "innernamespace", "basecompoundref"].has(local_name) then
                        prot = get_optional(atts, "prot", "")
-                       virt = get_optional(atts, "virt", "")
                        text.listen_until(dox_uri, local_name)
+                       if "basecompoundref" == local_name then
+                               refid = get_optional(atts, "refid", "")
+                               virt = get_optional(atts, "virt", "")
+                       else
+                               refid = get_required(atts, "refid")
+                       end
                else if "memberdef" == local_name then
                        read_member(atts)
                else if local_name == "sectiondef" then
@@ -122,7 +123,7 @@ class CompoundDefListener
                if local_name == "compoundname" then
                        compound.full_name = text.to_s
                else if local_name == "innerclass" then
-                       compound.declare_class(refid, text.to_s)
+                       compound.declare_class(refid, text.to_s, prot)
                else if local_name == "innernamespace" then
                        compound.declare_namespace(refid, text.to_s)
                else if "memberdef" == local_name then