eric7.Plugins.CheckerPlugins.SyntaxChecker.jsonCheckSyntax

Module implementing the syntax check for JSON.

Global Attributes

None

Classes

None

Functions

__jsonSyntaxCheck Function to check a JSON source file for syntax errors.
initBatchService Initialize the batch service and return the entry point.
initService Initialize the service and return the entry point.
jsonSyntaxBatchCheck Module function to check syntax for a batch of files.
jsonSyntaxCheck Function to check a JSON source file for syntax errors.
workerTask Module function acting as the parallel worker for the syntax check.


__jsonSyntaxCheck

__jsonSyntaxCheck(file, codestring)

Function to check a JSON source file for syntax errors.

file (str)
source filename
codestring (str)
string containing the code to check
Return:
list of dictionaries with the key 'error' which contain a tuple with details about the syntax error. Each tuple contains the file name, line number, column, code string and the error message.
Return Type:
list of dict
Up


initBatchService

initBatchService()

Initialize the batch service and return the entry point.

Return:
the entry point for the background client
Return Type:
function
Up


initService

initService()

Initialize the service and return the entry point.

Return:
the entry point for the background client
Return Type:
function
Up


jsonSyntaxBatchCheck

jsonSyntaxBatchCheck(argumentsList, send, fx, cancelled, maxProcesses=0)

Module function to check syntax for a batch of files.

argumentsList (list)
list of arguments tuples as given for jsonSyntaxCheck
send (function)
reference to send function
fx (str)
registered service name
cancelled (function)
reference to function checking for a cancellation
maxProcesses (int)
number of processes to be used
Up


jsonSyntaxCheck

jsonSyntaxCheck(file, codestring)

Function to check a JSON source file for syntax errors.

file (str)
source filename
codestring (str)
string containing the code to check
Return:
list of dictionaries with the key 'error' which contain a tuple with details about the syntax error. Each tuple contains the file name, line number, column, code string and the error message.
Return Type:
list of dict
Up


workerTask

workerTask(inputQueue, outputQueue)

Module function acting as the parallel worker for the syntax check.

inputQueue (multiprocessing.Queue)
input queue
outputQueue (multiprocessing.Queue)
output queue
Up