CN111857854A - Shutdown resource loading method and device, storage medium and electronic equipment - Google Patents

Shutdown resource loading method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN111857854A
CN111857854A CN202010774774.5A CN202010774774A CN111857854A CN 111857854 A CN111857854 A CN 111857854A CN 202010774774 A CN202010774774 A CN 202010774774A CN 111857854 A CN111857854 A CN 111857854A
Authority
CN
China
Prior art keywords
shutdown
partition
android system
resource
resources
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010774774.5A
Other languages
Chinese (zh)
Inventor
黎欠根
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Wingtech Communication Co Ltd
Original Assignee
Wingtech Communication 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 Wingtech Communication Co Ltd filed Critical Wingtech Communication Co Ltd
Priority to CN202010774774.5A priority Critical patent/CN111857854A/en
Publication of CN111857854A publication Critical patent/CN111857854A/en
Pending legal-status Critical Current

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/4401Bootstrapping
    • G06F9/442Shutdown

Abstract

The embodiment of the application provides a shutdown resource loading method and device, a storage medium and electronic equipment, and relates to the field of data loading. The method comprises the following steps: responding to the trigger request, and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state; when the android system is a slot partition system, polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources; when the android system is not a slot partition system, accessing a default partition in the android system according to a preset reference path to acquire shutdown resources; and loading shutdown resources. No matter the android system is a slot partition system or a traditional system, the shutdown charging animation can be correctly and successfully loaded, stable operation of electronic equipment is guaranteed, development and debugging time of developers is shortened, and working efficiency is improved.

Description

Shutdown resource loading method and device, storage medium and electronic equipment
Technical Field
The present application relates to the field of data loading, and in particular, to a method and an apparatus for loading shutdown resources, a storage medium, and an electronic device.
Background
With the development of science and technology, electronic devices such as smart phones and tablet computers have become one of the essential tools for people to perform social activities. However, in these electronic devices, an operating system (e.g., an android system) needs to be installed to operate normally.
Currently, when an electronic device is powered off and charged, a power-off charging animation is loaded in a default partition. With the change of the android system, the development efficiency of developers is low, and even the shutdown charging animation is not displayed.
Disclosure of Invention
The application aims to provide a shutdown resource loading method, a shutdown resource loading device, a storage medium and electronic equipment, which can correctly and successfully load shutdown charging animations, shorten development and debugging time of developers and improve working efficiency.
The embodiment of the application can be realized as follows:
in a first aspect, an embodiment of the present application provides a shutdown resource loading method, which is applied to an electronic device equipped with an android system, and the method includes: responding to a trigger request, and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state; when the android system is the slot partition system, polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources; when the android system is not the slot partition system, accessing a default partition in the android system according to a preset reference path to acquire shutdown resources; and loading the shutdown resources.
In an alternative embodiment, the android system includes a plurality of partitions; the step of polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources comprises: acquiring any one target partition from the plurality of partitions; accessing the target partition according to the reference path; determining whether shutdown resources exist in the target partition according to the access result; when shutdown resources exist in the target partition, the shutdown resources are acquired; and when the shutdown resources do not exist in the target partition, repeating the steps until the shutdown resources are obtained.
In an optional embodiment, the step of polling and accessing each partition in the android system according to a preset reference path to obtain a shutdown resource further includes: and when the access to the plurality of partitions is finished and the shutdown resource is not acquired, accessing a default partition according to the preset reference path to acquire the shutdown resource.
In an optional embodiment, the shutdown resource includes an animation resource, a picture resource, and an interactive program.
In an optional embodiment, a storage medium of the electronic device is preset with a plurality of interactive programs, and the method further includes: acquiring gesture operation of a user on a display of the electronic equipment; determining a target interactive program in the plurality of interactive programs as the shutdown resource according to the gesture operation; and loading and running the target interactive program.
In a second aspect, an embodiment of the present application provides a shutdown resource loading apparatus, which is applied to an electronic device equipped with an android system, where the apparatus includes: the judging module is used for responding to the trigger request and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state; the loading module is used for polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources when the android system is the slot partition system; the loading module is further configured to, when the android system is not the slot partition system, access a default partition in the android system according to a preset reference path to acquire a shutdown resource; the loading module is further configured to load the shutdown resource.
In an alternative embodiment, the android system includes a plurality of partitions; the loading module is used for acquiring any one target partition from the plurality of partitions; the loading module is further used for accessing the target partition according to the reference path; the loading module is further used for determining whether shutdown resources exist in the target partition according to the access result; the loading module is further configured to acquire a shutdown resource when the shutdown resource exists in the target partition; the loading module is further configured to, when the shutdown resource does not exist in the target partition, repeatedly execute the above steps until the shutdown resource is acquired.
In an optional embodiment, the loading module is further configured to, when the access to the multiple partitions is completed and the shutdown resource is not acquired, access a default partition according to the preset reference path to acquire the shutdown resource.
In an optional embodiment, the shutdown resource includes an animation resource, a picture resource, and an interactive program.
In an optional implementation manner, a storage medium of the electronic device is preset with a plurality of interactive programs, and the loading module is further configured to obtain a gesture operation of a user on a display of the electronic device; the loading module is further configured to determine a target interactive program in the plurality of interactive programs as the shutdown resource according to the gesture operation; the loading module is also used for loading and running the target interactive program.
In a third aspect, the present application provides a computer-readable storage medium, on which a computer program is stored, and the computer program, when executed by a processor, implements the method of any one of the foregoing embodiments.
In a fourth aspect, an embodiment of the present application provides an electronic device, which includes a processor and a memory, where the memory stores a computer program, and the processor is configured to execute the computer program to implement the method described in any one of the foregoing embodiments.
For the embodiment of the application, when the android system of the electronic device is a slot partition system, each partition in the android system can be polled and accessed according to a preset reference path to acquire shutdown resources; when the android system of the electronic device is not a slot partition system, a default partition in the android system can be accessed according to a preset reference path to acquire shutdown resources. Therefore, the beneficial effects of the embodiment of the application include: no matter the android system is a slot partition system or a traditional system, the shutdown resources can be correctly and successfully loaded, development and debugging time of developers is further shortened, and working efficiency is improved. Obviously, the embodiment of the application can correctly and successfully load the shutdown charging animation, ensure the stable operation of the electronic equipment, shorten the development and debugging time of a developer and improve the working efficiency.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are required to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained from the drawings without inventive effort.
Fig. 1 is a block diagram of an electronic device according to an embodiment of the present disclosure;
fig. 2 is a flowchart of a shutdown resource loading method according to an embodiment of the present application;
fig. 3 is another flowchart of a shutdown resource loading method according to an embodiment of the present application;
fig. 4 is another flowchart of a shutdown resource loading method according to an embodiment of the present application;
fig. 5 is a functional block diagram of a shutdown resource loading apparatus according to an embodiment of the present disclosure.
Icon: 100-an electronic device; 110-a memory; 120-a processor; 130-a bus; 140-a communication interface; 300-shutdown resource loading means; 310-a judgment module; 320-load module.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
It should be noted that the features of the embodiments of the present application may be combined with each other without conflict.
In the implementation process of the embodiment of the present application, the inventors of the present application find that:
with the development of the android system, a new partition mode appears in the android system. At present, the partition mode of the android system mainly includes two types: slot partition systems (e.g., slot A/B systems) and legacy partition systems. When the android system is a slot partition system, the electronic device on which the android system is installed may also be referred to as an a/B device.
When the android system is a traditional partition system, developers usually implement the function of loading shutdown and charging animations in a default partition when developing the function of loading shutdown and charging animations when electronic equipment is shut down for charging.
When the android system is a slot partition system, developers have to reset a loading path for loading shutdown charging animation when developing a function of loading shutdown charging animation when the electronic device is shut down for charging, and the function is realized by loading the shutdown charging animation in the newly set loading path. This method may result in low development efficiency of the developer, increase development workload, and even cause a problem that the shutdown charging animation is not displayed due to a wrong setting of the loading path.
In order to overcome the above drawbacks of the prior art, embodiments of the present application provide a shutdown resource loading method, apparatus, storage medium, and electronic device, which can correctly and successfully load a shutdown charging animation, shorten development and debugging time of a developer, and improve work efficiency.
It should be noted that all the defects of the above prior art solutions are the results of the careful practical study by the inventors, and therefore, the discovery process of the above problems and the solutions proposed by the following embodiments of the present application to the above problems should be the contribution of the inventors to the realization of the present application.
Referring to fig. 1, a block diagram of an electronic device 100 according to an embodiment of the present disclosure is shown. The electronic device 100 may be a smartphone, a tablet computer, a wearable smart device, and the like, which are equipped with an android system, and this application does not limit this.
The electronic device 100 may include a memory 110, a processor 120, a bus 130, and a communication interface 140, the memory 110, the processor 120, and the communication interface 140 being electrically connected to each other, directly or indirectly, to enable transmission or interaction of data. For example, the components may be electrically connected to each other via one or more buses 130 or signal lines. Processor 120 may process information and/or data related to the loading of shutdown resources to perform one or more of the functions described herein. For example, processor 120 may determine, in response to a trigger request, whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state, and shutdown resource loading is carried out according to the judgment, so that the shutdown resource loading method provided by the application is realized.
The Memory 110 may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like.
The processor 120 may be an integrated circuit chip having signal processing capabilities. The processor 120 may be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components.
It will be appreciated that the configuration shown in FIG. 1 is merely illustrative and that the electronic device 100 may include more or fewer components than shown in FIG. 1 or may have a different configuration than shown in FIG. 1. The components shown in fig. 1 may be implemented in hardware, software, or a combination thereof.
For convenience of understanding, in the following embodiments of the present application, an electronic device 100 shown in fig. 1 is taken as an example, and a shutdown resource loading method provided in the embodiments of the present application is explained with reference to the drawings.
Referring to fig. 2, fig. 2 is a flowchart illustrating a shutdown resource loading method according to an embodiment of the present disclosure. The shutdown resource loading method may be applied to the electronic device 100 with the android system installed, and the shutdown resource loading method may include the following steps:
and S200, responding to the trigger request, and judging whether the android system is a slot partition system.
The triggering request represents that the electronic equipment enters a shutdown charging state. For example, the trigger request may be a trigger request sent to the android system by a monitoring program in the android system when it is monitored that the electronic device enters a shutdown charging state.
It is to be understood that when the memory partition of electronic device 100 is partitioned into Slot a and Slot B (i.e., a/B partitions), then the android system is a Slot partition system.
In some possible embodiments, whether the android system is a slot partition system may be determined by system self-contained information of the android system, for example, by querying whether the storage medium of electronic device 100 has an a partition and a B partition, and when the storage medium of electronic device 100 has the a partition and the B partition, determining that the android system of electronic device 100 is the slot partition system.
And S210, when the android system is a slot partition system, polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources.
When the android system is a slot partition system, multiple system partitions are typically included in the android system, and the shutdown resource may be stored in one of the multiple system partitions. Therefore, in some possible embodiments, the shutdown resource stored in a certain partition of the multiple system partitions may be acquired by polling to access each partition in the android system according to a preset reference path.
For example, assume that a "boot partition," "system partition," "recovery partition," and "cache partition" are included in the android system. The preset reference path is as follows: the "boot partition" - "cache partition" - "system partition" - "recovery partition", then the electronic device 100 polls the access sequence for accessing each partition in the android system, first accesses the "boot partition", then accesses the "cache partition", then accesses the "system partition", and finally accesses the "recovery partition", so as to obtain the shutdown resources from the partitions.
The preset reference path may be data that is pre-stored in a storage medium of the electronic device and is used for indicating a storage location of the shutdown resource in the partition.
And S220, when the android system is not the slot partition system, accessing a default partition in the android system according to a preset reference path to acquire shutdown resources.
When the android system is not a slot partition system, the shutdown resource is stored in a default partition in the android system. And accessing a default partition in the android system according to a preset reference path to obtain the shutdown resource.
For example, assuming that the path of the default partition in the android system is "/recovery" and the preset reference path is "/data/graphics", the "/recovery/data/graphics" path may be used to access the default partition in the android system to obtain the shutdown resource.
And S230, loading shutdown resources.
After the shutdown resources are acquired, the shutdown resources can be correctly and successfully loaded.
Compared with the prior art, by applying the method provided by the embodiment of the application, developers can acquire the shutdown charging animation without considering the specific partition mode of the android system and in which partition, and can complete the development of the function of loading the shutdown charging animation when the electronic equipment is shut down for charging. Therefore, the method and the device can correctly and successfully load the shutdown resources, further shorten the development and debugging time of developers and improve the working efficiency.
Optionally, the shutdown resource may include: animation resources, picture resources, interactive programs and the like.
When the electronic device is powered off for charging, the electronic device cannot normally operate within a period of time, and a user cannot perform any operation on the electronic device. Therefore, in order to alleviate the anxiety of the user caused by the inability to operate the electronic device during this period of time, it is also necessary to ensure that the user can work effectively. When the shutdown resource is preferably an interactive program, and after the interactive program is loaded, a user of the electronic device can relieve anxiety through the interactive program or effectively work.
In some possible embodiments, a storage medium of the electronic device may have a plurality of interactive programs preset therein, and the method provided by the present application may further include: acquiring gesture operation of a user on a display of the electronic equipment; determining a target interactive program in the plurality of interactive programs as a shutdown resource according to the gesture operation; and loading and running the target interactive program.
The electronic device 100 may load a target interactive program in a plurality of interactive programs when the target interactive program is determined as a shutdown resource according to a gesture operation and the shutdown resource is acquired during shutdown and charging.
It should be understood that the above method may enable the user to operate the electronic device 100 before powering off and charging the electronic device 100, select a power-off resource on the electronic device 100, and set a favorite interactive program as the power-off resource. Further, when the electronic device 100 performs shutdown charging, the electronic device 100 ensures that the user can relieve anxiety through the interactive program or perform effective office work by loading the interactive program selected by the user as a shutdown resource.
For example, to relieve the user from anxiety, the above-mentioned interactive program may be: a mini-game program, a reader program, etc. The electronic equipment can operate the programs when shutdown charging is carried out, so that the anxiety mood of a user in the process of waiting for charging the equipment is relieved, and the fun is brought to the user.
For example, to enable the user to work effectively, the interactive program may also be: a notepad program, a drawing program, etc. The electronic equipment can run the programs when shutdown charging is carried out, and therefore a user can effectively work in the process of waiting for charging of the equipment.
In addition, obviously, the embodiment of the application can also correctly and successfully load the shutdown charging animation, shorten the development and debugging time of a developer, and improve the working efficiency.
It should be understood that, for the embodiment of the present application, when the android system of the electronic device is a slot partition system, each partition in the android system may be polled and accessed according to a preset reference path to obtain a shutdown resource; when the android system of the electronic device is not a slot partition system, a default partition in the android system can be accessed according to a preset reference path to acquire shutdown resources. Therefore, the beneficial effects of the embodiment of the application include: no matter the android system is a slot partition system or a traditional system, the shutdown resources can be correctly and successfully loaded, development and debugging time of developers is further shortened, and working efficiency is improved.
Further, when the android system is a slot partition system, the android system may include multiple partitions. In order to ensure that the shutdown resource can be correctly and successfully loaded in the embodiment of the present application, on the basis of fig. 2, the embodiment of the present application further provides a feasible real-time manner, please refer to fig. 3, and S210 may include the following sub-steps:
S210A, any one of the target partitions is acquired from the plurality of partitions.
And S210B, accessing the target partition according to the reference path.
For example, assuming that the target partition has a path of "/system" and the reference path is "/data/graphics", the target partition may be accessed using the "/system/data/graphics" path.
S210C, determining whether shutdown resources exist in the target partition according to the access result; when the shutdown resource exists in the target partition, executing S210D; when the shutdown resource does not exist in the target partition, the steps are repeatedly executed (returning to the step S210A) until the shutdown resource is acquired.
For example, assuming that the path of the target partition is "/system", and the reference path is "/data/graphics", when the target partition is accessed using the "/system/data/graphics" path, when there is no data in the path, it is determined that there is no shutdown resource in the target partition; otherwise, determining that the shutdown resources exist in the target partition.
S210D, when the shutdown resource exists in the target partition, acquiring the shutdown resource.
It should be understood that by executing the above-mentioned S210A-S210D, polling access can be performed on multiple partitions in the android system, and each partition is traversed until a shutdown resource is found, so that the shutdown resource can be correctly and successfully loaded in the embodiment of the present application.
It is also understood that, for the above S210A-S210D, in practical application, it is also possible to: and sequentially accessing each partition in the plurality of partitions according to a preset sequence and a reference path until the shutdown resource is found. The preset order is an ordering of the plurality of partitions, and the ordering may be determined by a probability value that the shutdown resource is stored in the partition. That is, the higher the probability value of the shutdown resource stored in the partition, the earlier the partition is ranked in the preset order, and the probability value may be determined by the storage condition of the shutdown resource in the existing android systems.
It can be understood that, since the partitions in the preset sequence are ranked more ahead, the probability value of shutdown resources stored in the partitions is higher, and obviously, the method can improve the searching efficiency and further improve the loading efficiency.
In some possible embodiments, when the foregoing S210A-S210D is executed, a "when access to multiple partitions is completed and shutdown resources are not acquired" may also occur, so to ensure that the embodiment of the present application can load shutdown resources without error and successfully, on the basis of fig. 3, this application further provides a possible implementation manner, please refer to fig. 4, and S210 may further include the following sub-steps:
and S210E, when the access to the plurality of partitions is completed and the shutdown resource is not acquired, accessing the default partition according to a preset reference path to acquire the shutdown resource.
In order to execute corresponding steps in the foregoing embodiments and various possible manners, an implementation manner of the shutdown resource loading apparatus is provided below, please refer to fig. 5, and fig. 5 shows a functional block diagram of the shutdown resource loading apparatus provided in the embodiment of the present application. It should be noted that the basic principle and the generated technical effect of the shutdown resource loading apparatus 300 provided in the present embodiment are the same as those of the foregoing embodiments, and for a brief description, no part of the present embodiment is mentioned, and corresponding contents in the foregoing embodiments may be referred to. The shutdown resource loading apparatus 300 may include: a judging module 310 and a loading module 320.
Alternatively, the modules may be stored in a memory in the form of software or Firmware (Firmware) or be fixed in an Operating System (OS) of the electronic device 100 provided in the present application, and may be executed by a processor in the electronic device 100. Meanwhile, data, codes of programs, and the like required to execute the above modules may be stored in the memory.
The determining module 310 may be configured to respond to a trigger request, and determine whether the android system is a slot partition system; the trigger request characterizes that the electronic device enters a shutdown charging state.
It is to be appreciated that the determination module 310 can be utilized to enable the electronic device 100 to perform the above-described S200, and/or the like, and/or other processes for the techniques described herein.
The loading module 320 may be configured to, when the android system is the slot partition system, poll and access each partition in the android system according to a preset reference path to obtain a shutdown resource.
It is to be appreciated that the load module 320 can be utilized to support the electronic device 100 in performing S210, and/or the like, described above, and/or other processes for the techniques described herein, e.g., S210A-S210E.
Further, when the android system is a slot partition system, the android system may include multiple partitions. In order to ensure that the embodiment of the present application can correctly and successfully load the shutdown resources, the embodiment of the present application further provides a feasible real-time manner; the loading module 320 may be configured to obtain any one target partition from the plurality of partitions; accessing the target partition according to the reference path; determining whether shutdown resources exist in the target partition according to the access result; when shutdown resources exist in the target partition, the shutdown resources are acquired; when the shutdown resources do not exist in the target partition, the steps are repeatedly executed until the shutdown resources are obtained; and when the access to the plurality of partitions is finished and the shutdown resources are not acquired, accessing the default partition according to a preset reference path to acquire the shutdown resources.
It will be appreciated that the load module 320 may be used to support the electronic device 100 in performing the above-described S210A-S210E, etc., and/or other processes for the techniques described herein.
The loading module 320 may be configured to, when the android system is not the slot partition system, access a default partition in the android system according to a preset reference path to obtain a shutdown resource.
It will be appreciated that the loading module 320 may be used to support the electronic device 100 in performing the above-described S220, and/or the like, and/or other processes for the techniques described herein.
The loading module 320 may be configured to load the shutdown resource.
It will be appreciated that the loading module 320 may be used to support the electronic device 100 in performing the above-described S230, etc., and/or other processes for the techniques described herein.
Based on the foregoing method embodiment, an embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the step of executing the shutdown resource loading method is performed.
Specifically, the storage medium may be a general storage medium, such as a mobile disk, a hard disk, or the like, and when a computer program on the storage medium is executed, the shutdown resource loading method may be executed, so as to solve the problem that "loading shutdown charging animation in a default partition at present may cause low development efficiency of a developer, and even cause no display of the shutdown charging animation", and achieve the purposes of correctly and successfully loading the shutdown charging animation, shortening development and debugging time of the developer, and improving work efficiency.
In one embodiment, a computer-readable storage medium is provided, having a computer program stored thereon, which when executed by a processor, performs the steps of: responding to the trigger request, and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state; when the android system is a slot partition system, polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources; when the android system is not a slot partition system, accessing a default partition in the android system according to a preset reference path to acquire shutdown resources; and loading shutdown resources. .
In one embodiment, the android system includes a plurality of partitions, and the computer program when executed by the processor further implements the steps of: acquiring any one target partition from a plurality of partitions; accessing the target partition according to the reference path; determining whether shutdown resources exist in the target partition according to the access result; when shutdown resources exist in the target partition, the shutdown resources are acquired; and when the shutdown resources do not exist in the target partition, the steps are repeatedly executed until the shutdown resources are obtained.
In one embodiment, the computer program when executed by the processor further performs the steps of: and when the access to the plurality of partitions is finished and the shutdown resources are not acquired, accessing the default partition according to a preset reference path to acquire the shutdown resources.
In one embodiment, the shutdown resources include animation resources, picture resources, and interactive programs.
It should be understood that, for the embodiment of the present application, when the android system of the electronic device is a slot partition system, each partition in the android system may be polled and accessed according to a preset reference path to obtain a shutdown resource; when the android system of the electronic device is not a slot partition system, a default partition in the android system can be accessed according to a preset reference path to acquire shutdown resources. Therefore, the beneficial effects of the embodiment of the application include: no matter the android system is a slot partition system or a traditional system, the shutdown resources can be correctly and successfully loaded, development and debugging time of developers is further shortened, and working efficiency is improved. Obviously, the embodiment of the application can correctly and successfully load the shutdown charging animation, ensure the stable operation of the electronic equipment, shorten the development and debugging time of a developer and improve the working efficiency.
In one embodiment, there is provided an electronic device for installing an android system, comprising a memory storing a computer program and a processor implementing the following steps when the processor executes the computer program: responding to the trigger request, and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state; when the android system is a slot partition system, polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources; when the android system is not a slot partition system, accessing a default partition in the android system according to a preset reference path to acquire shutdown resources; and loading shutdown resources.
In an alternative embodiment, the android system includes a plurality of partitions, and the processor, when executing the computer program, further implements the following steps: acquiring any one target partition from a plurality of partitions; accessing the target partition according to the reference path; determining whether shutdown resources exist in the target partition according to the access result; when shutdown resources exist in the target partition, the shutdown resources are acquired; and when the shutdown resources do not exist in the target partition, the steps are repeatedly executed until the shutdown resources are obtained.
In an alternative embodiment, the processor, when executing the computer program, further performs the steps of: and when the access to the plurality of partitions is finished and the shutdown resources are not acquired, accessing the default partition according to a preset reference path to acquire the shutdown resources.
In an alternative embodiment, the shutdown resource includes an animation resource, a picture resource, and an interactive program.
It should be understood that, for the embodiment of the present application, when the android system of the electronic device is a slot partition system, each partition in the android system may be polled and accessed according to a preset reference path to obtain a shutdown resource; when the android system of the electronic device is not a slot partition system, a default partition in the android system can be accessed according to a preset reference path to acquire shutdown resources. Therefore, the beneficial effects of the embodiment of the application include: no matter the android system is a slot partition system or a traditional system, the shutdown resources can be correctly and successfully loaded, development and debugging time of developers is further shortened, and working efficiency is improved. Obviously, the embodiment of the application can correctly and successfully load the shutdown charging animation, ensure the stable operation of the electronic equipment, shorten the development and debugging time of a developer and improve the working efficiency.
To sum up, the embodiment of the present application provides a shutdown resource loading method, apparatus, storage medium and electronic device, where the method includes: responding to the trigger request, and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state; when the android system is a slot partition system, polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources; when the android system is not a slot partition system, accessing a default partition in the android system according to a preset reference path to acquire shutdown resources; and loading shutdown resources. For the embodiment of the application, when the android system of the electronic device is a slot partition system, each partition in the android system can be polled and accessed according to a preset reference path to acquire shutdown resources; when the android system of the electronic device is not a slot partition system, a default partition in the android system can be accessed according to a preset reference path to acquire shutdown resources. Therefore, the beneficial effects of the embodiment of the application include: no matter the android system is a slot partition system or a traditional system, the shutdown resources can be correctly and successfully loaded, development and debugging time of developers is further shortened, and working efficiency is improved. Obviously, the embodiment of the application can also correctly and successfully load the shutdown charging animation, shorten the development and debugging time of a developer, and improve the working efficiency.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method can be implemented in other ways. The apparatus embodiments described above are merely illustrative, and for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, 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.
In addition, functional modules in the embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present application should be covered within the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (10)

1. A shutdown resource loading method is applied to electronic equipment for installing an android system, and comprises the following steps:
responding to a trigger request, and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state;
when the android system is the slot partition system, polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources;
when the android system is not the slot partition system, accessing a default partition in the android system according to a preset reference path to acquire shutdown resources;
and loading the shutdown resources.
2. The method of claim 1, wherein the android system comprises a plurality of partitions; the step of polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources comprises:
acquiring any one target partition from the plurality of partitions;
accessing the target partition according to the reference path;
determining whether shutdown resources exist in the target partition according to the access result;
when shutdown resources exist in the target partition, the shutdown resources are acquired;
and when the shutdown resources do not exist in the target partition, repeating the steps until the shutdown resources are obtained.
3. The method according to claim 2, wherein the step of polling access to each partition in the android system according to a preset reference path to obtain shutdown resources further comprises:
and when the access to the plurality of partitions is finished and the shutdown resource is not acquired, accessing a default partition according to the preset reference path to acquire the shutdown resource.
4. The method of claim 1, wherein the shutdown resources comprise animation resources, picture resources, and interactive programs.
5. The method of claim 4, wherein a storage medium of the electronic device is pre-loaded with a plurality of interactive programs, and the method further comprises:
acquiring gesture operation of a user on a display of the electronic equipment;
determining a target interactive program in the plurality of interactive programs as the shutdown resource according to the gesture operation;
and loading and running the target interactive program.
6. The shutdown resource loading device is applied to electronic equipment for installing an android system, and comprises the following components:
the judging module is used for responding to the trigger request and judging whether the android system is a slot partition system; the triggering request represents that the electronic equipment enters a shutdown charging state;
the loading module is used for polling and accessing each partition in the android system according to a preset reference path to acquire shutdown resources when the android system is the slot partition system;
the loading module is further configured to, when the android system is not the slot partition system, access a default partition in the android system according to a preset reference path to acquire a shutdown resource;
the loading module is further configured to load the shutdown resource.
7. The apparatus of claim 6, wherein the android system comprises a plurality of partitions;
the loading module is used for acquiring any one target partition from the plurality of partitions;
the loading module is further used for accessing the target partition according to the reference path;
the loading module is further used for determining whether shutdown resources exist in the target partition according to the access result;
the loading module is further configured to acquire a shutdown resource when the shutdown resource exists in the target partition;
the loading module is further configured to, when the shutdown resource does not exist in the target partition, repeatedly execute the above steps until the shutdown resource is acquired.
8. The apparatus according to claim 7, wherein the loading module is further configured to, when the access to the plurality of partitions is completed and the shutdown resource is not acquired, access a default partition according to the preset reference path to acquire the shutdown resource.
9. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the method of any one of claims 1 to 5.
10. An electronic device, comprising a processor and a memory, the memory storing a computer program, the processor being configured to execute the computer program to implement the method of any of claims 1 to 5.
CN202010774774.5A 2020-08-04 2020-08-04 Shutdown resource loading method and device, storage medium and electronic equipment Pending CN111857854A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010774774.5A CN111857854A (en) 2020-08-04 2020-08-04 Shutdown resource loading method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010774774.5A CN111857854A (en) 2020-08-04 2020-08-04 Shutdown resource loading method and device, storage medium and electronic equipment

Publications (1)

Publication Number Publication Date
CN111857854A true CN111857854A (en) 2020-10-30

Family

ID=72953629

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010774774.5A Pending CN111857854A (en) 2020-08-04 2020-08-04 Shutdown resource loading method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN111857854A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112232793A (en) * 2020-11-04 2021-01-15 腾讯科技(深圳)有限公司 Electronic resource distribution method, device, storage medium and equipment
CN113900673A (en) * 2021-06-15 2022-01-07 荣耀终端有限公司 System installation package management method, device, storage medium and program product

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112232793A (en) * 2020-11-04 2021-01-15 腾讯科技(深圳)有限公司 Electronic resource distribution method, device, storage medium and equipment
CN112232793B (en) * 2020-11-04 2023-09-19 腾讯科技(深圳)有限公司 Electronic resource distribution method, device, storage medium and equipment
CN113900673A (en) * 2021-06-15 2022-01-07 荣耀终端有限公司 System installation package management method, device, storage medium and program product

Similar Documents

Publication Publication Date Title
US11126328B2 (en) Application processing method and apparatus, storage medium, and computing device
US10613970B1 (en) Method and system for managing deployment of software application components based on software performance data
US9558016B2 (en) Platform system, method for changing support hardware configuration of universal extensible firmware interface basic input output system and computer program product
WO2017166447A1 (en) Method and device for loading kernel module
US9544399B2 (en) Visually depicting cloud resource utilization during execution of an application
CN109901881B (en) Plug-in loading method and device of application program, computer equipment and storage medium
CN104737134A (en) System and method for operating system agnostic hardware validation
CN111857854A (en) Shutdown resource loading method and device, storage medium and electronic equipment
CN110781067A (en) Method, device, equipment and storage medium for calculating starting time consumption
CN109375956B (en) Method for restarting operating system, logic device and control device
CN112817831A (en) Application performance monitoring method, device, computer system and readable storage medium
CN115114071A (en) Memory analysis method, device, equipment and medium
CN113191114A (en) Method and apparatus for authenticating a system
CN111045789B (en) Virtual machine starting method and device, electronic equipment and storage medium
CN115656788B (en) Chip testing system, method, equipment and storage medium
JP2015501046A (en) Method and apparatus for saving state prior to reset for evaluation after reset
CN108121572B (en) Web application starting method and device
CN110321179B (en) Application program starting method, system, device and computer storage medium
CN113972989B (en) Data verification method, storage medium and electronic equipment
CN106547583B (en) Operating system installation method and device
CN114647411A (en) Programming interface loading method and device, electronic equipment and storage medium
CN112181853A (en) Program debugging method, device and system
CN112784276B (en) Method and device for realizing trusted measurement
CN106708705B (en) Terminal background process monitoring method and system
CN112673354B (en) System state detection method, system state device and terminal equipment

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