eric3.UI.SingleApplication

Module implementing the single application server and client.

Classes

SingleApplicationClient Class implementing the single application server embedded within the IDE.
SingleApplicationServer Class implementing the single application server embedded within the IDE.

Functions

None

SingleApplicationClient

Class implementing the single application server embedded within the IDE.

Derived from

Methods

SingleApplicationClient Constructor
connect Public method to connect the single application client to its server.
errstr Public method to return a meaningful error string for the last error.
openFile Private method to open a file in the application server.
openProject Private method to open a project in the application server.
processArgs Public method to process the command line args passed to the UI.
sendArguments Private method to set the command arguments in the application server.
sendCommand Private method to send the command to the application server.

SingleApplicationClient (Constructor)

SingleApplicationClient()

Constructor

SingleApplicationClient.connect

connect()

Public method to connect the single application client to its server.

Returns:
value indicating success or an error number. Value is one of:
0No application is running
1Application is already running
-1The lock file could not be read
-2The lock file is corrupt

SingleApplicationClient.errstr

errstr()

Public method to return a meaningful error string for the last error.

Returns:
error string for the last error (string)

SingleApplicationClient.openFile

openFile(fname)

Private method to open a file in the application server.

fname
name of file to be opened (string)

SingleApplicationClient.openProject

openProject(pfname)

Private method to open a project in the application server.

pfname
name of the projectfile to be opened (string)

SingleApplicationClient.processArgs

processArgs(args)

Public method to process the command line args passed to the UI.

args
list of files to open

SingleApplicationClient.sendArguments

sendArguments(argsStr)

Private method to set the command arguments in the application server.

argsStr
space delimited list of command args (string)

SingleApplicationClient.sendCommand

sendCommand(cmd)

Private method to send the command to the application server.

cmd
command to be sent (string)

Up

SingleApplicationServer

Class implementing the single application server embedded within the IDE.

Derived from

QServerSocket

Methods

SingleApplicationServer Constructor
handleClosed Private method to handle the closure of the socket.
handleLine Private method to handle data from the client.
newConnection Reimplemented to handle a new connection.
saArguments Private method used to handle the "Arguments" command.
saOpenFile Private method used to handle the "Open File" command.
saOpenProject Private method used to handle the "Open Project" command.
shutdown Public method used to shut down the server.

SingleApplicationServer (Constructor)

SingleApplicationServer()

Constructor

SingleApplicationServer.handleClosed

handleClosed()

Private method to handle the closure of the socket.

SingleApplicationServer.handleLine

handleLine()

Private method to handle data from the client.

SingleApplicationServer.newConnection

newConnection(sockfd)

Reimplemented to handle a new connection.

sockfd
the socket descriptor

SingleApplicationServer.saArguments

saArguments(argsStr)

Private method used to handle the "Arguments" command.

argsStr
space delimited list of command args(string)

SingleApplicationServer.saOpenFile

saOpenFile(fname)

Private method used to handle the "Open File" command.

fname
filename to be opened (string)

SingleApplicationServer.saOpenProject

saOpenProject(pfname)

Private method used to handle the "Open Project" command.

pfname
filename of the project to be opened (string)

SingleApplicationServer.shutdown

shutdown()

Public method used to shut down the server.

Up