Skip to content
Martin Davtyan edited this page Jun 6, 2015 · 11 revisions

Methods

Algorithms working with Excel data are going to be implemented as methods of the Context object. This object is loaded into the memory throughout the entire lifetime of Worker. Data written by one method should be accessible to other methods.

 _______    events    _________
|       |   ----->   | Worker  |
| Excel |            |(runtime)|
|_______|   <-----   |_________|
            actions

Method overview

What we need to do What needs to be stored
Header detection Position of header, column names on every sheet
Table detection Position of beginning and end of table on every sheet
Error detection for columns Column validation features (numpy.array's)
Autofill from another column (in another sheet) A sequence of previously entered cells with their position
Selecting elements that user highlights A sequence of previously highlighted elements

Events

Event name Triggered when Information contained (passed to Worker)
WorkbookOpen New Excel file is open Name of file
WorkbookBeforeClose Before the Excel file is closed Name of file
SheetChange Any cell is changed A new value of a cell, it's metaparameters (formatting, etc, could serialize Excel Cell object into a dict) and a cell address
UndoComnsenseChange User presses Undo after comnsense changed something ComnsenseActionID to be cancelled
RangeResponse Range requested by the worker is retrieved List of values (need to check this)

Actions

Action name Description Information contained (passed to Excel)
ComnsenseChange Change the sheet based on comnsense inference (color cell red, autofill, etc.) Range address and range values in Python format
RangeRequest Request values for an Excel range (A1:A10, C3:D4, etc, see Range object Range

Clone this wiki locally