Home ⌂Doc Index ◂Up ▴

eric6.Utilities.BackgroundClient

Module implementing a Qt free version of a background client for the various checkers and other python interpreter dependent functions.

Global Attributes

None

Classes

BackgroundClient Class implementing the main part of the background client.

Functions

None


BackgroundClient

Class implementing the main part of the background client.

Derived from

object

Class Attributes

None

Class Methods

None

Methods

BackgroundClient Constructor of the BackgroundClient class.
__cancelled Private method to check for a job cancellation.
__initClientService Private method to import the given module and register it as service.
__peek Private methode to peek the given length of bytes.
__receive Private methode to receive the given length of bytes.
__send Private method to send a job response back to the BackgroundService.
run Public method implementing the main loop of the client.

Static Methods

None

BackgroundClient (Constructor)

BackgroundClient(host, port, maxProcs)

Constructor of the BackgroundClient class.

host (str)
ip address the background service is listening
port (int)
port of the background service
maxProcs (int)
maximum number of CPUs (processes) to use (0 = determined automatically)

BackgroundClient.__cancelled

__cancelled()

Private method to check for a job cancellation.

Returns:
flag indicating a cancellation (boolean)

BackgroundClient.__initClientService

__initClientService(fn, path, module)

Private method to import the given module and register it as service.

fn
service name to register (str)
path
contains the path to the module (str)
module
name to import (str)
Returns:
text result of the import action (str)

BackgroundClient.__peek

__peek(length)

Private methode to peek the given length of bytes.

length
bytes to receive (int)
Returns:
received bytes (bytes)

BackgroundClient.__receive

__receive(length)

Private methode to receive the given length of bytes.

length
bytes to receive (int)
Returns:
received bytes or None if connection closed (bytes)

BackgroundClient.__send

__send(fx, fn, data)

Private method to send a job response back to the BackgroundService.

fx
remote function name to execute (str)
fn
filename for identification (str)
data
return value(s) (any basic datatype)

BackgroundClient.run

run()

Public method implementing the main loop of the client.

Raises RuntimeError:
raised if hashes don't match
Up



Home ⌂Doc Index ◂Up ▴