+
+ # Can we accept this `mentity` in the view regarding its fictivity?
+ fun accept_fictive(mentity: MEntity): Bool do
+ if include_fictive then return true
+ return not mentity.is_fictive
+ end
+
+ # Should we accept mentities with empty documentation?
+ #
+ # Default is `true`.
+ var include_empty_doc = true is writable
+
+ # Can we accept this `mentity` regarding its documentation?
+ fun accept_empty_doc(mentity: MEntity): Bool do
+ if include_empty_doc then return true
+ return mentity.mdoc != null
+ end
+
+ # Should we accept nitunit test suites?
+ #
+ # Default is `false`.
+ var include_test_suite = false is writable
+
+ # Can we accept this `mentity` regarding its test suite status?
+ fun accept_test_suite(mentity: MEntity): Bool do
+ if include_test_suite then return true
+ if not mentity isa MModule then return true
+ return not mentity.is_test_suite
+ end
+
+ # Should we accept `MAttribute` instances?
+ #
+ # Default is `true`.
+ var include_attribute = true is writable
+
+ # Can we accept this `mentity` regarding its type?
+ fun accept_attribute(mentity: MEntity): Bool do
+ if include_attribute then return true
+ if mentity isa MAttribute then return false
+ if mentity isa MAttributeDef then return false
+ return true
+ end
+
+ # Should we accept this `mentity` from the view?
+ fun accept_mentity(mentity: MEntity): Bool do
+ if not accept_visibility(mentity) then return false
+ if not accept_fictive(mentity) then return false
+ if not accept_empty_doc(mentity) then return false
+ if not accept_test_suite(mentity) then return false
+ if not accept_attribute(mentity) then return false
+ return true
+ end
+