CN108228168A - A kind of revocation, the abstract method of recovery operation - Google Patents

A kind of revocation, the abstract method of recovery operation Download PDF

Info

Publication number
CN108228168A
CN108228168A CN201711478957.7A CN201711478957A CN108228168A CN 108228168 A CN108228168 A CN 108228168A CN 201711478957 A CN201711478957 A CN 201711478957A CN 108228168 A CN108228168 A CN 108228168A
Authority
CN
China
Prior art keywords
revocation
class
abstract
definition
defines
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201711478957.7A
Other languages
Chinese (zh)
Inventor
郁海涛
许登峰
王广越
冯艳霞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Anhui Fangzheng Medical Information Technology Co Ltd
Original Assignee
Anhui Fangzheng Medical Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Anhui Fangzheng Medical Information Technology Co Ltd filed Critical Anhui Fangzheng Medical Information Technology Co Ltd
Priority to CN201711478957.7A priority Critical patent/CN108228168A/en
Publication of CN108228168A publication Critical patent/CN108228168A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/33Intelligent editors

Abstract

The invention discloses the abstract methods of a kind of revocation, recovery operation, are as follows:Operate abstract class definition;Class definition is realized in operation;Operational administrative class defines, and defines the abstract class of editing machine operation, and defines execution, revocation, restores three methods;Declaration definition specifically operates class, including adding, deleting, moving, editing these operations, the operation abstract class that concrete operations Similar integral defines, and it realizes the execution of its declaration definition, revocation, restore three methods, the step (3) is responsible for the initialization of active stack, the stacking of concrete operations, the management of Pop operations.There are the present invention other data unrelated with operation not need to then record, and reduces the degree of coupling between program, adds new operational order and be easy to, the advantages that easily realizing revocation and restore function.

Description

A kind of revocation, the abstract method of recovery operation
Technical field
The present invention relates to the abstract methods of computer technology development field, specifically a kind of revocation, recovery operation.
Background technology
Revocation, recovery operation are that the software institute of many specific editting functions is indispensable.Most typically two types are exactly Text editing and image editing software, revocation are that the operation for doing user's previous step changes caused by program and is restored to change Before, and recovery operation refers to realize this change again.
Documents (103400012B) disclose arbitrary in a kind of replicated collaborative computer aided design system Undo/Redo methods after website receives Undo orders, position molding operation O and are judged whether in local operation historical record It is cancelled by concurrent Undo.If O and its dependence operation set are not set as engineering noise, O is obtained in model state record by Undo Model state during execution performs execution and the still operation of " effective " after molding operation O, Undo will be corresponded in the USV of O and given birth to Component into website increases by 1.After collaborative site receives Redo orders, the molding operation O that wants Redo is being locally-located, and judge O Whether it is concurrent Undo targets.If so, each collaborative site is waited for all to agree to that Redo operates O;If it is not, then it is based on "current" model State performs O.This method can be in the environment of multi-user collaborative editor, arbitrary under the premise of user's operation wish is kept Moment, arbitrary selection operation carry out Undo and Redo, and keep result consistent on each website, one during the realization of software As realization method have:Data method for recording when data method for recording refers to open information editing's window, preserves original number According to the result data after then record user operates every time, data here refer to be likely to occur in information editing's window The data of variation.The data before user's previous action are transmitted to the corresponding control of information editing's window by program when doing destruction operation. This way is changed the time with space, and program need not consider which data user changes on earth, anyway it is to replace every time It is possible that the data changed, but the realization method has the following disadvantages:Data volume is big, for example believes including figure, video Breath etc., this method just compare consumption memory, and when realizing unlimited pole revocation, recovery operation, storage information infinitely expands.
Invention content
Be directed to data volume present in the prior art it is big when consumption memory, it is complicated for operation the defects of, a kind of revocation, extensive is provided The abstract method operated again.
To achieve the above object, the technical solution adopted by the present invention is:A kind of revocation, the abstract method of recovery operation, tool Body step is as follows:
(1), abstract class definition is operated;
(2), class definition is realized in operation;
(3), operational administrative class defines.
Preferably, in the step (1), the abstract class of editing machine operation is defined, and defines execution, revocation, recovery Three methods;
Preferably, in the step (2), declaration definition specifically operates class, including adding, deleting, moving, editing These operations, the operation abstract class defined in concrete operations Similar integral step (1), and realize the execution of its declaration definition, revocation, Restore three methods.
Preferably, the step (3) is responsible for the initialization of active stack, the stacking of concrete operations, the pipe of Pop operations Reason.
The present invention has the following advantages compared with prior art:
The innovative point of the application is, is abstracted an operating method class, and there are three main methods, respectively performs, cancels And restore, the function that revocation and recovery operation are carried out in system goes to realize this operation class, and then this is grasped every time Make object storage to be used for carrying out performing revocation and recovery to storehouse;
Using method of the present invention, management can be facilitated per single stepping by command mode, the letter of program record Breath tails off, and only needs to record the action type of user and relevant operation data, other data unrelated with operation every time It does not need to then record, reduces the degree of coupling between program, add new operational order and be easy to, easily realize revocation and restore work( Energy.
Description of the drawings
Fig. 1 be it is of the present invention revocation, recovery operation abstract method operation class illustraton of model;
Fig. 2 be it is of the present invention revocation, recovery operation abstract method in moving operation realization flow chart;
Fig. 3 be it is of the present invention revocation, recovery operation abstract method revocation function realization flow chart;
Fig. 4 be it is of the present invention revocation, recovery operation abstract method restore function realization flow chart.
Specific embodiment
The effect of to make to structure feature of the invention and being reached, has a better understanding and awareness, to preferable Embodiment and attached drawing cooperation detailed description, are described as follows:
Embodiment 1
As shown in Figure 1, a kind of revocation, the abstract method of recovery operation, operate class Definition Model figure.
As shown in Fig. 2, when the moving operation for performing graphic editor, moving operation class is first got according to parameter information Then object calls its execution method to carry out moving operation, then stored moving operation object to behaviour by operational administrative class Make in stack.
As shown in figure 3, when performing destruction operation, the specific behaviour that operational administrative class takes out record from active stack is first passed through Make object (mobile, editor, deletion etc.), call its cancelling method, complete the revocation function of editing machine, last operation enters again Stack.
As shown in figure 4, it is similar with destruction operation, when performing recovery operation, operational administrative class is first passed through from active stack The concrete operations object (mobile, editor, deletion etc.) of record is taken out, its restoration methods is called, completes the recovery function of editing machine, Last operation stacking again.
Basic principle, main feature and the advantages of the present invention of the present invention has been shown and described above.The technology of the industry Personnel are it should be appreciated that the present invention is not limited to the above embodiments, and what is described in the above embodiment and the description is only the present invention Principle, various changes and improvements may be made to the invention without departing from the spirit and scope of the present invention, these variation and Improvement is both fallen in the range of claimed invention.The present invention claims protection domain by appended claims and its Equivalent defines.

Claims (4)

1. a kind of revocation, the abstract method of recovery operation, are as follows:
(1), abstract class definition is operated;
(2), class definition is realized in operation;
(3), operational administrative class defines.
2. a kind of revocation according to claim 1, the abstract method of recovery operation, it is characterised in that:The step (1) In, the abstract class of editing machine operation is defined, and define execution, revocation, restore three methods.
3. a kind of revocation according to claim 1, the abstract method of recovery operation, it is characterised in that:The step (2) In, declaration definition specifically operates class, including adding, deleting, moving, editing these operations, concrete operations Similar integral step (1) Defined in operation abstract class, and realize the execution of its declaration definition, revocation, restore three methods.
4. a kind of revocation according to claim 1, the abstract method of recovery operation, it is characterised in that:The step (3) It is responsible for the initialization of active stack, the stacking of concrete operations, the management of Pop operations.
CN201711478957.7A 2017-12-29 2017-12-29 A kind of revocation, the abstract method of recovery operation Pending CN108228168A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711478957.7A CN108228168A (en) 2017-12-29 2017-12-29 A kind of revocation, the abstract method of recovery operation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711478957.7A CN108228168A (en) 2017-12-29 2017-12-29 A kind of revocation, the abstract method of recovery operation

Publications (1)

Publication Number Publication Date
CN108228168A true CN108228168A (en) 2018-06-29

Family

ID=62646061

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711478957.7A Pending CN108228168A (en) 2017-12-29 2017-12-29 A kind of revocation, the abstract method of recovery operation

Country Status (1)

Country Link
CN (1) CN108228168A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110231909A (en) * 2019-05-15 2019-09-13 广州视源电子科技股份有限公司 Write the treating method and apparatus of operation
CN111338920A (en) * 2020-02-18 2020-06-26 成都品果科技有限公司 Method for recording user operation steps based on stack during photo editing
CN112000321A (en) * 2020-09-01 2020-11-27 杭州宏深科技有限公司 Method and device for realizing undo and/or redo of three-dimensional detection software
CN114489453A (en) * 2022-01-26 2022-05-13 深圳市前海手绘科技文化有限公司 Visual generation method and system for revocation and recovery of presentation drafts

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090217022A1 (en) * 2008-02-27 2009-08-27 Chang Yan Chi Method and apparatus for loading classes and re-organizing class archives
CN104572034A (en) * 2013-10-11 2015-04-29 北京西门子西伯乐斯电子有限公司 Method and device for implementing undo and/or redo
CN107145354A (en) * 2017-05-04 2017-09-08 武汉斗鱼网络科技有限公司 Software frame and its construction method, electric terminal and readable storage medium storing program for executing
CN107463380A (en) * 2017-08-01 2017-12-12 武汉斗鱼网络科技有限公司 Message treatment method, device and electronic equipment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090217022A1 (en) * 2008-02-27 2009-08-27 Chang Yan Chi Method and apparatus for loading classes and re-organizing class archives
CN104572034A (en) * 2013-10-11 2015-04-29 北京西门子西伯乐斯电子有限公司 Method and device for implementing undo and/or redo
CN107145354A (en) * 2017-05-04 2017-09-08 武汉斗鱼网络科技有限公司 Software frame and its construction method, electric terminal and readable storage medium storing program for executing
CN107463380A (en) * 2017-08-01 2017-12-12 武汉斗鱼网络科技有限公司 Message treatment method, device and electronic equipment

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110231909A (en) * 2019-05-15 2019-09-13 广州视源电子科技股份有限公司 Write the treating method and apparatus of operation
CN110231909B (en) * 2019-05-15 2021-03-05 广州视源电子科技股份有限公司 Writing operation processing method and device
CN111338920A (en) * 2020-02-18 2020-06-26 成都品果科技有限公司 Method for recording user operation steps based on stack during photo editing
CN111338920B (en) * 2020-02-18 2023-04-07 成都品果科技有限公司 Method for recording user operation steps based on stack during photo editing
CN112000321A (en) * 2020-09-01 2020-11-27 杭州宏深科技有限公司 Method and device for realizing undo and/or redo of three-dimensional detection software
CN114489453A (en) * 2022-01-26 2022-05-13 深圳市前海手绘科技文化有限公司 Visual generation method and system for revocation and recovery of presentation drafts

Similar Documents

Publication Publication Date Title
CN108228168A (en) A kind of revocation, the abstract method of recovery operation
CN105144063B (en) Software application automatically saves mode and manual preservation mode
KR101087364B1 (en) Undo infrastructure
JP5491388B2 (en) How to selectively enable multiple input controls
CN103577329B (en) Snapshot management method and device
CN103246638A (en) Information pasting method and device
CN102821193A (en) Method for rapidly operating file of intelligent cell phone and intelligent cell phone
CN102999366B (en) Activate based on the expansion of inferring
CN102223363A (en) System and method for generating persistent sessions in a graphical interface for managing communication sessions
CN112965660B (en) Method, system, equipment and medium for double storage pool information feedback
CN107665187A (en) A kind of method and apparatus for judging mobile device application interface and whether changing
CN104216646A (en) Method and device for creating application program based on gesture
WO2017113317A1 (en) File editing method and file editor
CN105988863A (en) Event processing method and device
CN102736910A (en) Plugin-based general command interface definition method
CN102567081B (en) Based on overall method to set up and the system of multi-process
CN105528334A (en) Method for processing document operation and terminal
CN110968404A (en) Equipment data processing method and device
CN102520947A (en) Method and device for automatically removing codes
CN105975265B (en) A kind of device based on modified MVP mode
CN103210389B (en) A kind for the treatment of method and apparatus of metadata
CN109086170A (en) A kind of data base backup recovery method and device
CN102446164A (en) Analytic method, device and operation system of report formula
JP4685898B2 (en) Disaster action support system and scenario creation program
CN107526675A (en) Record method, apparatus, storage medium and the electronic equipment of application message

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20180629

RJ01 Rejection of invention patent application after publication