WO2019184683A1 - Method and apparatus for preventing loss of application data, storage medium, and electronic device - Google Patents

Method and apparatus for preventing loss of application data, storage medium, and electronic device Download PDF

Info

Publication number
WO2019184683A1
WO2019184683A1 PCT/CN2019/077508 CN2019077508W WO2019184683A1 WO 2019184683 A1 WO2019184683 A1 WO 2019184683A1 CN 2019077508 W CN2019077508 W CN 2019077508W WO 2019184683 A1 WO2019184683 A1 WO 2019184683A1
Authority
WO
WIPO (PCT)
Prior art keywords
application
data
main
main application
disabled
Prior art date
Application number
PCT/CN2019/077508
Other languages
French (fr)
Chinese (zh)
Inventor
张伟杰
张俊
谭春宏
Original Assignee
Oppo广东移动通信有限公司
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 Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2019184683A1 publication Critical patent/WO2019184683A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/544Buffers; Shared memory; Pipes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/545Interprogram communication where tasks reside in different layers, e.g. user- and kernel-space
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/52Program synchronisation; Mutual exclusion, e.g. by means of semaphores

Definitions

  • the present application relates to the field of computer technology, and in particular, to an application data anti-lost method and device, a storage medium, and an electronic device.
  • the embodiment of the present application provides an application data anti-lost method and device, a storage medium, and an electronic device.
  • An application data anti-lost method includes:
  • the data after sharing is obtained for storage to prevent data loss.
  • a multi-space application data anti-lost method comprising:
  • An application obtaining module is configured to obtain a set of specified applications running in an electronic device supporting multiple spaces, where the set of specified applications includes a main application and a corresponding avatar application, where the main application and the avatar application are respectively operated An application of the same name in different spaces of an electronic device;
  • a data sharing module configured to share data of the main application and the corresponding avatar application when detecting that a running state of any one of the main application and the corresponding avatar application changes;
  • a data storage module for acquiring data after sharing for storage to prevent data loss.
  • a computer readable storage medium having stored thereon a computer program that, when executed by a processor, implements the operation of the application data anti-lost method as described above.
  • An electronic device comprising a memory, a processor, and a computer program stored on the memory and operable on the processor, the processor executing the operation of the application data anti-lost method as described above when executing the computer program.
  • the application data anti-lost method and device, the storage medium, and the electronic device acquire a set of specified applications running in an electronic device supporting multiple spaces.
  • the specified set of applications includes a main application and a corresponding avatar application, and the main application and the avatar application are The application of the same name running in different spaces of the electronic device respectively; when detecting that the running state of any one of the main application and the corresponding avatar application changes, sharing the data of the main application and the corresponding avatar application; acquiring the sharing The subsequent data is stored to prevent data loss.
  • For applications of the same name running in different spaces including the main application and the corresponding avatar application), when the running status of one of the applications is detected to change, the data of the main application and the corresponding avatar application are shared, thereby avoiding the application. If the state of the application changes, the data of the application is deleted and cannot be recovered. And only when the running state of the application changes, data sharing is performed, and data sharing is not performed in real time, so that resources are not taken too much.
  • 1 is a diagram showing the internal structure of an electronic device in an embodiment.
  • FIG. 2 is a flow chart of an application data anti-lost method in an embodiment.
  • FIG. 3 is a flow chart of the data sharing method of FIG. 2.
  • FIG. 4 is a flow chart of another data sharing method in FIG. 2.
  • FIG. 5 is a flow chart of the method for obtaining a specified application in FIG. 2.
  • FIG. 6 is a schematic structural diagram of an application data anti-lost device in an embodiment.
  • FIG. 7 is a schematic structural diagram of the data sharing module of FIG. 6.
  • FIG. 8 is a schematic structural diagram of another data sharing module in FIG. 6.
  • FIG. 9 is a block diagram showing a portion of a structure of an electronic device related to an electronic device provided in an embodiment.
  • FIG. 1 is a schematic diagram showing the internal structure of an electronic device in an embodiment.
  • the electronic device includes a processor, a memory, and a network interface connected by a system bus.
  • the processor is used to provide computing and control capabilities to support the operation of the entire electronic device.
  • the memory is used to store data, programs, etc., and the memory stores at least one computer program, which can be executed by the processor to implement the application data anti-lost method for the electronic device provided in the embodiment of the present application.
  • the memory may include a non-volatile storage medium such as a magnetic disk, an optical disk, a read-only memory (ROM), or a random storage memory (Random-Access-Memory, RAM).
  • the memory includes a non-volatile storage medium and an internal memory.
  • the non-volatile storage medium stores an operating system and a computer program.
  • the computer program can be executed by a processor for implementing an application data anti-lost method provided by the following various embodiments.
  • the internal memory provides a cached operating environment for operating system computer programs in a non-volatile storage medium.
  • the network interface can be an Ethernet card or a wireless network card, etc., for communicating with external electronic devices.
  • the electronic device can be a cell phone, a tablet or a personal digital assistant or a wearable device.
  • an application data anti-lost method is provided.
  • the method is applied to the electronic device in FIG. 1 as an example, and includes:
  • Operation 220 Obtain a set of specified applications running in an electronic device supporting multiple spaces.
  • the set of specified applications includes a main application and a corresponding avatar application, and the main application and the avatar application are respectively the same-named applications running in different spaces of the electronic device. .
  • An electronic device supporting multiple spaces means that an electronic device can support multiple spaces to run simultaneously, for example, a standard space and a privacy space run simultaneously.
  • the standard space refers to a space that is visible to any user in the electronic device
  • the privacy space is a space that can be accessed only after the user needs to be authenticated. This privacy space can be seen in some applications and information hidden by the user.
  • standard and privacy spaces operate independently.
  • Applying dual-opening means running at least two identical applications on the same electronic device at the same time. With the application double-opening technology, the same application can simultaneously open at least two processes, and all the processes that are opened simultaneously run, so that the application can be satisfied. The same user or different users can initiate the needs of multiple identical applications through multiple accounts, which facilitates the use of the user.
  • the specified application in the embodiment of the present application refers to an application of the same name that is double-opened and runs in different spaces respectively.
  • a set of designated applications includes a main application and a corresponding avatar application, which are applications of the same name running in different spaces of the electronic device, respectively.
  • the main application is generally an application running in a standard space
  • the avatar application is an application running in a non-standard space with the same name as the main application.
  • the main application is generally one, and the number of avatar applications can be one, or of course multiple. For example, running multiple avatar applications in a non-standard space, or running multiple avatar applications in multiple non-quasi-spaces, is a one-to-one relationship.
  • Operation 240 when it is detected that the running state of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared.
  • Operation 260 obtaining data after sharing for storage to prevent data loss.
  • Sharing the data of the main application and the corresponding avatar application generally means that the data of the application whose operating status has changed is shared with the application of the same name in other space for temporary storage, thereby preventing data loss.
  • a set of specified applications running in an electronic device supporting multiple spaces is acquired.
  • the set of specified applications includes a main application and a corresponding avatar application, and the main application and the avatar application respectively run in different spaces of the electronic device.
  • the application of the same name when detecting the change of the running state of any one of the main application and the corresponding avatar application, sharing the data of the main application and the corresponding avatar application; acquiring the data after sharing for storage to prevent data loss .
  • applications of the same name running in different spaces including the main application and the corresponding avatar application
  • the running status of one of the applications is detected to change, the data of the main application and the corresponding avatar application are shared, thereby avoiding the application. If the state of the application changes, the data of the application is deleted and cannot be recovered. And only when the running state of the application changes, data sharing is performed, and data sharing is not performed in real time, so that resources are not taken too much.
  • operation 240 when detecting that the running state of any one of the main application and the corresponding avatar application changes, sharing the data of the main application and the corresponding avatar application, include:
  • Operation 242 when it is detected that any one of the main application and the corresponding avatar application is disabled, the data corresponding to the disabled application is acquired, and the data is the first data.
  • each set of specified applications including the running status of the main application and the avatar application, is detected in real time.
  • the data of the main application and the corresponding avatar application are shared.
  • Disabling refers to the state in which the application changes from a normal use state to a prohibited use state. The application's data is deleted and disabled in the disabled state. After the application in a certain space is disabled, the data corresponding to the disabled application is obtained, and the data is named as the first data.
  • Operation 244 the first data is transferred to an application with the same name as the disabled application for temporary storage.
  • an application in a space When an application in a space is disabled, it looks for an application of the same name that corresponds to the disabled application in other spaces. After obtaining the application with the same name corresponding to the disabled application, the first data is immediately transferred to the application with the same name for temporary storage.
  • operation 244 after temporarily transferring the first data to an application having the same name as the disabled application, includes:
  • the application's data is deleted in the disabled state and cannot be recovered. Therefore, when the application is disabled, the first data that is disabled is immediately transferred to the application of the same name for temporary storage after acquiring the application with the same name corresponding to the disabled application, thereby preventing complete loss of data.
  • the disabled application is deactivated, the un-disabled application can obtain its own first data from the same-named application running in another space, that is, the same-named application can transmit the first data back to The application after the deactivation is disabled, the application is directly restored to normal use.
  • the first data in the application with the same name as the disabled application is backhauled to the disabled application. Because before detecting that an application in a certain space is disabled, it searches for other applications of the same name corresponding to the disabled application in other spaces. After obtaining the application with the same name corresponding to the disabled application, the first data is immediately transferred to the application with the same name for temporary storage. Therefore, it is guaranteed that the data of the application after the release is disabled is not lost, so that the user can directly start normal use.
  • operation 220 is performed to obtain a set of specified applications running in an electronic device supporting multiple spaces, including:
  • Operation 222 obtaining a main application in the standard space.
  • Operation 224 determining whether there is an application with the same name as the main application in another space opposite to the standard space.
  • an application is randomly obtained from the standard space, and the application running in the standard space is generally referred to as the main application. Then it is judged whether there is an application (ie, a avatar application) having the same name as the main application in another space opposite to the standard space. For example, an application QQ is randomly acquired in the standard space, and then it is judged whether there is an application QQ having the same name as the main application in another space opposite to the standard space. In general, data between different applications of the same name cannot be shared.
  • the main application and the avatar application corresponding to the main application constitute a set of designated applications.
  • Designated application refers to the same application that is dual-open and runs in different spaces.
  • an application of the same name running in different spaces is acquired, so that when the running state of an application changes, if the application has the same name application in another space, Moreover, data sharing between the applications of the same name can be performed, and the data of the application whose operating state is changed can be temporarily transferred to other applications of the same name for temporary storage, thereby avoiding the problem of data loss of the application whose operating state changes.
  • another space opposite the standard space is a privacy space.
  • a standard space is generally run, and of course, a privacy space may be run, and the privacy space may be used by the user to use some users for privacy settings.
  • the method further includes pre-opening data sharing between a set of designated applications.
  • the data of the main application and the corresponding avatar application are shared.
  • Data sharing between all applications of the same name can be started in advance, so that when it is detected that the running state of any one of the main application and the corresponding avatar application changes, and data sharing is required, data sharing can be performed in time. Avoid data loss caused by turning on data sharing at this time.
  • the data of the main application and the corresponding avatar application are shared, including:
  • the first data corresponding to the disabled application is acquired. Then, in the other space, the application with the same name corresponding to the application whose running state changes is obtained. After obtaining the application with the same name, it is also necessary to determine whether the data sharing is enabled between the application of the same name and the corresponding avatar application. If data sharing is enabled, the first data can be directly shared between applications of the same name at this time, thereby avoiding data loss.
  • the data sharing is further determined between the applications with the same name. If data sharing is enabled, the first data can be directly shared between applications of the same name at this time, thereby avoiding data loss. If data sharing is not enabled, data sharing cannot be performed. In this case, other methods are needed to enable data sharing in time to minimize data loss.
  • an application data anti-lost device 600 includes: a specified application obtaining module 620, a data sharing module 640, and a data storage module 660. among them,
  • the specified application obtaining module 620 is configured to obtain a set of specified applications running in an electronic device supporting multiple spaces, where the specified set of applications includes a main application and a corresponding avatar application, and the main application and the avatar application are respectively operated on the electronic device.
  • the data sharing module 640 is configured to share the data of the main application and the corresponding avatar application when detecting that the running state of any one of the main application and the corresponding avatar application changes;
  • the data storage module 660 is configured to acquire data after sharing for storage to prevent data loss.
  • the data sharing module 640 includes:
  • the first data obtaining module 642 is configured to: when it is detected that any one of the main application and the corresponding avatar application is disabled, acquire data corresponding to the disabled application, where the data is the first data;
  • the first data temporary storage module 644 is configured to temporarily transfer the first data to an application having the same name as the disabled application.
  • the data sharing module 640 further includes: a first data backhaul module 646, configured to temporarily and temporarily disable the disabled application when it is detected that the disabled application is disabled. The first data in the application with the same name is passed back to the disabled application.
  • the application obtaining module 620 is further configured to acquire a main application in the standard space; determine whether an application having the same name as the main application exists in another space opposite to the standard space; if yes, obtain and The application with the same name as the main application is the avatar application corresponding to the main application; the main application and the avatar application corresponding to the main application constitute a set of specified applications.
  • an application data anti-lost device 600 is provided, further comprising a data sharing on unit for pre-opening data sharing between a group of designated applications.
  • the data sharing module 640 is further configured to: when it is detected that the running state of any one of the main application and the corresponding avatar application changes, determine whether data sharing is enabled between the application and the corresponding avatar application. ;
  • each module in the application data anti-lost device is used for illustration only. In other embodiments, the application data anti-lost device may be divided into different modules as needed to complete all or part of the application data anti-lost device.
  • a computer readable storage medium having stored thereon a computer program that, when executed by a processor, implements the operations of the application data anti-lost method provided by the various embodiments described above.
  • an electronic device including a memory, a processor, and a computer program stored on the memory and executable on the processor, and the application data provided by the foregoing embodiments is implemented when the processor executes the computer program The operation of the anti-lost method.
  • the embodiment of the present application further provides a computer program product, when it is run on a computer, causing the computer to perform the operation of the application data anti-lost method provided by the foregoing embodiments.
  • An embodiment of the present application also provides an electronic device. As shown in FIG. 9 , for the convenience of description, only the parts related to the embodiments of the present application are shown. If the specific technical details are not disclosed, please refer to the method part of the embodiment of the present application.
  • the electronic device can be any terminal device including a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales), an on-board computer, a wearable device, and the like, and the electronic device is used as a mobile phone. :
  • FIG. 9 is a block diagram showing a partial structure of a mobile phone related to an electronic device according to an embodiment of the present application.
  • the mobile phone includes: a radio frequency (RF) circuit 910, a memory 920, an input unit 930, a display unit 940, a sensor 950, an audio circuit 990, a wireless fidelity (WiFi) module 970, and a processor 980. And power supply 990 and other components.
  • RF radio frequency
  • the RF circuit 910 can be used for receiving and transmitting signals during the transmission and reception of information or during a call.
  • the downlink information of the base station can be received and processed by the processor 980.
  • the uplink data can also be sent to the base station.
  • RF circuits include, but are not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like.
  • LNA Low Noise Amplifier
  • RF circuitry 910 can also communicate with the network and other devices via wireless communication.
  • the above wireless communication may use any communication standard or protocol, including but not limited to Global System of Mobile communication (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (Code Division). Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (LTE), e-mail, Short Messaging Service (SMS), and the like.
  • GSM Global System of Mobile communication
  • GPRS General
  • the memory 920 can be used to store software programs and modules, and the processor 980 executes various functional applications and data processing of the mobile phone by running software programs and modules stored in the memory 920.
  • the memory 920 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as an application of a sound playing function, an application of an image playing function, etc.);
  • the data storage area can store data (such as audio data, address book, etc.) created according to the use of the mobile phone.
  • memory 920 can include high speed random access memory, and can also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
  • the input unit 930 can be configured to receive input numeric or character information and to generate key signal inputs related to user settings and function control of the handset 900.
  • the input unit 930 may include a touch panel 931 and other input devices 932.
  • the touch panel 931 also referred to as a touch screen, can collect touch operations on or near the user (such as the user using a finger, a stylus, or the like on the touch panel 931 or near the touch panel 931. Operation) and drive the corresponding connection device according to a preset program.
  • the touch panel 931 can include two portions of a touch detection device and a touch controller.
  • the touch detection device detects the touch orientation of the user, and detects a signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts the touch information into contact coordinates, and sends the touch information.
  • the processor 980 is provided and can receive commands from the processor 980 and execute them.
  • the touch panel 931 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves.
  • the input unit 930 may also include other input devices 932.
  • other input devices 932 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control buttons, switch buttons, etc.).
  • the display unit 940 can be used to display information input by the user or information provided to the user as well as various menus of the mobile phone.
  • the display unit 940 can include a display panel 941.
  • the display panel 941 may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like.
  • the touch panel 931 can cover the display panel 941. When the touch panel 931 detects a touch operation on or near it, the touch panel 931 transmits to the processor 980 to determine the type of the touch event, and then the processor 980 is The type of touch event provides a corresponding visual output on display panel 941.
  • touch panel 931 and the display panel 941 are used as two independent components to implement the input and input functions of the mobile phone in FIG. 9, in some embodiments, the touch panel 931 and the display panel 941 may be integrated. Realize the input and output functions of the phone.
  • the handset 900 can also include at least one type of sensor 950, such as a light sensor, motion sensor, and other sensors.
  • the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 941 according to the brightness of the ambient light, and the proximity sensor may close the display panel 941 and/or when the mobile phone moves to the ear. Or backlight.
  • the motion sensor may include an acceleration sensor, and the acceleration sensor can detect the magnitude of the acceleration in each direction, and the magnitude and direction of the gravity can be detected at rest, and can be used to identify the gesture of the mobile phone (such as horizontal and vertical screen switching), and vibration recognition related functions (such as Pedometer, tapping, etc.; in addition, the phone can also be equipped with gyroscopes, barometers, hygrometers, thermometers, infrared sensors and other sensors.
  • the acceleration sensor can detect the magnitude of the acceleration in each direction, and the magnitude and direction of the gravity can be detected at rest, and can be used to identify the gesture of the mobile phone (such as horizontal and vertical screen switching), and vibration recognition related functions (such as Pedometer, tapping, etc.; in addition, the phone can also be equipped with gyroscopes, barometers, hygrometers, thermometers, infrared sensors and other sensors.
  • Audio circuitry 990, speaker 991, and microphone 992 can provide an audio interface between the user and the handset.
  • the audio circuit 990 can transmit the converted electrical data of the received audio data to the speaker 991 for conversion to the sound signal output by the speaker 991; on the other hand, the microphone 992 converts the collected sound signal into an electrical signal, by the audio circuit 990.
  • WiFi is a short-range wireless transmission technology
  • the mobile phone can help users to send and receive emails, browse web pages, and access streaming media through the WiFi module 970, which provides users with wireless broadband Internet access.
  • FIG. 9 shows the WiFi module 970, it can be understood that it does not belong to the essential configuration of the mobile phone 900 and can be omitted as needed.
  • the processor 980 is the control center of the handset, which connects various portions of the entire handset using various interfaces and lines, by executing or executing software programs and/or modules stored in the memory 920, and invoking data stored in the memory 920, executing The phone's various functions and processing data, so that the overall monitoring of the phone.
  • processor 980 can include one or more processing units.
  • the processor 980 can integrate an application processor and a modem processor, wherein the application processor primarily processes an operating system, a user interface, an application, and the like; the modem processor primarily processes wireless communications. It will be appreciated that the above described modem processor may also not be integrated into the processor 980.
  • the mobile phone 900 also includes a power source 990 (such as a battery) that supplies power to various components.
  • a power source 990 such as a battery
  • the power source can be logically coupled to the processor 980 through a power management system to manage functions such as charging, discharging, and power management through the power management system.
  • the handset 900 can also include a camera, a Bluetooth module, and the like.
  • Non-volatile memory can include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory.
  • Volatile memory can include random access memory (RAM), which acts as an external cache.
  • RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronization.
  • SRAM static RAM
  • DRAM dynamic RAM
  • SDRAM synchronous DRAM
  • DDR SDRAM dual data rate SDRAM
  • ESDRAM enhanced SDRAM
  • SLDRAM Link (Synchlink) DRAM
  • SLDRAM Memory Bus
  • Rambus Direct RAM
  • RDRAM Direct Memory Bus Dynamic RAM
  • RDRAM Memory Bus Dynamic RAM

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

A method for preventing loss of application data, comprising: obtaining a set of specified applications running in an electronic device supporting multiple spaces, the set of specified applications comprising a main application and a corresponding twin application, and the main application and the twin application being applications which have the same name and respectively run in different spaces of the electronic device; sharing data of the main application and the corresponding twin application when it is detected that the running state of any of the main application and the corresponding twin application changes; and obtaining the shared data for storing to prevent data loss.

Description

应用数据防丢方法和装置、存储介质、电子设备Application data anti-lost method and device, storage medium, electronic device
本申请要求于2018年03月29日提交中国专利局、申请号为201810274180.0、发明名称为“应用数据防丢方法和装置、存储介质、电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application filed on March 29, 2018, the Chinese Patent Office, application number 201810274180.0, the invention titled "application data anti-lost method and device, storage medium, electronic device", the entire content of which is The citations are incorporated herein by reference.
技术领域Technical field
本申请涉及计算机技术领域,特别是涉及一种应用数据防丢方法和装置、存储介质、电子设备。The present application relates to the field of computer technology, and in particular, to an application data anti-lost method and device, a storage medium, and an electronic device.
背景技术Background technique
随着移动终端的普及和移动互联网的迅速发展,移动终端的用户使用量越来越大。在支持多空间的设备中,运行在不同空间中的同名应用之间可以进行数据共享。但当在其中一个空间中禁用了某应用之后,该应用在该空间的数据就会被删除,且无法恢复。With the popularity of mobile terminals and the rapid development of mobile Internet, the usage of mobile terminals is increasing. In devices that support multiple spaces, data sharing can occur between applications of the same name running in different spaces. However, when an app is disabled in one of the spaces, the app's data in that space is deleted and cannot be recovered.
发明内容Summary of the invention
本申请实施例提供一种应用数据防丢方法和装置、存储介质、电子设备。The embodiment of the present application provides an application data anti-lost method and device, a storage medium, and an electronic device.
一种应用数据防丢方法,包括:An application data anti-lost method includes:
获取运行于支持多空间的电子设备中的一组指定应用,所述一组指定应用包括主应用和对应的分身应用,所述主应用和分身应用为分别运行于所述电子设备的不同空间中的同名应用;Obtaining a set of specified applications running in an electronic device supporting multiple spaces, the set of specified applications including a main application and a corresponding avatar application, the main application and the avatar application respectively running in different spaces of the electronic device Application of the same name;
当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared;
获取共享之后的数据进行存储以防止数据丢失。The data after sharing is obtained for storage to prevent data loss.
一种多空间应用数据防丢方法,所述装置包括:A multi-space application data anti-lost method, the device comprising:
指定应用获取模块,用于获取运行于支持多空间的电子设备中的一组指定应用,所述一组指定应用包括主应用和对应的分身应用,所述主应用和分身应用为分别运行于所述电 子设备的不同空间中的同名应用;An application obtaining module is configured to obtain a set of specified applications running in an electronic device supporting multiple spaces, where the set of specified applications includes a main application and a corresponding avatar application, where the main application and the avatar application are respectively operated An application of the same name in different spaces of an electronic device;
数据共享模块,用于当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享;a data sharing module, configured to share data of the main application and the corresponding avatar application when detecting that a running state of any one of the main application and the corresponding avatar application changes;
数据存储模块,用于获取共享之后的数据进行存储以防止数据丢失。A data storage module for acquiring data after sharing for storage to prevent data loss.
一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如上所述的应用数据防丢方法的操作。A computer readable storage medium having stored thereon a computer program that, when executed by a processor, implements the operation of the application data anti-lost method as described above.
一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,处理器执行计算机程序时执行如上所述的应用数据防丢方法的操作。An electronic device comprising a memory, a processor, and a computer program stored on the memory and operable on the processor, the processor executing the operation of the application data anti-lost method as described above when executing the computer program.
上述应用数据防丢方法和装置、存储介质、电子设备,获取运行于支持多空间的电子设备中的一组指定应用,一组指定应用包括主应用和对应的分身应用,主应用和分身应用为分别运行于电子设备的不同空间中的同名应用;当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享;获取共享之后的数据进行存储以防止数据丢失。对于运行于不同空间的同名应用(包括主应用和对应的分身应用),当检测到其中一个应用的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享,从而避免了应用的状态发生变化时删除了该应用的数据导致无法恢复。且只是在应用的运行状态发生变化时才进行数据共享,不用实时进行数据共享,如此便不会过多占用资源。The application data anti-lost method and device, the storage medium, and the electronic device acquire a set of specified applications running in an electronic device supporting multiple spaces. The specified set of applications includes a main application and a corresponding avatar application, and the main application and the avatar application are The application of the same name running in different spaces of the electronic device respectively; when detecting that the running state of any one of the main application and the corresponding avatar application changes, sharing the data of the main application and the corresponding avatar application; acquiring the sharing The subsequent data is stored to prevent data loss. For applications of the same name running in different spaces (including the main application and the corresponding avatar application), when the running status of one of the applications is detected to change, the data of the main application and the corresponding avatar application are shared, thereby avoiding the application. If the state of the application changes, the data of the application is deleted and cannot be recovered. And only when the running state of the application changes, data sharing is performed, and data sharing is not performed in real time, so that resources are not taken too much.
附图说明DRAWINGS
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings to be used in the embodiments or the prior art description will be briefly described below. Obviously, the drawings in the following description are only It is a certain embodiment of the present application, and other drawings can be obtained according to the drawings without any creative work for those skilled in the art.
图1为一个实施例中电子设备的内部结构图。1 is a diagram showing the internal structure of an electronic device in an embodiment.
图2为一个实施例中应用数据防丢方法的流程图。2 is a flow chart of an application data anti-lost method in an embodiment.
图3为图2中数据共享方法的流程图。3 is a flow chart of the data sharing method of FIG. 2.
图4为图2中另一数据共享方法的流程图。4 is a flow chart of another data sharing method in FIG. 2.
图5为图2中获取指定应用方法的流程图。FIG. 5 is a flow chart of the method for obtaining a specified application in FIG. 2.
图6为一个实施例中应用数据防丢装置的结构示意图。FIG. 6 is a schematic structural diagram of an application data anti-lost device in an embodiment.
图7为图6中数据共享模块的结构示意图。FIG. 7 is a schematic structural diagram of the data sharing module of FIG. 6.
图8为图6中另一种数据共享模块的结构示意图。FIG. 8 is a schematic structural diagram of another data sharing module in FIG. 6.
图9为一个实施例中提供的电子设备相关的手机的部分结构的框图。9 is a block diagram showing a portion of a structure of an electronic device related to an electronic device provided in an embodiment.
具体实施方式detailed description
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the objects, technical solutions, and advantages of the present application more comprehensible, the present application will be further described in detail below with reference to the accompanying drawings and embodiments. It is understood that the specific embodiments described herein are merely illustrative of the application and are not intended to be limiting.
图1为一个实施例中电子设备的内部结构示意图。如图1所示,该电子设备包括通过***总线连接的处理器、存储器和网络接口。其中,该处理器用于提供计算和控制能力,支撑整个电子设备的运行。存储器用于存储数据、程序等,存储器上存储至少一个计算机程序,该计算机程序可被处理器执行,以实现本申请实施例中提供的适用于电子设备的应用数据防丢方法。存储器可包括磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等非易失性存储介质,或随机存储记忆体(Random-Access-Memory,RAM)等。例如,在一个实施例中,存储器包括非易失性存储介质及内存储器。非易失性存储介质存储有操作***和计算机程序。该计算机程序可被处理器所执行,以用于实现以下各个实施例所提供的一种应用数据防丢方法。内存储器为非易失性存储介质中的操作***计算机程序提供高速缓存的运行环境。网络接口可以是以太网卡或无线网卡等,用于与外部的电子设备进行通信。该电子设备可以是手机、平板电脑或者个人数字助理或穿戴式设备等。FIG. 1 is a schematic diagram showing the internal structure of an electronic device in an embodiment. As shown in FIG. 1, the electronic device includes a processor, a memory, and a network interface connected by a system bus. The processor is used to provide computing and control capabilities to support the operation of the entire electronic device. The memory is used to store data, programs, etc., and the memory stores at least one computer program, which can be executed by the processor to implement the application data anti-lost method for the electronic device provided in the embodiment of the present application. The memory may include a non-volatile storage medium such as a magnetic disk, an optical disk, a read-only memory (ROM), or a random storage memory (Random-Access-Memory, RAM). For example, in one embodiment, the memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The computer program can be executed by a processor for implementing an application data anti-lost method provided by the following various embodiments. The internal memory provides a cached operating environment for operating system computer programs in a non-volatile storage medium. The network interface can be an Ethernet card or a wireless network card, etc., for communicating with external electronic devices. The electronic device can be a cell phone, a tablet or a personal digital assistant or a wearable device.
在一个实施例中,如图2所示,提供了一种应用数据防丢方法,以该方法应用于图1中的电子设备为例进行说明,包括:In an embodiment, as shown in FIG. 2, an application data anti-lost method is provided. The method is applied to the electronic device in FIG. 1 as an example, and includes:
操作220,获取运行于支持多空间的电子设备中的一组指定应用,一组指定应用包括主应用和对应的分身应用,主应用和分身应用为分别运行于电子设备的不同空间中的同名应用。Operation 220: Obtain a set of specified applications running in an electronic device supporting multiple spaces. The set of specified applications includes a main application and a corresponding avatar application, and the main application and the avatar application are respectively the same-named applications running in different spaces of the electronic device. .
支持多空间的电子设备指的是,电子设备上可以支持多个空间同时运行,例如,一个 标准空间和一个隐私空间同时运行。标准空间是指电子设备中对于任何用户都可见的一个空间,而隐私空间是需要用户进行身份验证之后才可以进入的一个空间,这个隐私空间中可见用户所隐藏的一些应用及信息等。一般情况下,标准空间和隐私空间是独立运行的。应用双开指的是在同一电子设备上同时运行至少两个相同的应用程序,采用应用双开技术可以实现同一应用程序能够同时打开至少两个进程,且被打开的所有进程同时运行,这样就可以满足同一用户或不同用户通过多个账号启动多个相同应用的需求,为用户的使用提供便利。本申请实施例中的指定应用,指的就是应用双开且分别运行在不同的空间内的同名应用。一组指定应用包括主应用和对应的分身应用,主应用和分身应用为分别运行于电子设备的不同空间中的同名应用。其中,主应用一般为运行于标准空间内的应用,而分身应用为运行于非标准空间的与主应用同名的应用。主应用一般为一个,而分身应用的数目可以是一个,当然也可以是多个。例如,在一个非标准空间中运行多个分身应用,也可以是在多个非准空间中运行多个分身应用,都是一对一的关系。An electronic device supporting multiple spaces means that an electronic device can support multiple spaces to run simultaneously, for example, a standard space and a privacy space run simultaneously. The standard space refers to a space that is visible to any user in the electronic device, and the privacy space is a space that can be accessed only after the user needs to be authenticated. This privacy space can be seen in some applications and information hidden by the user. In general, standard and privacy spaces operate independently. Applying dual-opening means running at least two identical applications on the same electronic device at the same time. With the application double-opening technology, the same application can simultaneously open at least two processes, and all the processes that are opened simultaneously run, so that the application can be satisfied. The same user or different users can initiate the needs of multiple identical applications through multiple accounts, which facilitates the use of the user. The specified application in the embodiment of the present application refers to an application of the same name that is double-opened and runs in different spaces respectively. A set of designated applications includes a main application and a corresponding avatar application, which are applications of the same name running in different spaces of the electronic device, respectively. The main application is generally an application running in a standard space, and the avatar application is an application running in a non-standard space with the same name as the main application. The main application is generally one, and the number of avatar applications can be one, or of course multiple. For example, running multiple avatar applications in a non-standard space, or running multiple avatar applications in multiple non-quasi-spaces, is a one-to-one relationship.
操作240,当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享。 Operation 240, when it is detected that the running state of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared.
本申请实施例中,因为不用实时将运行在不同空间内的同名应用程序进行数据共享,因此就需要实时检测每一组指定应用的运行状态,包括主应用和分身应用的运行状态。一般情况下不同的同名应用是独立运行的,所以不同的同名应用之间的数据也是不能够共享的。当某一组指定应用中的主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享。具体地,运行状态发生变化可以是应用被禁用、应用解除禁用、应用的软件崩溃、应用的软件强制暂停等突发情况。在发生上述运行状态发生变化时,一般应用的数据就会被删除或消失,因此,面对这些情况时,如何才能防止应用数据丢失。在此提出了在检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享。具体地,假如在某一个空间中运行的某一个分身应用的运行状态发生变化,则立即将该分身应用对应的数据传输至运行在另一个空间中的同名应用下进行暂存,从而避免了数据的彻底丢失。当该分身应用恢复正常使用时,则可以从该同名应用下获取到暂存的应用数据而直接进行使用,不会出现因为丢失数据而对用户的正常使用造成困扰。In the embodiment of the present application, since data sharing of the same-named application running in different spaces is not performed in real time, it is necessary to detect the running state of each group of specified applications in real time, including the running states of the main application and the avatar application. In general, different applications with the same name are run independently, so data between different applications with the same name cannot be shared. When the running status of any one of the main application and the corresponding avatar application in a certain group of applications changes, the data of the main application and the corresponding avatar application are shared. Specifically, the change in the operating state may be an unexpected situation in which the application is disabled, the application is deactivated, the application's software crashes, the application's software is forced to pause, and the like. When the above operating state changes, the general application data will be deleted or disappeared. Therefore, in the face of these situations, how to prevent application data loss. Here, it is proposed that when the running state of any one of the main application and the corresponding avatar application is changed, the data of the main application and the corresponding avatar application are shared. Specifically, if the running state of a certain avatar application running in a certain space changes, the data corresponding to the avatar application is immediately transferred to the application of the same name running in another space for temporary storage, thereby avoiding data. Completely lost. When the avatar application resumes normal use, the temporary application data can be obtained directly from the application of the same name and used directly, and the normal use of the user is not caused by the loss of data.
操作260,获取共享之后的数据进行存储以防止数据丢失。 Operation 260, obtaining data after sharing for storage to prevent data loss.
将主应用和对应的分身应用的数据进行共享,一般是将运行状态发生了变化的应用的数据共享至其他空间中正常运行的同名应用下进行暂存,从而就可以防止数据丢失。Sharing the data of the main application and the corresponding avatar application generally means that the data of the application whose operating status has changed is shared with the application of the same name in other space for temporary storage, thereby preventing data loss.
本申请实施例中,获取运行于支持多空间的电子设备中的一组指定应用,一组指定应用包括主应用和对应的分身应用,主应用和分身应用为分别运行于电子设备的不同空间中的同名应用;当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享;获取共享之后的数据进行存储以防止数据丢失。对于运行于不同空间的同名应用(包括主应用和对应的分身应用),当检测到其中一个应用的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享,从而避免了应用的状态发生变化时删除了该应用的数据导致无法恢复。且只是在应用的运行状态发生变化时才进行数据共享,不用实时进行数据共享,如此便不会过多占用资源。In the embodiment of the present application, a set of specified applications running in an electronic device supporting multiple spaces is acquired. The set of specified applications includes a main application and a corresponding avatar application, and the main application and the avatar application respectively run in different spaces of the electronic device. The application of the same name; when detecting the change of the running state of any one of the main application and the corresponding avatar application, sharing the data of the main application and the corresponding avatar application; acquiring the data after sharing for storage to prevent data loss . For applications of the same name running in different spaces (including the main application and the corresponding avatar application), when the running status of one of the applications is detected to change, the data of the main application and the corresponding avatar application are shared, thereby avoiding the application. If the state of the application changes, the data of the application is deleted and cannot be recovered. And only when the running state of the application changes, data sharing is performed, and data sharing is not performed in real time, so that resources are not taken too much.
在一个实施例中,如图3所示,操作240,当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享,包括:In an embodiment, as shown in FIG. 3, operation 240, when detecting that the running state of any one of the main application and the corresponding avatar application changes, sharing the data of the main application and the corresponding avatar application, include:
操作242,当检测到主应用和对应的分身应用中的任意一个被禁用时,则获取被禁用的应用对应的数据,数据为第一数据。 Operation 242, when it is detected that any one of the main application and the corresponding avatar application is disabled, the data corresponding to the disabled application is acquired, and the data is the first data.
具体地,实时检测每一组指定应用,包括主应用和分身应用的运行状态。当某一组指定应用中的主应用和对应的分身应用中的任意一个被禁用时,则将主应用和对应的分身应用的数据进行共享。禁用指的是该应用由正常使用的状态变化为被禁止使用的状态。且在禁用状态下会对应用程序的数据进行删除,且不可恢复。当某个空间中的应用被禁用之后,则获取被禁用的应用对应的数据,并将数据命名为第一数据。Specifically, each set of specified applications, including the running status of the main application and the avatar application, is detected in real time. When any one of the main application and the corresponding avatar application in a certain group of designated applications is disabled, the data of the main application and the corresponding avatar application are shared. Disabling refers to the state in which the application changes from a normal use state to a prohibited use state. The application's data is deleted and disabled in the disabled state. After the application in a certain space is disabled, the data corresponding to the disabled application is obtained, and the data is named as the first data.
操作244,将第一数据传输至与被禁用的应用同名的应用中进行暂存。 Operation 244, the first data is transferred to an application with the same name as the disabled application for temporary storage.
当某个空间中的应用被禁用之后,则在其他空间中寻找与被禁用的应用对应的同名应用。在获取了与被禁用的应用对应的同名应用之后,立即将第一数据传输至该同名应用下进行暂存。When an application in a space is disabled, it looks for an application of the same name that corresponds to the disabled application in other spaces. After obtaining the application with the same name corresponding to the disabled application, the first data is immediately transferred to the application with the same name for temporary storage.
本申请实施例中,当检测到某个空间中的应用被禁用之后,则在其他空间中寻找与被禁用的应用对应的同名应用。在获取了与被禁用的应用对应的同名应用之后,立即将第一数据传输至该同名应用下进行暂存。从而,不需要实时对运行在不同空间的同名应用的 数据之间进行数据共享,而只是在应用被禁用时才进行数据共享,如此便不会过多占用资源。In the embodiment of the present application, after detecting that the application in a certain space is disabled, searching for an application of the same name corresponding to the disabled application in other spaces. After obtaining the application with the same name corresponding to the disabled application, the first data is immediately transferred to the application with the same name for temporary storage. Therefore, data sharing between data of the same-named application running in different spaces is not required in real time, but data sharing is only performed when the application is disabled, so that resources are not excessively occupied.
在一个实施例中,如图4所示,操作244,在将第一数据传输至与被禁用的应用同名的应用中进行暂存之后,包括:In one embodiment, as shown in FIG. 4, operation 244, after temporarily transferring the first data to an application having the same name as the disabled application, includes:
操作246,当检测到被禁用的应用解除禁用时,则将暂存在与被禁用的应用同名的应用中的第一数据回传至被禁用的应用。 Operation 246, when it is detected that the disabled application is deactivated, then the first data in the application with the same name as the disabled application is backhauled to the disabled application.
因为在禁用状态下会对应用程序的数据进行删除,且不可恢复。所以当应用被禁用时,采用在获取了与被禁用的应用对应的同名应用之后,立即将被禁用的第一数据传输至该同名应用下进行暂存,从而防止了数据的彻底丢失。当该被禁用的应用解除禁用时,则该解除禁用之后的应用就可以从运行在另一个空间中的同名应用下获取到自身的第一数据,即该同名应用可以将第一数据回传至该解除禁用之后的应用,使得该应用直接恢复正常使用。Because the application's data is deleted in the disabled state and cannot be recovered. Therefore, when the application is disabled, the first data that is disabled is immediately transferred to the application of the same name for temporary storage after acquiring the application with the same name corresponding to the disabled application, thereby preventing complete loss of data. When the disabled application is deactivated, the un-disabled application can obtain its own first data from the same-named application running in another space, that is, the same-named application can transmit the first data back to The application after the deactivation is disabled, the application is directly restored to normal use.
本申请实施例中,当检测到被禁用的应用解除禁用时,则将暂存在与被禁用的应用同名的应用中的第一数据回传至被禁用的应用。因为之前当检测到某个空间中的应用被禁用之后,则在其他空间中寻找与被禁用的应用对应的同名应用。在获取了与被禁用的应用对应的同名应用之后,立即将第一数据传输至该同名应用下进行暂存。所以就保证了该解除禁用之后的应用程序的数据未丢失,便于用户直接开始正常使用。In the embodiment of the present application, when it is detected that the disabled application is deactivated, the first data in the application with the same name as the disabled application is backhauled to the disabled application. Because before detecting that an application in a certain space is disabled, it searches for other applications of the same name corresponding to the disabled application in other spaces. After obtaining the application with the same name corresponding to the disabled application, the first data is immediately transferred to the application with the same name for temporary storage. Therefore, it is guaranteed that the data of the application after the release is disabled is not lost, so that the user can directly start normal use.
在一个实施例中,如图5所示,操作220,获取运行于支持多空间的电子设备中的一组指定应用,包括:In one embodiment, as shown in FIG. 5, operation 220 is performed to obtain a set of specified applications running in an electronic device supporting multiple spaces, including:
操作222,在标准空间中获取一个主应用。 Operation 222, obtaining a main application in the standard space.
操作224,判断在与标准空间相对的另一个空间中是否存在与主应用同名的应用。 Operation 224, determining whether there is an application with the same name as the main application in another space opposite to the standard space.
首先,从标准空间中随机获取一个应用,一般把运行在标准空间中的应用称为主应用。然后判断在与标准空间相对的另一个空间中是否存在与主应用同名的应用(即分身应用)。例如,在标准空间中随机获取一个应用QQ,然后判断在与标准空间相对的另一个空间中是否存在与主应用同名的应用QQ。一般情况下不同的同名应用之间的数据是不能够共享的。First, an application is randomly obtained from the standard space, and the application running in the standard space is generally referred to as the main application. Then it is judged whether there is an application (ie, a avatar application) having the same name as the main application in another space opposite to the standard space. For example, an application QQ is randomly acquired in the standard space, and then it is judged whether there is an application QQ having the same name as the main application in another space opposite to the standard space. In general, data between different applications of the same name cannot be shared.
操作226,若存在,则获取与主应用同名的应用作为主应用对应的分身应用。 Operation 226, if yes, acquires an application with the same name as the main application as the avatar application corresponding to the main application.
操作228,主应用及与主应用对应的分身应用构成一组指定应用。 Operation 228, the main application and the avatar application corresponding to the main application constitute a set of designated applications.
若在与标准空间相对的另一个空间中存在与主应用同名的应用,则将该同名应用作为主应用的分身应用,该主应用及与该主应用对应的分身应用构成一组指定应用。指定应用,指的就是应用双开且分别运行在不同的空间内的相同应用。If there is an application with the same name as the main application in another space opposite to the standard space, the application with the same name is used as the avatar application of the main application, and the main application and the avatar application corresponding to the main application constitute a set of designated applications. Designated application refers to the same application that is dual-open and runs in different spaces.
本申请实施例中,在支持多空间的电子设备中,获取运行在不同空间中的同名应用,以备后续在当一个应用的运行状态发生变化时,若该应用在其他空间中存在同名应用,且这些同名应用之间可以实现数据共享,则就可以将该运行状态发生变化的应用的数据传输至其他同名应用进行暂存,从而避免了该运行状态发生变化的应用的数据丢失的问题。In the embodiment of the present application, in an electronic device supporting multiple spaces, an application of the same name running in different spaces is acquired, so that when the running state of an application changes, if the application has the same name application in another space, Moreover, data sharing between the applications of the same name can be performed, and the data of the application whose operating state is changed can be temporarily transferred to other applications of the same name for temporary storage, thereby avoiding the problem of data loss of the application whose operating state changes.
在一个实施例中,与标准空间相对的另一个空间为隐私空间。In one embodiment, another space opposite the standard space is a privacy space.
本申请实施例中,在支持多空间的电子设备中,一般情况下运行一个标准空间,当然也可以运行一个隐私空间,该隐私空间中可以供用户使用一些用户进行隐私设置的应用。In the embodiment of the present application, in an electronic device supporting multiple spaces, a standard space is generally run, and of course, a privacy space may be run, and the privacy space may be used by the user to use some users for privacy settings.
在一个实施例中,方法还包括:预先在一组指定应用之间开启了数据共享。In one embodiment, the method further includes pre-opening data sharing between a set of designated applications.
本申请实施例中,当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享。可以预先开启所有的同名应用之间的数据共享,这样当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化,而需要进行数据共享时,就可以直接及时进行数据共享。避免此时若在开启数据共享而造成的数据丢失。In the embodiment of the present application, when it is detected that the running state of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared. Data sharing between all applications of the same name can be started in advance, so that when it is detected that the running state of any one of the main application and the corresponding avatar application changes, and data sharing is required, data sharing can be performed in time. Avoid data loss caused by turning on data sharing at this time.
在一个实施例中,当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享,包括:In an embodiment, when it is detected that the running status of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared, including:
当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则判断应用和对应的分身应用之间是否开启了数据共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, it is determined whether data sharing is enabled between the application and the corresponding avatar application;
若是,则将主应用和对应的分身应用的数据进行共享。If so, the data of the main application and the corresponding avatar application are shared.
具体地,当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则获取被禁用的应用对应的第一数据。然后在其他空间中获取到与该运行状态发生变化的应用对应的同名应用。再获取到了同名应用之后,还需要判断同名应用之间即应用和对应的分身应用之间是否开启了数据共享。若开启了数据共享,此时就可以直接将第一数据在同名应用之间进行共享,从而避免了数据的丢失。Specifically, when it is detected that the running state of any one of the main application and the corresponding avatar application changes, the first data corresponding to the disabled application is acquired. Then, in the other space, the application with the same name corresponding to the application whose running state changes is obtained. After obtaining the application with the same name, it is also necessary to determine whether the data sharing is enabled between the application of the same name and the corresponding avatar application. If data sharing is enabled, the first data can be directly shared between applications of the same name at this time, thereby avoiding data loss.
本申请实施例中,在获取被禁用的应用对应的第一数据、在其他空间中获取到与该运行状态发生变化的应用对应的同名应用之后,进一步判断同名应用之间开启了数据共享。若开启了数据共享,此时就可以直接将第一数据在同名应用之间进行共享,从而避免了数据的丢失。若未开启数据共享,则就不能进行数据共享,此时需要采用其他办法及时开启数据共享,尽量减少数据的丢失。In the embodiment of the present application, after the first data corresponding to the disabled application is acquired, and the application of the same name corresponding to the application whose operating state changes is obtained in another space, the data sharing is further determined between the applications with the same name. If data sharing is enabled, the first data can be directly shared between applications of the same name at this time, thereby avoiding data loss. If data sharing is not enabled, data sharing cannot be performed. In this case, other methods are needed to enable data sharing in time to minimize data loss.
在一个实施例中,如图6所示,提供了一种应用数据防丢装置600,装置包括:指定应用获取模块620、数据共享模块640及数据存储模块660。其中,In an embodiment, as shown in FIG. 6, an application data anti-lost device 600 is provided. The device includes: a specified application obtaining module 620, a data sharing module 640, and a data storage module 660. among them,
指定应用获取模块620,用于获取运行于支持多空间的电子设备中的一组指定应用,一组指定应用包括主应用和对应的分身应用,主应用和分身应用为分别运行于电子设备的不同空间中的同名应用;The specified application obtaining module 620 is configured to obtain a set of specified applications running in an electronic device supporting multiple spaces, where the specified set of applications includes a main application and a corresponding avatar application, and the main application and the avatar application are respectively operated on the electronic device. The same name application in space;
数据共享模块640,用于当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将主应用和对应的分身应用的数据进行共享;The data sharing module 640 is configured to share the data of the main application and the corresponding avatar application when detecting that the running state of any one of the main application and the corresponding avatar application changes;
数据存储模块660,用于获取共享之后的数据进行存储以防止数据丢失。The data storage module 660 is configured to acquire data after sharing for storage to prevent data loss.
在一个实施例中,如图7所示,数据共享模块640,包括:In an embodiment, as shown in FIG. 7, the data sharing module 640 includes:
第一数据获取模块642,用于当检测到主应用和对应的分身应用中的任意一个被禁用时,则获取被禁用的应用对应的数据,数据为第一数据;The first data obtaining module 642 is configured to: when it is detected that any one of the main application and the corresponding avatar application is disabled, acquire data corresponding to the disabled application, where the data is the first data;
第一数据暂存模块644,用于将第一数据传输至与被禁用的应用同名的应用中进行暂存。The first data temporary storage module 644 is configured to temporarily transfer the first data to an application having the same name as the disabled application.
在一个实施例中,如图8所示,数据共享模块640,还包括:第一数据回传模块646,用于当检测到被禁用的应用解除禁用时,则将暂存在与被禁用的应用同名的应用中的第一数据回传至被禁用的应用。In an embodiment, as shown in FIG. 8, the data sharing module 640 further includes: a first data backhaul module 646, configured to temporarily and temporarily disable the disabled application when it is detected that the disabled application is disabled. The first data in the application with the same name is passed back to the disabled application.
在一个实施例中,指定应用获取模块620,还用于在标准空间中获取一个主应用;判断在与标准空间相对的另一个空间中是否存在与主应用同名的应用;若存在,则获取与主应用同名的应用作为主应用对应的分身应用;主应用及与主应用对应的分身应用构成一组指定应用。In an embodiment, the application obtaining module 620 is further configured to acquire a main application in the standard space; determine whether an application having the same name as the main application exists in another space opposite to the standard space; if yes, obtain and The application with the same name as the main application is the avatar application corresponding to the main application; the main application and the avatar application corresponding to the main application constitute a set of specified applications.
在一个实施例中,提供了一种应用数据防丢装置600,还包括数据共享开启单元,用于预先在一组指定应用之间开启了数据共享。In one embodiment, an application data anti-lost device 600 is provided, further comprising a data sharing on unit for pre-opening data sharing between a group of designated applications.
在一个实施例中,数据共享模块640,还用于当检测到主应用和对应的分身应用中的任意一个的运行状态发生变化时,则判断应用和对应的分身应用之间是否开启了数据共享;In an embodiment, the data sharing module 640 is further configured to: when it is detected that the running state of any one of the main application and the corresponding avatar application changes, determine whether data sharing is enabled between the application and the corresponding avatar application. ;
若是,则将主应用和对应的分身应用的数据进行共享。If so, the data of the main application and the corresponding avatar application are shared.
上述应用数据防丢装置中各个模块的划分仅用于举例说明,在其他实施例中,可将应用数据防丢装置按照需要划分为不同的模块,以完成上述应用数据防丢装置的全部或部分功能。The division of each module in the application data anti-lost device is used for illustration only. In other embodiments, the application data anti-lost device may be divided into different modules as needed to complete all or part of the application data anti-lost device. Features.
在一个实施例中,提供了一种计算机可读存储介质,其上存储有计算机程序,计算机程序被处理器执行时实现上述各实施例所提供的应用数据防丢方法的操作。In one embodiment, a computer readable storage medium is provided having stored thereon a computer program that, when executed by a processor, implements the operations of the application data anti-lost method provided by the various embodiments described above.
在一个实施例中,提供了一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,处理器执行计算机程序时实现上述各实施例所提供的应用数据防丢方法的操作。In one embodiment, an electronic device is provided, including a memory, a processor, and a computer program stored on the memory and executable on the processor, and the application data provided by the foregoing embodiments is implemented when the processor executes the computer program The operation of the anti-lost method.
本申请实施例还提供了一种计算机程序产品,当其在计算机上运行时,使得计算机执行上述各实施例所提供的应用数据防丢方法的操作。The embodiment of the present application further provides a computer program product, when it is run on a computer, causing the computer to perform the operation of the application data anti-lost method provided by the foregoing embodiments.
本申请实施例还提供了一种电子设备。如图9所示,为了便于说明,仅示出了与本申请实施例相关的部分,具体技术细节未揭示的,请参照本申请实施例方法部分。该电子设备可以为包括手机、平板电脑、PDA(Personal Digital Assistant,个人数字助理)、POS(Point of Sales,销售终端)、车载电脑、穿戴式设备等任意终端设备,以电子设备为手机为例:An embodiment of the present application also provides an electronic device. As shown in FIG. 9 , for the convenience of description, only the parts related to the embodiments of the present application are shown. If the specific technical details are not disclosed, please refer to the method part of the embodiment of the present application. The electronic device can be any terminal device including a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales), an on-board computer, a wearable device, and the like, and the electronic device is used as a mobile phone. :
图9为与本申请实施例提供的电子设备相关的手机的部分结构的框图。参考图9,手机包括:射频(Radio Frequency,RF)电路910、存储器920、输入单元930、显示单元940、传感器950、音频电路990、无线保真(wireless fidelity,WiFi)模块970、处理器980、以及电源990等部件。本领域技术人员可以理解,图9所示的手机结构并不构成对手机的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。FIG. 9 is a block diagram showing a partial structure of a mobile phone related to an electronic device according to an embodiment of the present application. Referring to FIG. 9, the mobile phone includes: a radio frequency (RF) circuit 910, a memory 920, an input unit 930, a display unit 940, a sensor 950, an audio circuit 990, a wireless fidelity (WiFi) module 970, and a processor 980. And power supply 990 and other components. It will be understood by those skilled in the art that the structure of the handset shown in FIG. 9 does not constitute a limitation to the handset, and may include more or less components than those illustrated, or some components may be combined, or different component arrangements.
其中,RF电路910可用于收发信息或通话过程中,信号的接收和发送,可将基站的下行信息接收后,给处理器980处理;也可以将上行的数据发送给基站。通常,RF 电路包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器(Low Noise Amplifier,LNA)、双工器等。此外,RF电路910还可以通过无线通信与网络和其他设备通信。上述无线通信可以使用任一通信标准或协议,包括但不限于全球移动通讯***(Global System of Mobile communication,GSM)、通用分组无线服务(General Packet Radio Service,GPRS)、码分多址(Code Division Multiple Access,CDMA)、宽带码分多址(Wideband Code Division Multiple Access,WCDMA)、长期演进(Long Term Evolution,LTE))、电子邮件、短消息服务(Short Messaging Service,SMS)等。The RF circuit 910 can be used for receiving and transmitting signals during the transmission and reception of information or during a call. The downlink information of the base station can be received and processed by the processor 980. The uplink data can also be sent to the base station. Generally, RF circuits include, but are not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, RF circuitry 910 can also communicate with the network and other devices via wireless communication. The above wireless communication may use any communication standard or protocol, including but not limited to Global System of Mobile communication (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (Code Division). Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (LTE), e-mail, Short Messaging Service (SMS), and the like.
存储器920可用于存储软件程序以及模块,处理器980通过运行存储在存储器920的软件程序以及模块,从而执行手机的各种功能应用以及数据处理。存储器920可主要包括程序存储区和数据存储区,其中,程序存储区可存储操作***、至少一个功能所需的应用程序(比如声音播放功能的应用程序、图像播放功能的应用程序等)等;数据存储区可存储根据手机的使用所创建的数据(比如音频数据、通讯录等)等。此外,存储器920可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 920 can be used to store software programs and modules, and the processor 980 executes various functional applications and data processing of the mobile phone by running software programs and modules stored in the memory 920. The memory 920 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as an application of a sound playing function, an application of an image playing function, etc.); The data storage area can store data (such as audio data, address book, etc.) created according to the use of the mobile phone. Moreover, memory 920 can include high speed random access memory, and can also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
输入单元930可用于接收输入的数字或字符信息,以及产生与手机900的用户设置以及功能控制有关的键信号输入。具体地,输入单元930可包括触控面板931以及其他输入设备932。触控面板931,也可称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板931上或在触控面板931附近的操作),并根据预先设定的程式驱动相应的连接装置。在一个实施例中,触控面板931可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器980,并能接收处理器980发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板931。除了触控面板931,输入单元930还可以包括其他输入设备932。具体地,其他输入设备932可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)等中的一种或多种。The input unit 930 can be configured to receive input numeric or character information and to generate key signal inputs related to user settings and function control of the handset 900. Specifically, the input unit 930 may include a touch panel 931 and other input devices 932. The touch panel 931, also referred to as a touch screen, can collect touch operations on or near the user (such as the user using a finger, a stylus, or the like on the touch panel 931 or near the touch panel 931. Operation) and drive the corresponding connection device according to a preset program. In one embodiment, the touch panel 931 can include two portions of a touch detection device and a touch controller. Wherein, the touch detection device detects the touch orientation of the user, and detects a signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts the touch information into contact coordinates, and sends the touch information. The processor 980 is provided and can receive commands from the processor 980 and execute them. In addition, the touch panel 931 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch panel 931, the input unit 930 may also include other input devices 932. Specifically, other input devices 932 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control buttons, switch buttons, etc.).
显示单元940可用于显示由用户输入的信息或提供给用户的信息以及手机的各种菜单。显示单元940可包括显示面板941。在一个实施例中,可以采用液晶显示器(Liquid Crystal Display,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板941。在一个实施例中,触控面板931可覆盖显示面板941,当触控面板931检测到在其上或附近的触摸操作后,传送给处理器980以确定触摸事件的类型,随后处理器980根据触摸事件的类型在显示面板941上提供相应的视觉输出。虽然在图9中,触控面板931与显示面板941是作为两个独立的部件来实现手机的输入和输入功能,但是在某些实施例中,可以将触控面板931与显示面板941集成而实现手机的输入和输出功能。The display unit 940 can be used to display information input by the user or information provided to the user as well as various menus of the mobile phone. The display unit 940 can include a display panel 941. In one embodiment, the display panel 941 may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like. In one embodiment, the touch panel 931 can cover the display panel 941. When the touch panel 931 detects a touch operation on or near it, the touch panel 931 transmits to the processor 980 to determine the type of the touch event, and then the processor 980 is The type of touch event provides a corresponding visual output on display panel 941. Although the touch panel 931 and the display panel 941 are used as two independent components to implement the input and input functions of the mobile phone in FIG. 9, in some embodiments, the touch panel 931 and the display panel 941 may be integrated. Realize the input and output functions of the phone.
手机900还可包括至少一种传感器950,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板941的亮度,接近传感器可在手机移动到耳边时,关闭显示面板941和/或背光。运动传感器可包括加速度传感器,通过加速度传感器可检测各个方向上加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换)、振动识别相关功能(比如计步器、敲击)等;此外,手机还可配置陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器等。The handset 900 can also include at least one type of sensor 950, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 941 according to the brightness of the ambient light, and the proximity sensor may close the display panel 941 and/or when the mobile phone moves to the ear. Or backlight. The motion sensor may include an acceleration sensor, and the acceleration sensor can detect the magnitude of the acceleration in each direction, and the magnitude and direction of the gravity can be detected at rest, and can be used to identify the gesture of the mobile phone (such as horizontal and vertical screen switching), and vibration recognition related functions (such as Pedometer, tapping, etc.; in addition, the phone can also be equipped with gyroscopes, barometers, hygrometers, thermometers, infrared sensors and other sensors.
音频电路990、扬声器991和传声器992可提供用户与手机之间的音频接口。音频电路990可将接收到的音频数据转换后的电信号,传输到扬声器991,由扬声器991转换为声音信号输出;另一方面,传声器992将收集的声音信号转换为电信号,由音频电路990接收后转换为音频数据,再将音频数据输出处理器980处理后,经RF电路910可以发送给另一手机,或者将音频数据输出至存储器920以便后续处理。 Audio circuitry 990, speaker 991, and microphone 992 can provide an audio interface between the user and the handset. The audio circuit 990 can transmit the converted electrical data of the received audio data to the speaker 991 for conversion to the sound signal output by the speaker 991; on the other hand, the microphone 992 converts the collected sound signal into an electrical signal, by the audio circuit 990. After receiving, it is converted into audio data, and after being processed by the audio data output processor 980, it can be sent to another mobile phone via the RF circuit 910, or the audio data can be output to the memory 920 for subsequent processing.
WiFi属于短距离无线传输技术,手机通过WiFi模块970可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图9示出了WiFi模块970,但是可以理解的是,其并不属于手机900的必须构成,可以根据需要而省略。WiFi is a short-range wireless transmission technology, and the mobile phone can help users to send and receive emails, browse web pages, and access streaming media through the WiFi module 970, which provides users with wireless broadband Internet access. Although FIG. 9 shows the WiFi module 970, it can be understood that it does not belong to the essential configuration of the mobile phone 900 and can be omitted as needed.
处理器980是手机的控制中心,利用各种接口和线路连接整个手机的各个部分,通过运行或执行存储在存储器920内的软件程序和/或模块,以及调用存储在存储器 920内的数据,执行手机的各种功能和处理数据,从而对手机进行整体监控。在一个实施例中,处理器980可包括一个或多个处理单元。在一个实施例中,处理器980可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作***、用户界面和应用程序等;调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器980中。The processor 980 is the control center of the handset, which connects various portions of the entire handset using various interfaces and lines, by executing or executing software programs and/or modules stored in the memory 920, and invoking data stored in the memory 920, executing The phone's various functions and processing data, so that the overall monitoring of the phone. In one embodiment, processor 980 can include one or more processing units. In one embodiment, the processor 980 can integrate an application processor and a modem processor, wherein the application processor primarily processes an operating system, a user interface, an application, and the like; the modem processor primarily processes wireless communications. It will be appreciated that the above described modem processor may also not be integrated into the processor 980.
手机900还包括给各个部件供电的电源990(比如电池),优选的,电源可以通过电源管理***与处理器980逻辑相连,从而通过电源管理***实现管理充电、放电、以及功耗管理等功能。The mobile phone 900 also includes a power source 990 (such as a battery) that supplies power to various components. Preferably, the power source can be logically coupled to the processor 980 through a power management system to manage functions such as charging, discharging, and power management through the power management system.
在一个实施例中,手机900还可以包括摄像头、蓝牙模块等。In one embodiment, the handset 900 can also include a camera, a Bluetooth module, and the like.
本申请所使用的对存储器、存储、数据库或其它介质的任何引用可包括非易失性和/或易失性存储器。合适的非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM),它用作外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDR SDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus)直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)。Any reference to a memory, storage, database or other medium used herein may include non-volatile and/or volatile memory. Suitable non-volatile memories can include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM), which acts as an external cache. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronization. Link (Synchlink) DRAM (SLDRAM), Memory Bus (Rambus) Direct RAM (RDRAM), Direct Memory Bus Dynamic RAM (DRDRAM), and Memory Bus Dynamic RAM (RDRAM).
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。The above-mentioned embodiments are merely illustrative of several embodiments of the present application, and the description thereof is more specific and detailed, but is not to be construed as limiting the scope of the claims. It should be noted that a number of variations and modifications may be made by those skilled in the art without departing from the spirit and scope of the present application. Therefore, the scope of the invention should be determined by the appended claims.

Claims (28)

  1. 一种应用数据防丢方法,包括:An application data anti-lost method includes:
    获取运行于支持多空间的电子设备中的一组指定应用,所述一组指定应用包括主应用和对应的分身应用,所述主应用和分身应用为分别运行于所述电子设备的不同空间中的同名应用;Obtaining a set of specified applications running in an electronic device supporting multiple spaces, the set of specified applications including a main application and a corresponding avatar application, the main application and the avatar application respectively running in different spaces of the electronic device Application of the same name;
    当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared;
    获取共享之后的数据进行存储以防止数据丢失。The data after sharing is obtained for storage to prevent data loss.
  2. 根据权利要求1所述的方法,其特征在于,所述当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享,包括:The method according to claim 1, wherein when the operating state of any one of the main application and the corresponding avatar application is detected to change, the main application and the corresponding avatar application are Data sharing, including:
    当检测到所述主应用和对应的分身应用中的任意一个被禁用时,则获取被禁用的应用对应的数据,所述数据为第一数据;When it is detected that any one of the main application and the corresponding avatar application is disabled, acquiring data corresponding to the disabled application, where the data is the first data;
    将所述第一数据传输至与所述被禁用的应用同名的应用中进行暂存。Transmitting the first data to an application having the same name as the disabled application for temporary storage.
  3. 根据权利要求1所述的方法,其特征在于,在将所述第一数据传输至与所述被禁用的应用同名的应用中进行暂存之后,包括:The method according to claim 1, wherein after the first data is temporarily stored in an application having the same name as the disabled application, the method comprises:
    当检测到所述被禁用的应用解除禁用时,则将暂存在与所述被禁用的应用同名的应用中的所述第一数据回传至所述被禁用的应用。When it is detected that the disabled application is deactivated, the first data in the application with the same name as the disabled application is backhauled to the disabled application.
  4. 根据权利要求1所述的方法,其特征在于,所述获取运行于支持多空间的电子设备中的一组指定应用,包括:The method according to claim 1, wherein the obtaining a set of specified applications running in an electronic device supporting multiple spaces comprises:
    在标准空间中获取一个主应用;Get a main application in the standard space;
    判断在与标准空间相对的另一个空间中是否存在与所述主应用同名的应用;Determining whether there is an application with the same name as the main application in another space opposite to the standard space;
    若存在,则获取与所述主应用同名的应用作为所述主应用对应的分身应用;If yes, obtaining an application with the same name as the main application as a avatar application corresponding to the main application;
    所述主应用及与所述主应用对应的分身应用构成一组指定应用。The main application and the avatar application corresponding to the main application constitute a set of designated applications.
  5. 根据权利要求4所述的方法,其特征在于,所述与标准空间相对的另一个空间为隐私空间。The method of claim 4 wherein the other space opposite the standard space is a privacy space.
  6. 根据权利要求1所述的方法,其特征在于,所述方法还包括:The method of claim 1 further comprising:
    预先在所述一组指定应用之间开启了数据共享。Data sharing is initiated in advance between the set of specified applications.
  7. 根据权利要求1所述的方法,其特征在于,所述当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享,包括:The method according to claim 1, wherein when the operating state of any one of the main application and the corresponding avatar application is detected to change, the main application and the corresponding avatar application are Data sharing, including:
    当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则判断所述应用和对应的分身应用之间是否开启了数据共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, determining whether data sharing is enabled between the application and the corresponding avatar application;
    若是,则将所述主应用和对应的分身应用的数据进行共享。If yes, the data of the main application and the corresponding avatar application are shared.
  8. 一种多空间应用数据防丢装置,所述装置包括:A multi-space application data anti-lost device, the device comprising:
    指定应用获取模块,用于获取运行于支持多空间的电子设备中的一组指定应用,所述一组指定应用包括主应用和对应的分身应用,所述主应用和分身应用为分别运行于所述电子设备的不同空间中的同名应用;An application obtaining module is configured to obtain a set of specified applications running in an electronic device supporting multiple spaces, where the set of specified applications includes a main application and a corresponding avatar application, where the main application and the avatar application are respectively operated An application of the same name in different spaces of an electronic device;
    数据共享模块,用于当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享;a data sharing module, configured to share data of the main application and the corresponding avatar application when detecting that a running state of any one of the main application and the corresponding avatar application changes;
    数据存储模块,用于获取共享之后的数据进行存储以防止数据丢失。A data storage module for acquiring data after sharing for storage to prevent data loss.
  9. 根据权利要求8所述的装置,其特征在于,所述装置还包括:The device according to claim 8, wherein the device further comprises:
    第一数据获取模块,用于当检测到所述主应用和对应的分身应用中的任意一个被禁用时,则获取被禁用的应用对应的数据,所述数据为第一数据;a first data obtaining module, configured to: when it is detected that any one of the main application and the corresponding avatar application is disabled, acquire data corresponding to the disabled application, where the data is first data;
    第一数据暂存模块,用于将所述第一数据传输至与所述被禁用的应用同名的应用中进行暂存。And a first data temporary storage module, configured to transmit the first data to an application that has the same name as the disabled application for temporary storage.
  10. 根据权利要求8所述的装置,其特征在于,所述装置还包括:The device according to claim 8, wherein the device further comprises:
    第一数据回传模块,用于当检测到所述被禁用的应用解除禁用时,则将暂存在与所述被禁用的应用同名的应用中的所述第一数据回传至所述被禁用的应用。a first data backhaul module, configured to: when detecting that the disabled application is deactivated, return the first data in an application that has the same name as the disabled application to the disabled Applications.
  11. 根据权利要求8所述的装置,其特征在于,所述指定应用获取模块还用于在标准空间中获取一个主应用;判断在与标准空间相对的另一个空间中是否存在与所述主应用同名的应用;若存在,则获取与所述主应用同名的应用作为所述主应用对应的分身应用;所述主应用及与所述主应用对应的分身应用构成一组指定应用。The apparatus according to claim 8, wherein the specified application obtaining module is further configured to acquire a main application in a standard space; and determine whether a same name as the main application exists in another space opposite to the standard space. The application, if present, obtains an application having the same name as the main application as the avatar application corresponding to the main application; the main application and the avatar application corresponding to the main application constitute a set of designated applications.
  12. 根据权利要求11所述的装置,其特征在于,所述与标准空间相对的另一个空间为隐私空间。The apparatus of claim 11 wherein said another space opposite said standard space is a privacy space.
  13. 根据权利要求8所述的装置,其特征在于,所述装置还包括:The device according to claim 8, wherein the device further comprises:
    数据共享开启模块,用于预先在所述一组指定应用之间开启了数据共享。A data sharing on module for pre-opening data sharing between the set of specified applications.
  14. 根据权利要求8所述的装置,其特征在于,所述数据共享模块还用于当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则判断所述应用和对应的分身应用之间是否开启了数据共享;若是,则将所述主应用和对应的分身应用的数据进行共享。The device according to claim 8, wherein the data sharing module is further configured to: when detecting an operation state of any one of the main application and the corresponding avatar application, determine the application and Whether data sharing is enabled between the corresponding avatar applications; if so, sharing the data of the main application and the corresponding avatar application.
  15. 一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如下操作:A computer readable storage medium having stored thereon a computer program, the computer program being executed by a processor to:
    获取运行于支持多空间的电子设备中的一组指定应用,所述一组指定应用包括主应用和对应的分身应用,所述主应用和分身应用为分别运行于所述电子设备的不同空间中的同名应用;Obtaining a set of specified applications running in an electronic device supporting multiple spaces, the set of specified applications including a main application and a corresponding avatar application, the main application and the avatar application respectively running in different spaces of the electronic device Application of the same name;
    当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared;
    获取共享之后的数据进行存储以防止数据丢失。The data after sharing is obtained for storage to prevent data loss.
  16. 根据权利要求15所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行所述当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享操作时,还执行如下操作:The computer readable storage medium according to claim 15, wherein said computer program is executed by said processor when said change in an operational state of any one of said main application and a corresponding avatar application is detected When the data sharing between the main application and the corresponding avatar application is performed, the following operations are also performed:
    当检测到所述主应用和对应的分身应用中的任意一个被禁用时,则获取被禁用的应用对应的数据,所述数据为第一数据;When it is detected that any one of the main application and the corresponding avatar application is disabled, acquiring data corresponding to the disabled application, where the data is the first data;
    将所述第一数据传输至与所述被禁用的应用同名的应用中进行暂存。Transmitting the first data to an application having the same name as the disabled application for temporary storage.
  17. 根据权利要求15所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行所述将所述第一数据传输至与所述被禁用的应用同名的应用中进行暂存操作之后,还执行如下操作:The computer readable storage medium according to claim 15, wherein said computer program is executed by said processor to transfer said first data to an application having the same name as said disabled application for temporary storage operation After that, also do the following:
    当检测到所述被禁用的应用解除禁用时,则将暂存在与所述被禁用的应用同名的应用 中的所述第一数据回传至所述被禁用的应用。When it is detected that the disabled application is deactivated, the first data in the application having the same name as the disabled application is backhauled to the disabled application.
  18. 根据权利要求15所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行所述获取运行于支持多空间的电子设备中的一组指定应用操作时,还执行如下操作:The computer readable storage medium according to claim 15, wherein when the computer program is executed by the processor to obtain a set of specified application operations running in an electronic device supporting multiple spaces, the computer program further performs the following operations:
    在标准空间中获取一个主应用;Get a main application in the standard space;
    判断在与标准空间相对的另一个空间中是否存在与所述主应用同名的应用;Determining whether there is an application with the same name as the main application in another space opposite to the standard space;
    若存在,则获取与所述主应用同名的应用作为所述主应用对应的分身应用;If yes, obtaining an application with the same name as the main application as a avatar application corresponding to the main application;
    所述主应用及与所述主应用对应的分身应用构成一组指定应用。The main application and the avatar application corresponding to the main application constitute a set of designated applications.
  19. 根据权利要求18所述的计算机可读存储介质,其特征在于,所述与标准空间相对的另一个空间为隐私空间。The computer readable storage medium of claim 18, wherein the other space opposite the standard space is a privacy space.
  20. 根据权利要求15所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行时,还执行如下操作:A computer readable storage medium according to claim 15, wherein when said computer program is executed by a processor, the following operations are also performed:
    预先在所述一组指定应用之间开启了数据共享。Data sharing is initiated in advance between the set of specified applications.
  21. 根据权利要求15所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行所述当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享操作时,还执行如下操作:The computer readable storage medium according to claim 15, wherein said computer program is executed by said processor when said change in an operational state of any one of said main application and a corresponding avatar application is detected When the data sharing between the main application and the corresponding avatar application is performed, the following operations are also performed:
    当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则判断所述应用和对应的分身应用之间是否开启了数据共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, determining whether data sharing is enabled between the application and the corresponding avatar application;
    若是,则将所述主应用和对应的分身应用的数据进行共享。If yes, the data of the main application and the corresponding avatar application are shared.
  22. 一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现如下操作:An electronic device includes a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor performing the following operations when the computer program is executed:
    获取运行于支持多空间的电子设备中的一组指定应用,所述一组指定应用包括主应用和对应的分身应用,所述主应用和分身应用为分别运行于所述电子设备的不同空间中的同名应用;Obtaining a set of specified applications running in an electronic device supporting multiple spaces, the set of specified applications including a main application and a corresponding avatar application, the main application and the avatar application respectively running in different spaces of the electronic device Application of the same name;
    当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, the data of the main application and the corresponding avatar application are shared;
    获取共享之后的数据进行存储以防止数据丢失。The data after sharing is obtained for storage to prevent data loss.
  23. 根据权利要求22所述的电子设备,其特征在于,所述处理器执行所述当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享操作时,还执行如下操作:The electronic device according to claim 22, wherein said processor executes said main application when said change in an operating state of any one of said main application and a corresponding avatar application is detected When sharing data with the corresponding avatar application, the following operations are also performed:
    当检测到所述主应用和对应的分身应用中的任意一个被禁用时,则获取被禁用的应用对应的数据,所述数据为第一数据;When it is detected that any one of the main application and the corresponding avatar application is disabled, acquiring data corresponding to the disabled application, where the data is the first data;
    将所述第一数据传输至与所述被禁用的应用同名的应用中进行暂存。Transmitting the first data to an application having the same name as the disabled application for temporary storage.
  24. 根据权利要求22所述的电子设备,其特征在于,所述处理器执行所述将所述第一数据传输至与所述被禁用的应用同名的应用中进行暂存操作之后,还执行如下曹组:The electronic device according to claim 22, wherein after the processor performs the temporary storage operation by transmitting the first data to an application having the same name as the disabled application, the processor further performs the following group:
    当检测到所述被禁用的应用解除禁用时,则将暂存在与所述被禁用的应用同名的应用中的所述第一数据回传至所述被禁用的应用。When it is detected that the disabled application is deactivated, the first data in the application with the same name as the disabled application is backhauled to the disabled application.
  25. 根据权利要求22所述的电子设备,其特征在于,所述处理器执行所述获取运行于支持多空间的电子设备中的一组指定应用操作时,还执行如下操作:The electronic device according to claim 22, wherein when the processor performs the acquiring a set of specified application operations running in an electronic device supporting multiple spaces, the processor further performs the following operations:
    在标准空间中获取一个主应用;Get a main application in the standard space;
    判断在与标准空间相对的另一个空间中是否存在与所述主应用同名的应用;Determining whether there is an application with the same name as the main application in another space opposite to the standard space;
    若存在,则获取与所述主应用同名的应用作为所述主应用对应的分身应用;If yes, obtaining an application with the same name as the main application as a avatar application corresponding to the main application;
    所述主应用及与所述主应用对应的分身应用构成一组指定应用。The main application and the avatar application corresponding to the main application constitute a set of designated applications.
  26. 根据权利要求25所述的电子设备,其特征在于,所述与标准空间相对的另一个空间为隐私空间。The electronic device of claim 25, wherein the other space opposite the standard space is a privacy space.
  27. 根据权利要求22所述的电子设备,其特征在于,所述处理器还执行如下操作:The electronic device of claim 22, wherein the processor further performs the following operations:
    预先在所述一组指定应用之间开启了数据共享。Data sharing is initiated in advance between the set of specified applications.
  28. 根据权利要求22所述的电子设备,其特征在于,所述处理器执行所述当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则将所述主应用和对应的分身应用的数据进行共享操作时,还执行如下操作:The electronic device according to claim 22, wherein said processor executes said main application when said change in an operating state of any one of said main application and a corresponding avatar application is detected When sharing data with the corresponding avatar application, the following operations are also performed:
    当检测到所述主应用和对应的分身应用中的任意一个的运行状态发生变化时,则判断所述应用和对应的分身应用之间是否开启了数据共享;When it is detected that the running state of any one of the main application and the corresponding avatar application changes, determining whether data sharing is enabled between the application and the corresponding avatar application;
    若是,则将所述主应用和对应的分身应用的数据进行共享。If yes, the data of the main application and the corresponding avatar application are shared.
PCT/CN2019/077508 2018-03-29 2019-03-08 Method and apparatus for preventing loss of application data, storage medium, and electronic device WO2019184683A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810274180.0A CN108563516A (en) 2018-03-29 2018-03-29 Using data anti-lost method and device, storage medium, electronic equipment
CN201810274180.0 2018-03-29

Publications (1)

Publication Number Publication Date
WO2019184683A1 true WO2019184683A1 (en) 2019-10-03

Family

ID=63533526

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/077508 WO2019184683A1 (en) 2018-03-29 2019-03-08 Method and apparatus for preventing loss of application data, storage medium, and electronic device

Country Status (2)

Country Link
CN (1) CN108563516A (en)
WO (1) WO2019184683A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108563516A (en) * 2018-03-29 2018-09-21 广东欧珀移动通信有限公司 Using data anti-lost method and device, storage medium, electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105808059A (en) * 2016-03-04 2016-07-27 北京奇虎科技有限公司 Application processing method and device based on terminal system
CN106406986A (en) * 2016-11-24 2017-02-15 宇龙计算机通信科技(深圳)有限公司 Resource sharing method and device
CN106484547A (en) * 2016-10-10 2017-03-08 广东欧珀移动通信有限公司 A kind of management method, device and terminal for opening application more
CN108563516A (en) * 2018-03-29 2018-09-21 广东欧珀移动通信有限公司 Using data anti-lost method and device, storage medium, electronic equipment

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7225302B2 (en) * 2002-11-27 2007-05-29 Sap Ag Method and software application for avoiding data loss
CN105468478B (en) * 2015-11-26 2019-06-04 北京京东尚科信息技术有限公司 Business datum restoration methods and device after a kind of application crashes
CN105930231B (en) * 2016-04-19 2019-08-27 奇酷软件(深圳)有限公司 Data back up method and system, data reconstruction method and system and mobile terminal
CN106648962B (en) * 2016-10-10 2019-08-30 Oppo广东移动通信有限公司 A kind of management method, device and intelligent terminal for opening application more
CN106528098B (en) * 2016-10-21 2019-08-02 宇龙计算机通信科技(深圳)有限公司 A kind of processing method, device and terminal for opening data between application more

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105808059A (en) * 2016-03-04 2016-07-27 北京奇虎科技有限公司 Application processing method and device based on terminal system
CN106484547A (en) * 2016-10-10 2017-03-08 广东欧珀移动通信有限公司 A kind of management method, device and terminal for opening application more
CN106406986A (en) * 2016-11-24 2017-02-15 宇龙计算机通信科技(深圳)有限公司 Resource sharing method and device
CN108563516A (en) * 2018-03-29 2018-09-21 广东欧珀移动通信有限公司 Using data anti-lost method and device, storage medium, electronic equipment

Also Published As

Publication number Publication date
CN108563516A (en) 2018-09-21

Similar Documents

Publication Publication Date Title
WO2021109926A1 (en) Application sharing method, electronic device and computer-readable storage medium
WO2017206916A1 (en) Method for determining kernel running configuration in processor and related product
WO2021129762A1 (en) Application sharing method, electronic device and computer-readable storage medium
WO2018049897A1 (en) Data backup method and device
WO2018103492A1 (en) Method for setting wifi roaming, and terminal device
WO2018049887A1 (en) Data transmission processing method and terminal device
US20220159777A1 (en) Method for network control and related products
CN106657251A (en) Data synchronizing method and apparatus
WO2018161353A1 (en) Photo sharing method and device
WO2018049893A1 (en) Data transmission method and terminal device
WO2015035947A1 (en) Method for realizing cellphone without card, cellphone and server
WO2020156123A1 (en) Information processing method and terminal device
CN108681437B (en) Display method and device, storage medium and electronic equipment
WO2018103443A1 (en) Network positioning method and terminal device
CN108733337B (en) Screen display method and device, electronic equipment and computer readable storage medium
WO2018049971A1 (en) Hotspot network switching method and terminals
WO2018049934A1 (en) Data migration method and terminals
JP2018504708A (en) Method, device, and system for managing information recommendations
WO2018049894A1 (en) Data transmission method and device
WO2018166202A1 (en) Network positioning method, computer equipment and non-volatile readable storage medium
WO2018049970A1 (en) Hotspot network switching method and terminal
WO2018049885A1 (en) Data migration method and device
WO2019184617A1 (en) Information sharing method and device, computer-readable storage medium and terminal
WO2019184631A1 (en) Information processing method and apparatus, computer-readable storage medium, and terminal
WO2021143669A1 (en) Method for acquiring configuration information and electronic device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19777344

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19777344

Country of ref document: EP

Kind code of ref document: A1