CN110046000B - Applet running method and device - Google Patents

Applet running method and device Download PDF

Info

Publication number
CN110046000B
CN110046000B CN201910331999.0A CN201910331999A CN110046000B CN 110046000 B CN110046000 B CN 110046000B CN 201910331999 A CN201910331999 A CN 201910331999A CN 110046000 B CN110046000 B CN 110046000B
Authority
CN
China
Prior art keywords
data
running
directory
applet
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910331999.0A
Other languages
Chinese (zh)
Other versions
CN110046000A (en
Inventor
崔英林
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Lianshang Network Technology Co Ltd
Original Assignee
Shanghai Lianshang Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanghai Lianshang Network Technology Co Ltd filed Critical Shanghai Lianshang Network Technology Co Ltd
Priority to CN201910331999.0A priority Critical patent/CN110046000B/en
Publication of CN110046000A publication Critical patent/CN110046000A/en
Application granted granted Critical
Publication of CN110046000B publication Critical patent/CN110046000B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • G06F9/44526Plug-ins; Add-ons

Abstract

The embodiment of the application discloses an applet running method and device. One embodiment of the method comprises: establishing a running directory and at least one data directory for the first hosted application; in response to detecting a user start operation on a target applet integrated in the first host application, running the target applet, and storing running data generated in a running process in the running directory; and in response to the detected user closing operation on the target small program, copying the running data in the running directory to the data directory corresponding to the target small program. According to the scheme provided by the embodiment of the application, the data directory is independently set for each small program, so that the data of different small programs are mutually isolated.

Description

Applet running method and device
Technical Field
The embodiment of the application relates to the technical field of computers, in particular to the technical field of internet, and particularly relates to a small program running method and device.
Background
In an operating system, data of a host application is often in the same directory. If multiple applets are integrated into the same host application, each applet can utilize the data under the corresponding directory of the other applet.
Thus, information between the applets integrated in the same host application is intercommunicated, and data isolation between the applets cannot be realized.
Disclosure of Invention
The embodiment of the application provides an applet running method and device.
In a first aspect, an embodiment of the present application provides an applet running method, which is applied to a terminal device, where the terminal device is installed with at least one host application including a first host application; the method comprises the following steps: establishing an operation directory and at least one data directory for the first host application, wherein different data directories are used for storing data of different applets integrated by the first host application, the operation directory is used for storing operation data, and the operation data comprises user behavior data; in response to detecting that a user starting operation on a target applet integrated in the first host application is performed, operating the target applet, and storing operating data generated in the operating process in an operating directory; and in response to the detected user closing operation on the target small program, copying the running data in the running catalog to the data catalog corresponding to the target small program.
In a second aspect, an embodiment of the present application provides an applet running apparatus, which is applied to a terminal device, where the terminal device is installed with at least one host application including a first host application; the device comprises: the establishing unit is configured to establish an operation directory and at least one data directory for the first host application, wherein different data directories are used for storing data of different applets integrated by the first host application, the operation directory is used for storing operation data, and the operation data comprises user behavior data; the running unit is configured to respond to the detection of user starting operation of the target small program integrated in the first host application, run the target small program and store running data generated in the running process in a running directory; and the copying unit is configured to copy the running data in the running directory to the data directory corresponding to the target small program in response to detecting the user closing operation on the target small program.
In a third aspect, an embodiment of the present application provides an electronic device, including: one or more processors; a storage device for storing one or more programs which, when executed by one or more processors, cause the one or more processors to perform a method as in any embodiment of a method for applet execution.
In a fourth aspect, the present application provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements a method as in any one of the embodiments of the applet running method.
According to the applet running scheme provided by the embodiment of the application, firstly, a running directory and at least one data directory are established for a first host application, wherein different data directories are used for storing data of different applets integrated by the first host application, the running directory is used for storing running data, and the running data comprises user behavior data. And then, responding to the detected user starting operation of the target small program integrated in the first host application, operating the target small program, and storing the operating data generated in the operating process in an operating directory. And finally, in response to the detected user closing operation on the target small program, copying the running data in the running directory to the data directory corresponding to the target small program. According to the scheme provided by the embodiment of the application, the data directory is independently set for each small program, so that the data of different small programs are mutually isolated. In addition, the running directory is set for the running small programs, so that the use permission is set for the currently running data, and permission isolation is achieved.
Drawings
Other features, objects and advantages of the present application will become more apparent upon reading of the following detailed description of non-limiting embodiments thereof, made with reference to the accompanying drawings in which:
FIG. 1 is an exemplary system architecture diagram in which the present application may be applied;
FIG. 2 is a flow diagram of one embodiment of an applet running method according to the present application;
FIG. 3 is a schematic diagram of a host application scenario for an applet running method according to the application;
FIG. 4 is a flow chart of yet another embodiment of a method of applet running according to the present application;
FIG. 5 is a schematic block diagram of one embodiment of an applet running device according to the application;
FIG. 6 is a schematic block diagram of a computer system suitable for use in implementing an electronic device according to embodiments of the present application.
Detailed Description
The present application will be described in further detail with reference to the following drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the relevant invention and not restrictive of the invention. It should be noted that, for convenience of description, only the portions related to the related invention are shown in the drawings.
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
Fig. 1 illustrates an exemplary system architecture 100 that may host an embodiment of an applet running method or applet running apparatus to which the present application is applicable.
As shown in fig. 1, the system architecture 100 may include terminal devices 101, 102, 103, a network 104, and a server 105. The network 104 serves as a medium for providing communication links between the terminal devices 101, 102, 103 and the server 105. Network 104 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal devices 101, 102, 103 to interact with the server 105 via the network 104 to receive or send messages or the like. Various communication client host applications, such as an applet running host application, a video host application, a live host application, an instant messaging tool, a mailbox client, social platform software, and the like, may be installed on the terminal devices 101, 102, 103.
Here, the terminal apparatuses 101, 102, and 103 may be hardware or software. When the terminal devices 101, 102, 103 are hardware, they may be various electronic devices having a display screen, including but not limited to smart phones, tablet computers, e-book readers, laptop portable computers, desktop computers, and the like. When the terminal apparatuses 101, 102, 103 are software, they can be installed in the electronic apparatuses listed above. It may be implemented as multiple pieces of software or software modules (e.g., multiple pieces of software or software modules to provide distributed services) or as a single piece of software or software module. And is not particularly limited herein.
The server 105 may be a server providing various services, such as a background server providing support for the terminal devices 101, 102, 103. The background server can analyze and process the received data such as the historical behavior data of the user and feed back the processing result to the terminal equipment.
It should be noted that the applet running method provided in the embodiment of the present application is generally executed by the terminal devices 101, 102, and 103, and accordingly, the applet running apparatus may be disposed in the terminal devices 101, 102, and 103.
It should be understood that the number of terminal devices, networks, and servers in fig. 1 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
With continued reference to FIG. 2, a flow 200 of one embodiment of an applet running method in accordance with the present application is shown. The small program running method comprises the following steps:
step 201, establishing an operation directory and at least one data directory for the first host application, wherein different data directories are used for storing data of different applets integrated by the first host application, the operation directory is used for storing operation data, and the operation data comprises user behavior data.
In this embodiment, an execution subject (for example, the terminal device shown in fig. 1) of the applet running method may establish a running directory and a data directory for the first host application. In this way, it is convenient to set the authority for the operation directory separately, so that the execution main body or the server cannot apply the operation data under the operation directory to the small program without the authority. The first hosted application may be any applet-integrated hosted application installed by the terminal device. User behavior data refers to data generated by the user's behavior with respect to an applet. For example, the user behavior data may include the time the user accessed the web page through the applet and the web address of the web page. The data under the data directory may include user behavior data. Data of different target applets can be stored in different data directories, so that the data in different data directories can be isolated. Specifically, folders may exist under both the data directory and the run directory, and data may be stored in the folders. A host application refers to an application that has an applet running platform. The applet running platform is used for providing a running environment for the applet in the host application, and is a necessary condition for the applet to be started and run in the host application. The applet running platform can provide the applet with templates of interfaces to be displayed, a browser and personalized services for different host applications or different operating systems.
Step 202, in response to detecting a user start operation on the target applet integrated in the first host application, running the target applet, and storing running data generated in the running process in a running directory.
In this embodiment, the executing agent may start and run the target applet integrated in the first host application in response to detecting a user start operation of a user on the target applet. And, the execution main body may store the operation data generated in the operation process in the operation directory. The user start operation is an operation by the user for instructing the start of the above-mentioned target applet.
In some optional implementations of this embodiment, step 202 includes: in response to detecting user starting operation of a target applet integrated in a first host application, judging whether running data exists in a data directory corresponding to the target applet; if the target applet exists, decrypting and storing the existing running data in a running directory, and running the target applet based on the running data in the running directory; if not, the target applet is run.
In these alternative implementations, the execution main body may determine whether the running data exists in the data directory in response to detecting a user-initiated operation on the target applet by the user. Thus, the execution body can execute the subsequent steps according to the judgment result.
The execution main body may store the operation data in the data directory in the operation directory if the operation data exists, and then, the execution main body may execute the target applet based on the operation data. If the judgment result is that the running data does not exist in the data directory corresponding to the target applet, the execution main body can directly run the target applet.
In practice, the execution agent may execute the target applet based on the execution data in a variety of ways. For example, the executing agent may upload the running data to a server of the target applet, so that the server determines the objects preferred by the user. For example, the favorite objects may be video types, categories of goods, and the like. The server is then able to push relevant videos, goods or advertisements, etc. to the targeted applet of the executing agent. In this way, the execution body can play out the pushed content. Furthermore, if the target applet has instructions instructing the user to view a web page, the execution body may determine that the user has viewed the web page as long as a user's viewing record for the web page appears in the operation data.
These implementations may better run the target applet for the user of the terminal device using the run data in the presence of the run data.
Step 203, in response to detecting the user closing operation on the target applet, copying the running data in the running directory to the data directory corresponding to the target applet.
In this embodiment, the executing entity may copy the running data in the running directory to the data directory corresponding to the target applet in response to detecting a user closing operation of the target applet by the user. Specifically, the user closing operation is an operation of a user for instructing to close the target applet.
In some optional implementations of this embodiment, keys of data directories corresponding to different applets integrated by the first host application are different.
In these alternative implementations, the execution principal or the server may set a key to the data directory, where the set key has a one-to-one relationship with the applet id. Thus, the key is different between the data directories where the data of different applets are located. In this way, data between the applets can be better isolated to prevent the data of the applets from being utilized at will.
In some optional implementations of this embodiment, after step 203, the method may further include:
and encrypting the running data of the current running of the target small program under the data directory corresponding to the target small program.
In these optional implementation manners, the execution main body may encrypt the operation data generated by the current operation of the target applet in the data directory corresponding to the target applet. Where the encrypted data includes the copied data. In addition, other data may be included, such as data that is periodically cached from under the run directory to under the data directory. The encryption here uses keys only for the data directory corresponding to the target applet.
In these implementation manners, the running data in the data directories may be encrypted to implement isolation of the data in each data directory.
In some optional implementations of this embodiment, after step 203, the method further includes:
and emptying data in the running directory.
In these alternative implementations, the execution subject may flush the data in the execution directory after copying the execution data in the execution directory to the data directory, so that other applets can store the execution data therein.
In some optional implementations of this embodiment, the running data in the running directory is only used to execute the instruction corresponding to the running applet integrated in the first host application.
In these alternative implementations, the execution subject may apply the running data under the running directory to the currently running applet integrated with the first hosted application, but may not apply the running data under the running directory to the applet that is not in operation or is not integrated with the first hosted application. Specifically, the instruction corresponding to the applet may be various, for example, the instruction may instruct to send the operation data to the server corresponding to the applet, so as to facilitate data analysis by the server, or facilitate advertisement pushing from the server to the terminal device.
The optional implementation modes can isolate the data under the operating directory by limiting the use permission so as to better protect the data in the operating directory and prevent the execution main body from applying the data in the operating directory to other small programs.
With continued reference to fig. 3, fig. 3 is a schematic diagram of a host application scenario of the applet running method according to the present embodiment. In the hosting application scenario of fig. 3, the terminal device 301 is installed with 5 hosting applications including an instant messaging hosting application. The terminal device 301 may establish a running directory and 3 data directories 302 for the instant messaging host application, where the 3 data directories are used to store data of 3 different applets integrated by the instant messaging host application, and the running directory is used to store running data, where the running data includes user behavior data. The terminal device 301 responds to the detection of the user starting operation of the game applet integrated with the instant messaging host application, runs the game applet and stores the running data 303 generated in the running process in the running directory. The terminal device 301, in response to detecting a user-closing operation on the game applet, copies the execution data 303 under the execution directory to the data directory 304 corresponding to the game applet.
The method provided by the above embodiment of the present application isolates data between different applets by setting a data directory for each applet individually. In addition, the embodiment sets an operation directory for the running small program so as to set the use permission for the currently running operation data and realize permission isolation.
With further reference to FIG. 4, a flow 400 of yet another embodiment of an applet running method is illustrated. The flow 400 of the applet running method includes the following steps:
step 401, establishing an operation directory and at least one data directory for the first host application, where different data directories are used to store data of different applets integrated by the first host application, and the operation directory is used to store operation data, where the operation data includes user behavior data.
In this embodiment, an execution subject (for example, the terminal device shown in fig. 1) of the applet running method may establish a running directory and a data directory for the first host application. In this way, it is convenient to set the authority for the operation directory separately, so that the execution main body or the server cannot apply the operation data under the operation directory to the small program without the authority. The first hosted application may be any applet-integrated hosted application installed by the terminal device. User behavior data refers to data generated by user actions performed with respect to an applet.
And 402, in response to detecting the user starting operation of the target applet integrated in the first host application, operating the target applet, and storing the operating data generated in the operating process in an operating directory.
In this embodiment, the executing agent may execute the target applet integrated in the first host application in response to detecting a user start operation of a user on the target applet, and store the execution data generated in the execution process in the execution directory. The user start operation is an operation by the user for instructing the start of the target applet.
And step 403, backing up the running data generated in the running directory to a data directory corresponding to the target applet at regular time.
In this embodiment, the execution main body may periodically back up the operation data generated under the operation target in the data directory corresponding to the target applet. For example, the data may be compressed and stored under a data directory for backup. In addition, after each backup, the backed-up data can be encrypted and the backed-up data can be ensured not to be used freely.
In response to detecting a user closing operation on the target applet, the step 404 copies the running data in the running directory to the data directory corresponding to the target applet.
In this embodiment, the executing entity may copy the running data in the running directory to the data directory corresponding to the target applet in response to detecting a user closing operation of the target applet by the user. Specifically, the user closing operation is an operation of a user for instructing to close the target applet.
In some optional implementations of this embodiment, step 404 includes: and copying the operation data added after the operation data is backed up at the last time in the operation directory to the data directory corresponding to the target applet.
In these alternative implementations, the above-mentioned copying process of the execution main body may be to copy data that is not backed up to the data directory in the data in the operating directory, and the data that has been backed up to the data directory before may not be stored repeatedly to the data directory. Therefore, repeated storage of the operation data can be avoided, and the storage efficiency of the data is improved.
In some optional host application scenarios for these implementations, after step 404, the method may further include: and encrypting the running data backed up at regular time and the copied running data under the data directory corresponding to the target applet.
In these alternative host application scenarios, the execution entity may encrypt the run data stored from the run directory to the data directory. Specifically, the data encrypted here may include data that is backed up at regular time and data that is copied. The encrypted key is a key set for the data directory of the target applet.
The host application scenes can encrypt the stored data after all the running data in the running directory are stored in the data directory, so that the performance problem caused by too frequent encryption is avoided, and smooth running of the applet is ensured.
The embodiment carries out timing backup on the running data so as to avoid the performance problem of the terminal equipment caused by over concentrated storage time possibly brought by unified storage after the small program running is finished.
With further reference to fig. 5, as an implementation of the methods shown in the above-mentioned figures, the present application provides an embodiment of an applet running apparatus, which corresponds to the method embodiment shown in fig. 2, and which can be applied in various electronic devices.
As shown in fig. 5, the applet running device 500 of the present embodiment includes: a creating unit 501, an executing unit 502 and a copying unit 503. The establishing unit 501 is configured to establish an operation directory and at least one data directory for the first host application, where different data directories are used for storing data of different applets integrated by the first host application, the operation directory is used for storing operation data, and the operation data includes user behavior data; an execution unit 502 configured to execute a target applet integrated in a first host application in response to detecting a user start operation on the target applet, store operation data generated during an operation process in an operation directory; and the copying unit 503 is configured to copy the running data in the running directory to the data directory corresponding to the target applet in response to detecting a user closing operation on the target applet.
In some embodiments, the establishing unit 501 of the applet running device 500 may establish a running directory and a data directory for the first hosted application. In this way, it is convenient to set the authority for the operation directory separately, so that the execution main body or the server cannot apply the operation data under the operation directory to the small program without the authority. The first hosted application may be any applet-integrated hosted application installed by the terminal device.
In some embodiments, the running unit 502 may start and run the target applet integrated with the first hosted application in response to detecting a user-initiated operation of the target applet by a user. And, the execution main body may store the operation data generated in the operation process in the operation directory.
In some embodiments, the copying unit 503 may copy the running data in the running directory to the data directory corresponding to the target applet in response to detecting a user closing operation of the target applet by the user. Specifically, the user closing operation is an operation of a user for instructing to close the target applet.
In some optional implementations of this embodiment, the keys of the data directories corresponding to the different applets integrated by the first host application are different.
In some optional implementations of the embodiment, the execution unit is further configured to execute the target applet in response to detecting a user-initiated operation on the target applet integrated with the first hosted application, as follows: in response to detecting user starting operation of a target applet integrated in a first host application, judging whether running data exists in a data directory corresponding to the target applet; if the target applet exists, decrypting and storing the existing running data in a running directory, and running the target applet based on the running data in the running directory; if not, the target applet is run.
In some optional implementations of this embodiment, the apparatus further includes: and the encryption unit is configured to encrypt the operation data of the current operation of the target applet under the data directory corresponding to the target applet.
In some optional implementations of this embodiment, the apparatus further includes: and the backup unit is configured to backup the operation data generated in the operation directory to the data directory corresponding to the target applet at regular time.
In some optional implementations of the embodiment, the copying unit is further configured to copy the running data in the running directory into the data directory corresponding to the target applet as follows: and copying the operation data added after the operation data is backed up at the last time in the operation directory to the data directory corresponding to the target applet.
In some optional implementations of this embodiment, the apparatus further includes: and the execution unit is configured to encrypt the running data which is backed up at regular time and the copied running data under the data directory corresponding to the target small program.
In some optional implementations of this embodiment, the apparatus further includes: and the clearing unit is configured to clear the data in the running directory.
In some optional implementations of the embodiment, the running data in the running directory is only used for executing the instruction corresponding to the running applet integrated in the first host application.
As shown in fig. 6, electronic device 600 may include a processing means (e.g., central processing unit, graphics processor, etc.) 601 that may perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)602 or a program loaded from a storage means 608 into a Random Access Memory (RAM) 603. In the RAM603, various programs and data necessary for the operation of the electronic apparatus 600 are also stored. The processing device 601, the ROM 602, and the RAM603 are connected to each other via a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
Generally, the following devices may be connected to the I/O interface 605: input devices 606 including, for example, a touch screen, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; output devices 607 including, for example, a Liquid Crystal Display (LCD), a speaker, a vibrator, and the like; a storage device 608; and a communication device 609. The communication means 609 may allow the electronic device 600 to communicate with other devices wirelessly or by wire to exchange data. While fig. 6 illustrates an electronic device 600 having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided. Each block shown in fig. 6 may represent one device or may represent multiple devices as desired.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication means 609, or may be installed from the storage means 608, or may be installed from the ROM 602. The computer program, when executed by the processing device 601, performs the above-described functions defined in the methods of embodiments of the present disclosure. It should be noted that the computer readable medium of the embodiments of the present disclosure may be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In embodiments of the disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In embodiments of the present disclosure, however, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present application may be implemented by software or hardware. The described units may also be provided in a processor, and may be described as: a processor includes a setup unit, an execution unit, and a copy unit. Where the names of these elements do not in some cases constitute a limitation on the elements themselves, for example, the creation element may also be described as a "element that creates a running directory and at least one data directory for the first hosted application".
As another aspect, the present application also provides a computer-readable medium, which may be contained in the apparatus described in the above embodiments; or may be present separately and not assembled into the device. The computer readable medium carries one or more programs which, when executed by the apparatus, cause the apparatus to: establishing an operation directory and at least one data directory for the first host application, wherein different data directories are used for storing data of different applets integrated by the first host application, the operation directory is used for storing operation data, and the operation data comprises user behavior data; in response to detecting a user start operation on a target applet integrated in the first host application, running the target applet, and storing running data generated in a running process in a running directory; and in response to the detected user closing operation on the target small program, copying the running data in the running catalog to the data catalog corresponding to the target small program.
The above description is only a preferred embodiment of the application and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the invention herein disclosed is not limited to the particular combination of features described above, but also encompasses other arrangements formed by any combination of the above features or their equivalents without departing from the spirit of the invention. For example, the above features may be replaced with (but not limited to) features having similar functions disclosed in the present application.

Claims (11)

1. An applet running method is applied to a terminal device, and the terminal device is provided with at least one host application comprising a first host application; the method comprises the following steps:
establishing an operation directory and at least one data directory for the first host application, wherein different data directories are used for storing data of different applets integrated by the first host application, the operation directory is used for storing operation data, and the operation data comprises user behavior data;
in response to detecting a user starting operation on a target applet integrated in the first host application, running the target applet, and storing running data generated in a running process in the running directory;
and in response to the detected user closing operation on the target small program, copying the running data in the running catalog to the data catalog corresponding to the target small program.
2. The method of claim 1, wherein,
and the keys of the data directories corresponding to the different applets integrated by the first host application are different.
3. The method of claim 1, wherein, in response to detecting a user-initiated operation on a target applet integrated with the first hosted application, executing the target applet comprises:
in response to detecting user starting operation of a target applet integrated in the first host application, judging whether running data exists in a data directory corresponding to the target applet;
if the target applet exists, decrypting the existing running data and storing the decrypted running data in the running directory, and running the target applet based on the running data in the running directory;
and if not, operating the target applet.
4. The method of claim 1, wherein after the copying the operating data in the operating directory into the data directory corresponding to the target applet, the method further comprises:
and encrypting the running data of the current running of the target small program under the data directory corresponding to the target small program.
5. The method of claim 1, wherein after said storing operational data generated during operation under said operational directory, said method further comprises:
and backing up the running data generated under the running catalog to a data catalog corresponding to the target applet at regular time.
6. The method of claim 5, wherein the copying the operating data in the operating directory to the data directory corresponding to the target applet comprises:
and copying the operation data added after the operation data is backed up at the last time in the operation directory to the data directory corresponding to the target applet.
7. The method of claim 6, wherein after the copying the operating data in the operating directory into the data directory corresponding to the target applet, the method further comprises:
and encrypting the regularly backed-up running data and the copied running data under the data directory corresponding to the target applet.
8. The method of any of claims 1-5, wherein after the copying the operating data in the operating directory into the data directory corresponding to the target applet, the method further comprises:
and clearing the data in the running directory.
9. The method of any of claims 1-5, wherein the run data under the run directory is only used to execute instructions corresponding to the applet that is integrated with the first hosted application and that is running.
10. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-9.
11. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the method according to any one of claims 1-9.
CN201910331999.0A 2019-04-24 2019-04-24 Applet running method and device Active CN110046000B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910331999.0A CN110046000B (en) 2019-04-24 2019-04-24 Applet running method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910331999.0A CN110046000B (en) 2019-04-24 2019-04-24 Applet running method and device

Publications (2)

Publication Number Publication Date
CN110046000A CN110046000A (en) 2019-07-23
CN110046000B true CN110046000B (en) 2022-03-11

Family

ID=67278913

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910331999.0A Active CN110046000B (en) 2019-04-24 2019-04-24 Applet running method and device

Country Status (1)

Country Link
CN (1) CN110046000B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110688124B (en) * 2019-08-23 2023-03-17 北京奇艺世纪科技有限公司 Applet processing method, apparatus, electronic device and computer readable storage medium
CN111338542B (en) * 2020-02-19 2021-08-17 北京字节跳动网络技术有限公司 Shortcut generation method and device and computer readable storage medium
CN112559980B (en) * 2020-11-24 2023-05-05 深圳凡泰极客科技有限责任公司 Applet runtime capable of embedding a plurality of random APP

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101853181A (en) * 2010-05-11 2010-10-06 中达电通股份有限公司 Subprogram mutual calling method used in embedded system
CN103473091A (en) * 2011-01-21 2013-12-25 北京奇虎科技有限公司 Method and system for software migration and installation for computing equipment
CN104063284A (en) * 2013-03-18 2014-09-24 腾讯科技(深圳)有限公司 Method and device operating application program
CN104965723A (en) * 2014-10-09 2015-10-07 腾讯科技(深圳)有限公司 Application program operation method and apparatus
CN107220528A (en) * 2017-07-21 2017-09-29 北京深思数盾科技股份有限公司 The protection of java applet and operation method, device and terminal
CN109542530A (en) * 2018-10-26 2019-03-29 深圳点猫科技有限公司 A kind of hierarchical loading method and device based on small routine framework

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101853181A (en) * 2010-05-11 2010-10-06 中达电通股份有限公司 Subprogram mutual calling method used in embedded system
CN103473091A (en) * 2011-01-21 2013-12-25 北京奇虎科技有限公司 Method and system for software migration and installation for computing equipment
CN104063284A (en) * 2013-03-18 2014-09-24 腾讯科技(深圳)有限公司 Method and device operating application program
CN104965723A (en) * 2014-10-09 2015-10-07 腾讯科技(深圳)有限公司 Application program operation method and apparatus
CN107220528A (en) * 2017-07-21 2017-09-29 北京深思数盾科技股份有限公司 The protection of java applet and operation method, device and terminal
CN109542530A (en) * 2018-10-26 2019-03-29 深圳点猫科技有限公司 A kind of hierarchical loading method and device based on small routine framework

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
小程序.小故事(19)——文件系统能力;微信开发者;《小程序.小故事(19)——文件系统能力,https://www.qianyxcx.com/article/36.html》;20180818;第1-6页 *

Also Published As

Publication number Publication date
CN110046000A (en) 2019-07-23

Similar Documents

Publication Publication Date Title
JP6795684B2 (en) Malware detection and content item restoration
CN106612285B (en) Distributed cloud data management method and system based on peer-to-peer network
US10650077B2 (en) Providing secure storage of content and controlling content usage by social media applications
CN110046000B (en) Applet running method and device
CN111258602B (en) Information updating method and device
WO2020216204A1 (en) Information acquisition method and apparatus
CN109154968B (en) System and method for secure and efficient communication within an organization
WO2020220536A1 (en) Data backup method and device, and computer readable storage medium
US10346618B1 (en) Data encryption for virtual workspaces
CN110007936B (en) Data processing method and device
Tso et al. iPhone social networking for evidence investigations using iTunes forensics
CN109814889B (en) Method and apparatus for updating source code base
CN110058902B (en) Information processing method, electronic device, and computer-readable medium
AU2014203538A1 (en) Method and system for digital rights enforcement
CN113656713B (en) Network resource processing method, device and system
CN112700014B (en) Method, device, system and electronic equipment for deploying federal learning application
US10462113B1 (en) Systems and methods for securing push authentications
CN104639973A (en) Information pushing method and device
US9887979B1 (en) Systems and methods for enabling users to launch applications without entering authentication credentials
JP6272546B2 (en) Data storage device, data processing method, and data processing program
CN111818179A (en) User request processing method and device, computing equipment and medium
CN111181905A (en) File encryption method and device
CN111309698A (en) Disk redirection method, device and system
CN110708238A (en) Method and apparatus for processing information
CN107463808B (en) Method for calling functional module integrated in operating system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant