mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-11-30 22:31:21 -07:00
Add typing for file and settings.
Add diagnostic generator documentation
This commit is contained in:
parent
f49f8b3cb8
commit
d19f1f3e42
4 changed files with 11 additions and 4 deletions
|
|
@ -1,11 +1,17 @@
|
|||
from abc import ABC, abstractmethod
|
||||
from pathlib import Path
|
||||
from typing import Iterator
|
||||
|
||||
from ..diagnostic import Diagnostic
|
||||
|
||||
|
||||
class DiagnosticGenerator(ABC):
|
||||
def __init__(self, file, settings) -> None:
|
||||
def __init__(self, file: Path, settings: dict) -> None:
|
||||
""" Yields Diagnostics for file, these are suggested text replacements based on formatting rules in settings.
|
||||
|
||||
@param file: A file to generate diagnostics for
|
||||
@param settings: A list of settings containing rules for creating diagnostics
|
||||
"""
|
||||
self._settings = settings
|
||||
self._file = file
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue