diff options
Diffstat (limited to 'pylint/pyreverse/mermaidjs_printer.py')
-rw-r--r-- | pylint/pyreverse/mermaidjs_printer.py | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/pylint/pyreverse/mermaidjs_printer.py b/pylint/pyreverse/mermaidjs_printer.py index a8f3c576b..61d0d7948 100644 --- a/pylint/pyreverse/mermaidjs_printer.py +++ b/pylint/pyreverse/mermaidjs_printer.py @@ -1,6 +1,6 @@ # Licensed under the GPL: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html -# For details: https://github.com/PyCQA/pylint/blob/main/LICENSE -# Copyright (c) https://github.com/PyCQA/pylint/blob/main/CONTRIBUTORS.txt +# For details: https://github.com/pylint-dev/pylint/blob/main/LICENSE +# Copyright (c) https://github.com/pylint-dev/pylint/blob/main/CONTRIBUTORS.txt """Class to generate files in mermaidjs format.""" @@ -17,12 +17,10 @@ class MermaidJSPrinter(Printer): NODES: dict[NodeType, str] = { NodeType.CLASS: "class", - NodeType.INTERFACE: "class", NodeType.PACKAGE: "class", } ARROWS: dict[EdgeType, str] = { EdgeType.INHERITS: "--|>", - EdgeType.IMPLEMENTS: "..|>", EdgeType.ASSOCIATION: "--*", EdgeType.AGGREGATION: "--o", EdgeType.USES: "-->", @@ -46,7 +44,6 @@ class MermaidJSPrinter(Printer): # pylint: disable=duplicate-code if properties is None: properties = NodeProperties(label=name) - stereotype = "~~Interface~~" if type_ is NodeType.INTERFACE else "" nodetype = self.NODES[type_] body = [] if properties.attrs: @@ -60,7 +57,7 @@ class MermaidJSPrinter(Printer): line += f" {get_annotation_label(func.returns)}" body.append(line) name = name.split(".")[-1] - self.emit(f"{nodetype} {name}{stereotype} {{") + self.emit(f"{nodetype} {name} {{") self._inc_indent() for line in body: self.emit(line) |