Changes between Version 8 and Version 9 of PRO_CHANGE_PRIMITIVES_R0


Ignore:
Timestamp:
01/26/09 16:31:03 (16 years ago)
Author:
gogov
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • PRO_CHANGE_PRIMITIVES_R0

    v8 v9  
    44 
    55= Analysis = 
     6== Overview == 
     7Changes should be able to be decomposed into ProLib primitives. 
    68 
    7 == Overview == 
     9The set of ProLib primitives should have the following characteristics: 
     10 * each primitive should be representable as a plain-text string of characters 
     11 * all the primitives together should describe some sort of a language which should correspond to all the functionality which the ProLib provides 
     12  * this way everything that happens inside Sophie 2 should be representable as some sort of a program written in this language 
     13  * this program could then be easily: 
     14   * transmitted to a server over the network 
     15   * viewable and understandable for debugging purposes 
     16   * converted to appropriate ProLib functions 
     17 * both primitives and changes form the type of information that will be stored in the ChangeManager 
    818 
    9 This task is about the primitives that are needed to manage changes. These include primitive operations about changes. 
     19This task is to develop a set of primitives which fulfills the requirements above. 
    1020 
    1121== Task requirements == 
    12  * Primitive operations about changes which include the following: 
    13   * create - which should create a change which should have an id. The design section should decide on the uniqueness of the id of a change. This is needed to manage changes on a server for example. 
    14   * destroy - which should destroy a change by an id. 
    15   * set - should be able to set the change with an id for a property. This will be helpful if for example a change is to be altered so that consistency is kept. There will occur situation with changes on a server where some part of a composite change should be altered. Imagine for example several people managing a book at the same time. 
    16  * Changes types: 
    17   * Change - a simple change. 
    18   * !GroupChange - a composite change that is constructed of simple changes. 
    19   * !UnmanagedChange - a change that is supposed to be managed in a special way. Its undo and redo will be implemented as the situation requires. For example - save a book may be a unmanaged change. If the user creates a frame with a movie content (with a media file of over 700Mb), deletes the frame, deletes the media file and requests a undo - the change may become a unmanaged. If the user had not deleted the media file the change would have been a normal change that can be undone. 
    20   * '''Note''' - the primitive operations described above should be possible having in mind these types of changes. Also have in mind that the change types are already implemented in one way or another. 
    21  * A decent documentation should be created that explains the primitives - change types and operations with them. 
     22 * Primitives should include the following operations: 
     23  * ''create'' 
     24   * each object the ''create'' primitive creates should have a unique id 
     25   * this primitive should be able to create a ProObject and return its id 
     26   * or create a Property for a given ProObject and return its id 
     27   * create a ProList and  return its id 
     28  * ''destroy'' 
     29   * should destroy an object given its id 
     30  * ''set'' 
     31   * should be able to set a value to an object given its id 
     32 * A few ProList operations should be available: 
     33  * ''add'' 
     34   * adds an object to a ProList given its id and position to be added to 
     35  * ''remove'' 
     36   * removes an object from a ProList given its id and position to be removed from 
     37  * the ''set'' operation should be adapted to accept a ProList, object and a position and should assign the given object to the given position in the given ProList 
     38 
     39 * All ids used should be unique 
     40 
     41 * Synchronization problems with list operations should be considered 
     42  * An idea for solving those problems should be proposed 
     43 
     44 * Add more operations if needed 
     45 
     46 * Describe Changes decomposition to Change primitives, its purpose and provide a use-case 
    2247 
    2348== Task result == 
    24  * Source code 
    25  * wiki page somewhere - may be only a wiki content in the design section. 
     49 * Rough implementation 
     50 * Good description of the primitives 
     51 * Use-case for the primitives with diagrams 
    2652 
    2753== Implementation idea == 
    28  * look at the code in [source:trunk/sophie2-platform/modules/org.sophie2.core/src/main/java/org/sophie2/core/prolib/events Changes] types in event package to get an idea. 
    29  * decide on a way to create the different operations. 
    30  * decide which of the change are to be unmanaged. 
    31  * implement what is to be implemented. 
    32  * describe how to use changes. 
     54 * For the use case describe what happens when a Sophie client is connected to a Sophie server and how the ChangeManagers running on both sides work together 
    3355 
    3456== Related == 
     
    3860[wiki:PRO_CHANGE_COMPOSING_R0] [[BR]] 
    3961[wiki:PRO_CHANGE_MANAGER_R0] [[BR]] 
     62[wiki:PRO_CHANGE_UNDO_MANAGER_R0]  
    4063 
    4164== How to demo == 
    42  * run unit tests about change. 
    43  * show the wiki content. 
     65 * Show primitives set description 
     66 * Show and explain the use case 
    4467 
    4568= Design =