src/eric7/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckService.py

branch
eric7
changeset 10341
3fdffd9cc21d
parent 9972
68ac01294544
child 10373
093dcebe5ecb
--- a/src/eric7/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckService.py	Fri Nov 24 14:59:26 2023 +0100
+++ b/src/eric7/Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckService.py	Sat Nov 25 18:19:21 2023 +0100
@@ -48,9 +48,12 @@
         """
         Private method to determine the language of the file.
 
-        @param filename of the sourcefile (str)
-        @param source code of the file (str)
-        @return language of the file or None if not found (str or None)
+        @param filename of the sourcefile
+        @type str
+        @param source code of the file
+        @type str
+        @return language of the file or None if not found
+        @rtype str or None
         """
         pyVer = PythonUtilities.determinePythonVersion(filename, source)
         if pyVer:
@@ -66,17 +69,24 @@
         """
         Public method to register a new language to the supported languages.
 
-        @param lang new language to check syntax (str)
-        @param env the environment in which the checker is implemented (str)
-        @param path full path to the module (str)
-        @param module name to import (str)
+        @param lang new language to check syntax
+        @type str
+        @param env the environment in which the checker is implemented
+        @type str
+        @param path full path to the module
+        @type str
+        @param module name to import
+        @type str
         @param getArgs function to collect the required arguments to call the
-            syntax checker on client side (function)
+            syntax checker on client side
+        @type function
         @param getExt function that returns the supported file extensions of
-            the syntax checker (function)
-        @param callback function on service response (function)
+            the syntax checker
+        @type function
+        @param callback function on service response
+        @type function
         @param onError callback function if client or service isn't available
-            (function)
+        @type function
         """
         self.__supportedLanguages[lang] = env, getArgs, getExt
         # Connect to the background service
@@ -94,7 +104,8 @@
         """
         Public method to return the supported language names.
 
-        @return list of languanges supported (list of str)
+        @return list of languanges supported
+        @rtype list of str
         """
         return list(self.__supportedLanguages.keys()) + ["MicroPython"]
 
@@ -102,7 +113,8 @@
         """
         Public method to remove the language from syntax check.
 
-        @param lang language to remove (str)
+        @param lang language to remove
+        @type str
         """
         self.__supportedLanguages.pop(lang, None)
         self.backgroundService.serviceDisconnect("{0}Syntax".format(lang), lang)
@@ -112,7 +124,8 @@
         Public method to return all supported file extensions for the
         syntax checker dialog.
 
-        @return set of all supported file extensions (set of str)
+        @return set of all supported file extensions
+        @rtype set of str
         """
         extensions = set()
         for _env, _getArgs, getExt in self.__supportedLanguages.values():
@@ -154,8 +167,9 @@
         """
         Public method to prepare a syntax check on multiple source files.
 
-        @param argumentsList list of arguments tuples with each tuple
-            containing filename and source (string, string)
+        @param argumentsList list of argument tuples with each tuple
+            containing filename and source
+        @type list of tuples of (str, str)
         """
         data = {}
         for lang in self.getLanguages():
@@ -203,8 +217,10 @@
         """
         Private slot handling service errors.
 
-        @param fn file name (string)
-        @param msg message text (string)
+        @param fn file name
+        @type str
+        @param msg message text
+        @type str
         """
         self.error.emit(fn, msg)
 
@@ -212,10 +228,14 @@
         """
         Public method handling service errors for Python 3.
 
-        @param fx service name (string)
-        @param lang language (string)
-        @param fn file name (string)
-        @param msg message text (string)
+        @param fx service name
+        @type str
+        @param lang language
+        @type str
+        @param fn file name
+        @type str
+        @param msg message text
+        @type str
         """
         if fx in ["Python3Syntax", "batch_Python3Syntax"]:
             if fx == "Python3Syntax":
@@ -228,10 +248,14 @@
         """
         Public method handling service errors for JavaScript.
 
-        @param fx service name (string)
-        @param lang language (string)
-        @param fn file name (string)
-        @param msg message text (string)
+        @param fx service name
+        @type str
+        @param lang language
+        @type str
+        @param fn file name
+        @type str
+        @param msg message text
+        @type str
         """
         if fx in ["JavaScriptSyntax", "batch_JavaScriptSyntax"]:
             if fx == "JavaScriptSyntax":
@@ -244,10 +268,14 @@
         """
         Public method handling service errors for YAML.
 
-        @param fx service name (string)
-        @param lang language (string)
-        @param fn file name (string)
-        @param msg message text (string)
+        @param fx service name
+        @type str
+        @param lang language
+        @type str
+        @param fn file name
+        @type str
+        @param msg message text
+        @type str
         """
         if fx in ["YAMLSyntax", "batch_YAMLSyntax"]:
             if fx == "YAMLSyntax":
@@ -260,10 +288,14 @@
         """
         Public method handling service errors for JSON.
 
-        @param fx service name (string)
-        @param lang language (string)
-        @param fn file name (string)
-        @param msg message text (string)
+        @param fx service name
+        @type str
+        @param lang language
+        @type str
+        @param fn file name
+        @type str
+        @param msg message text
+        @type str
         """
         if fx in ["JSONSyntax", "batch_JSONSyntax"]:
             if fx == "JSONSyntax":
@@ -276,10 +308,14 @@
         """
         Public method handling service errors for TOML.
 
-        @param fx service name (string)
-        @param lang language (string)
-        @param fn file name (string)
-        @param msg message text (string)
+        @param fx service name
+        @type str
+        @param lang language
+        @type str
+        @param fn file name
+        @type str
+        @param msg message text
+        @type str
         """
         if fx in ["TOMLSyntax", "batch_TOMLSyntax"]:
             if fx == "TOMLSyntax":
@@ -292,8 +328,10 @@
         """
         Public slot handling the completion of a batch job.
 
-        @param fx service name (string)
-        @param lang language (string)
+        @param fx service name
+        @type str
+        @param lang language
+        @type str
         """
         if fx in [
             "Python3Syntax",

eric ide

mercurial