Use Cases for CCP4i

This document outlines the operations which are performed on the database using CCP4i. Some operations are initiated by the user, which then cause CCP4i to perform a series of operations in order to accomplish the requested task.

The purpose of this document is make it more clear what the requirements are within the current version of CCP4i for the database backend.

Case 1: Start-up

Case 2: Open Project

Case 2a: Open Project Database

This is handled by the command DbOpen within CCP4i.

Case 2b: Change Project

This is performed by the DbChange procedure:

Case 3: Create a New Project

CCP4i has no explicit command to create a new project - this happens implicitly the first time the user changes to a project for the first time (see case 2b).

Case 4: Run a Job

Case 4a: Run a Job

The run_command procedure (in runjob.tcl) is the driving procedure for running jobs within CCP4i. Strictly speaking running a job is not part of the database functionality however it is instructive to know how this interacts with the database.

Case 4b: Running job communicates with database

Running jobs are independent processes to the main CCP4i process. A running job can communicate with the database via the main CCP4i process and has a limited number of commands which are available to the scripts from the execute.tcl file:

RunNotification is called from ExecuteScript and opens a socket to the main CCP4i process which remains open for the lifetime of the job. This socket is used by the remaining commands below to pass data to the database:

Note that it is possible for scripts not written in Tcl to also be run in which case there is a separate mechanism to allow them to communicate with the database and issue the above commands.

A running job may also communicate with the main CCP4i process in the "Run&View Com File" mode. This is so that the main process can throw up the window which allows the user to edit the keyworded script for a program prior to it being run.

Case 5: View Files from Job

Case 6: Edit Job Data

Case 6a: Read/Edit Notebook

Case 6b: Edit Job Data

Case 6c: Enter Data for External Job

Case 7: Delete/Archive and Clean-up of Jobs

Case 8: Display Job List