CN111753235A - Page loading method and device and storage medium - Google Patents
Page loading method and device and storage medium Download PDFInfo
- Publication number
- CN111753235A CN111753235A CN202010597766.8A CN202010597766A CN111753235A CN 111753235 A CN111753235 A CN 111753235A CN 202010597766 A CN202010597766 A CN 202010597766A CN 111753235 A CN111753235 A CN 111753235A
- Authority
- CN
- China
- Prior art keywords
- loading
- loading request
- request
- current
- target page
- 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.)
- Granted
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/957—Browsing optimisation, e.g. caching or content distillation
- G06F16/9574—Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching
Landscapes
- Engineering & Computer Science (AREA)
- Databases & Information Systems (AREA)
- Theoretical Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The disclosure relates to a page loading method, a device and a medium, wherein the method comprises the steps of obtaining a loading request in a current loading request queue when receiving a loading request of a target page; processing the loading request in the current loading request queue according to a first preset rule; and executing the loading request of the target page. In the page loading method provided by the disclosure, in order to make the loading of the target page be processed preferentially, all the loading requests in the current loading request queue are obtained and processed according to the first preset rule, and then the loading request of the target page required by a user can be executed preferentially, so that the loading efficiency is improved, and the user experience is improved.
Description
Technical Field
The present disclosure relates to the field of page processing, and in particular, to a page loading method, device and storage medium.
Background
In the related art, web page loading speed is one of the issues that are getting more and more concerned. Preloading techniques are used in the prior art. The preloading is to load the required resource extraction request to the local, so that the request is not required to be carried out when the resource extraction request needs to be used, and the resource extraction request can be directly obtained from the cache, and the efficiency of the information flow service is improved by the method. However, the preloading is done in order of load requests. When the network environment is poor, the disadvantages of sequentially completing the loading requests in the loading queue according to the loading sequence are particularly obvious, and the user experience is poor. The method for conveniently loading the page is an urgent technical problem to be solved.
Disclosure of Invention
To overcome the problems in the related art, the present disclosure provides a page loading method, device and storage medium.
According to a first aspect of the embodiments of the present disclosure, a method for page loading is provided, which includes:
when a loading request of a target page is received, acquiring the loading request in a current loading request queue;
processing the loading request in the current loading request queue according to a first preset rule;
and executing the loading request of the target page.
Wherein, the processing the load request in the current load request queue according to a first preset rule includes:
determining whether the current loading request queue has a loading request of the target page;
if so, suspending other loading requests except the loading request of the target page in the current loading request queue, and processing the content loaded by other loading requests except the loading request of the target page in the current loading request queue according to a second preset rule;
if not, suspending all the loading requests in the current loading request queue, and processing the content loaded by all the loading requests in the current loading request queue according to a second preset rule.
Wherein the second preset rule comprises one of the following rules:
rule one is as follows: emptying the contents loaded by other loading requests except the loading request of the target page in the current loading request queue or emptying the contents loaded by all the loading requests in the current loading request queue;
rule two: determining the loading requests with loading contents exceeding a first preset threshold value in the current loading request queue, caching the contents loaded by other loading requests except the loading request of the target page in the determined loading requests with the loading contents exceeding the first preset threshold value or caching the contents loaded by all the loading requests with the loading contents exceeding the first preset threshold value.
Wherein, the processing the load request in the current load request queue according to a first preset rule includes:
determining whether the current loading request queue has a loading request of the target page;
if yes, determining that the loading content in the current loading request queue exceeds a second preset threshold and the loading priority level of the loading request is higher than that of the target page, and continuing to execute the determined loading request;
and if not, determining the loading request with the loading content exceeding a second preset threshold value in the current loading request queue, and continuing to execute the determined loading request.
Wherein the method further comprises:
and after the loading of the target page is finished, resuming the execution of the loading request in the current loading request queue.
According to a second aspect of the embodiments of the present disclosure, there is provided an apparatus for page loading, the apparatus including:
the acquisition module is configured to acquire a loading request in a current loading request queue when receiving the loading request of a target page;
the processing module is configured to process the loading requests in the current loading request queue according to a first preset rule;
an execution module configured to execute the load request of the target page.
Wherein the processing module is configured to:
determining whether the current loading request queue has a loading request of the target page;
if so, suspending other loading requests except the loading request of the target page in the current loading request queue, and processing the content loaded by other loading requests except the loading request of the target page in the current loading request queue according to a second preset rule;
if not, suspending all the loading requests in the current loading request queue, and processing the content loaded by all the loading requests in the current loading request queue according to a second preset rule.
Wherein the second preset rule comprises one of the following rules:
rule one is as follows: emptying the contents loaded by other loading requests except the loading request of the target page in the current loading request queue or emptying the contents loaded by all the loading requests in the current loading request queue;
rule two: determining the loading requests with loading contents exceeding a first preset threshold value in the current loading request queue, caching the contents loaded by other loading requests except the loading request of the target page in the determined loading requests with the loading contents exceeding the first preset threshold value or caching the contents loaded by all the loading requests with the loading contents exceeding the first preset threshold value.
Wherein the processing module is configured to:
determining whether the current loading request queue has a loading request of the target page;
if yes, determining that the loading content in the current loading request queue exceeds a second preset threshold and the loading priority level of the loading request is higher than that of the target page, and continuing to execute the determined loading request;
and if not, determining the loading request with the loading content exceeding a second preset threshold value in the current loading request queue, and continuing to execute the determined loading request.
Wherein the execution module is configured to:
and after the loading of the target page is finished, resuming the execution of the loading request in the current loading request queue.
According to a third aspect of the embodiments of the present disclosure, there is provided an apparatus for page loading, the apparatus including:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to:
when a loading request of a target page is received, acquiring the loading request in a current loading request queue;
processing the loading request in the current loading request queue according to a first preset rule;
and executing the loading request of the target page.
According to a first aspect of embodiments of the present disclosure, there is provided a non-transitory computer-readable storage medium, wherein instructions, when executed by a processor of a mobile terminal, enable the mobile terminal to perform a method of page loading, the method comprising:
when a loading request of a target page is received, acquiring the loading request in a current loading request queue;
processing the loading request in the current loading request queue according to a first preset rule;
and executing the loading request of the target page.
The technical scheme provided by the embodiment of the disclosure can have the following beneficial effects: when the network environment is poor, for example, the network speed is slow, that is, in a weak network environment, a user needs to load a target page, in order to make the loading of the target page be processed preferentially, all the loading requests in the current loading request queue are obtained and processed according to a first preset rule, and then the loading request of the target page required by the user can be executed preferentially, so that the loading efficiency is improved, and the user experience is improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
FIG. 1 is a flow diagram illustrating a method of page loading in accordance with an exemplary embodiment.
Fig. 2 is a flowchart illustrating a method for processing the load request in the current load request queue according to the first preset rule in step S12 in fig. 1.
Fig. 3 is a flowchart illustrating a method for processing the load request in the current load request queue according to the first preset rule in step S12 in fig. 1.
FIG. 4 is a flowchart of a page loading method of the embodiment.
FIG. 5 is a block diagram illustrating an apparatus for page loading in accordance with an illustrative embodiment.
Fig. 6 is a block diagram illustrating an apparatus for page loading (general structure of a mobile terminal) according to an exemplary embodiment.
Fig. 7 is a block diagram illustrating an apparatus 700 for page loading (general structure of a server) in accordance with an example embodiment.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the invention, as detailed in the appended claims.
Fig. 1 is a flowchart illustrating a method for page loading according to an exemplary embodiment, where the method for page loading is used in an electronic device, as shown in fig. 1, and includes the following steps:
in step S11, when a load request of a target page is received, a load request in the current load request queue is obtained;
in step S12, processing the load request in the current load request queue according to a first preset rule;
in step S13, the load request of the target page is executed.
In the page loading method provided by the disclosure, when a loading request of a target page is received, the loading request of a current loading request queue is obtained first, and the loading request of the target page is executed after being processed according to a first preset rule. That is, in the page loading method provided by the present disclosure, in order to preferentially process a load request of a target page, after a load request that has been preloaded in a load queue is processed according to a first preset rule, the load request of the target page is executed.
When the network environment is poor, for example, the network speed is slow, that is, in a weak network environment, a user needs to load a target page, in order to make the loading of the target page be processed preferentially, all the loading requests in the current loading request queue are obtained and processed according to a first preset rule, and then the loading request of the target page required by the user can be executed preferentially, so that the loading efficiency is improved, and the user experience is improved.
The target page may be a first-screen page, or may be any other page that needs to be preferentially loaded, for example, a page that needs to be preloaded and is clicked at will by a user may be used as a page that needs to be preferentially loaded.
An embodiment of the present disclosure provides a page loading method, as shown in fig. 2, fig. 2 is a flowchart illustrating a method for processing a load request in the current load request queue according to a first preset rule in step S12 in fig. 1:
in step S121, determining whether there is a load request of a target page in the current load request queue;
in step S122, if yes, suspending other loading requests in the current loading request queue except the loading request of the target page, and processing the content loaded by other loading requests in the current loading request queue except the loading request of the target page according to a second preset rule;
in step S123, if not, all the load requests in the current load request queue are suspended, and the content loaded by all the load requests in the current load request queue is processed according to the second preset rule.
In the page loading method provided by the present disclosure, it may be determined whether there is a loading request of a target page in a current loading queue, and if the loading request of the target page is in the current loading request queue, other loading requests except the loading request of the target page in the current loading request queue are suspended; if not, suspending all the loading requests in the current loading request queue to ensure that the target page required by the user is loaded preferentially; and processing the content loaded by each suspended loading request according to a second preset rule while suspending so as to process the loaded content according to the requirement.
The electronic device may be a terminal device, such as a mobile phone or a computer, or a server device.
In the page loading method provided by the disclosure, when a target page loading demand event occurs, whether a loading request of a target page required to be loaded currently exists in a current loading queue is checked, and if the loading request of the target page required to be loaded currently exists in the current loading queue, other loading requests except the loading request of the target page required to be loaded in the current loading queue are suspended; if not, suspending all loading requests in the current loading queue, ensuring that the target page needing to be loaded at present is loaded preferentially, ensuring that the loading efficiency of the page needed by the user can be improved under various network conditions, and improving the user experience.
In the page loading method provided by the present disclosure, the second preset rule may include one of the following rules:
rule one is as follows: emptying the contents loaded by other loading requests except the loading request of the target page in the current loading request queue or emptying the contents loaded by all the loading requests in the current loading request queue;
rule two: determining the loading requests with loading contents exceeding a first preset threshold value in the current loading request queue, caching the contents loaded by other loading requests except the loading request of the target page in the determined loading requests with the loading contents exceeding the first preset threshold value or caching the contents loaded by all the loading requests with the loading contents exceeding the first preset threshold value.
For rule one, after suspending other load requests except the load request of the target page in the current load request queue or all load requests in the current load request queue, in order to ensure sufficient cache space and further ensure that the target page is preferentially and smoothly loaded, the contents loaded by all suspended load requests can be emptied. Therefore, under the condition of poor network environment, enough cache space can be ensured to load the target page preferentially, the requirements of the user can be met timely, and the user experience is improved.
For rule two, after suspending other load requests except for the load request of the target page in the current load request queue or all load requests in the current load request queue, in order to process the content already loaded by the load request in the current load queue as required, the load request whose load content exceeds the first preset threshold in the current load request queue may be determined, and the content loaded by the other load requests except for the load request of the target page in the load request whose load content exceeds the first preset threshold is cached or the content loaded by all load requests whose load content exceeds the first preset threshold is cached.
And caching the content loaded by the load request with the content exceeding a first preset threshold value in the suspended load request so as to improve the loading efficiency of the load request in the current load request queue after the execution is resumed. The first preset threshold may be set as desired, for example, the first preset threshold may be fifty percent or sixty percent or eighty percent, etc. And for the content loaded by the loading request with the loaded content less than the first preset threshold, emptying to ensure that enough cache space exists and ensure the loading efficiency of the target page.
In the page loading method provided by the present disclosure, each loading request in the current loading request queue except the loading request of the target page may be suspended, and the content loaded by the loading request whose loaded content reaches or exceeds the first preset threshold is cached, so as to be continuously loaded later, or each loading request in the current loading request queue except the loading request of the target page may be suspended and all the loaded content may be emptied, so as to further improve the execution efficiency of the loading request of the target page. Therefore, the processing mode of the loading request can be set according to different network environments so as to meet the requirement of loading the target page of the user.
In an embodiment of the present disclosure, a method for page loading is provided, as shown in fig. 3, fig. 3 shows a flowchart illustrating a method for processing a load request in the current load request queue according to a first preset rule, in step S12 in fig. 1:
in step S124, determining whether there is a load request of the target page in the current load request queue;
in step S125, if yes, determining that the loading content in the current loading request queue exceeds the second preset threshold and the loading priority is higher than that of the loading request of the target page, and continuing to execute the determined loading request;
in step S126, if not, the load request whose load content in the current load request queue exceeds the second preset threshold is determined, and the determined load request is continuously executed.
In the page loading method provided by the present disclosure, it may be determined whether a load request of a target page exists in a current load queue, if the load request of the target page is in the current load request queue, a load request whose load content exceeds a second preset threshold in the current load request queue is determined, the determined load request is continuously executed, and after the determined load request is loaded, the load request of the target page is executed. When the load request of the target page is in the current load queue, two factors can be considered, namely whether the content loaded by the load request in the current load queue exceeds a second preset threshold value, and whether the priority level of the load request with the load content exceeding the second preset threshold value is higher than that of the load request of the target page. For example, when there are 5 load requests whose load contents exceed the second preset threshold, and the load request priority level of the target page is fourth, the first three load requests are continuously executed. And after the first three loading requests are completed, executing the loading request of the target page.
And if the priority levels of the loading requests with the loading contents exceeding the second preset threshold all exceed the loading request of the target page, executing the loading request of the target page after all the loading requests with the loading contents exceeding the second preset threshold are loaded.
For a load request which does not satisfy that the load content exceeds the second preset threshold, the corresponding load request can be suspended from being executed, and the loaded related content can be emptied or cached. The second preset threshold may be selected and set in combination with the current network speed, for example, the second preset threshold may be set to a value close to the completion of loading, that is, a value close to 100%, for example, 98%, 99.5%, or 99.8%. The loading requests of which the loading contents are close to the completion in the current loading request queue are executed continuously without being suspended, so that the loaded contents are not excessively wasted under the condition that the target page is preferentially loaded, and the loading efficiency of the target page and other preloading items is considered.
The embodiment of the disclosure provides a page loading method, which further includes:
and after the loading of the target page is finished, resuming the execution of the loading request in the current loading request queue.
In the page loading method provided by the present disclosure, after the target page is recorded, the loading of the loading content corresponding to each suspended loading request in the current loading request queue is resumed. And the loading request with the cached loading content can be continuously loaded, and the loading request with the emptied loading content can be reloaded.
According to the page loading method provided by the disclosure, the loading requests in the current loading request queue are suspended to preferentially load the target pages required by the user, so that the user experience is improved. And after the target page is loaded, resuming executing each load request in the suspended current load request queue, and continuing executing according to the original execution sequence and rules.
A specific embodiment of a page loading method according to the present disclosure is described below, and fig. 4 is a flowchart of the page loading method of the specific embodiment. In this embodiment, the page loading method is implemented at a computer end or a mobile phone end. Referring to fig. 4, the page loading method includes the following steps:
in step S201, when a load request of a target page is received, a load request in a current load request queue is acquired;
in step S202, it is determined whether there is a load request of the target page in the current load request queue:
in step S2021, if there is any load request, suspending other load requests in the current load request queue except the load request of the target page;
in step S2022, if not, suspending all the load requests in the current load request queue;
then, the content loaded by each suspended loading request is processed, and the content can be completely emptied, or the content loaded by the loading request with the loading content reaching a first preset threshold value is cached, and the other content is emptied;
in step S203, a load request of the target page is executed;
in step S204, after the loading of the target page is completed, the execution of the load request in the current load request queue is resumed, the execution of the load request corresponding to the cached load content is continued, and the execution of the load request corresponding to the emptied load content is resumed.
The page loading method disclosed by the invention can be used for loading the target page required by the user in time and preferentially in the weak network environment and then loading other pre-loading items, so that the page loading efficiency in the weak network environment can be greatly improved, and the user experience is improved. In the process, the loaded content can be continuously loaded, or cached or emptied by combining with the current network speed, and the loading efficiency of other preloaded items is considered under the condition of ensuring the loading efficiency of the user target page.
FIG. 5 is a block diagram illustrating an apparatus for page loading in accordance with an illustrative embodiment. Referring to fig. 5, the apparatus comprises an obtaining module 501, a processing module 502 and an executing module 503, wherein,
an obtaining module 501, configured to obtain a load request in a current load request queue when receiving a load request of a target page;
a processing module 502 configured to process the load request in the current load request queue according to a first preset rule;
an execution module 503 configured to execute the load request of the target page.
Wherein the processing module 502 is configured to:
determining whether the current loading request queue has a loading request of the target page;
if so, suspending other loading requests except the loading request of the target page in the current loading request queue, and processing the content loaded by other loading requests except the loading request of the target page in the current loading request queue according to a second preset rule;
if not, suspending all the loading requests in the current loading request queue, and processing the content loaded by all the loading requests in the current loading request queue according to a second preset rule.
Wherein the second preset rule comprises one of the following rules:
rule one is as follows: emptying the contents loaded by other loading requests except the loading request of the target page in the current loading request queue or emptying the contents loaded by all the loading requests in the current loading request queue;
rule two: determining the loading requests with loading contents exceeding a first preset threshold value in the current loading request queue, caching the contents loaded by other loading requests except the loading request of the target page in the determined loading requests with the loading contents exceeding the first preset threshold value or caching the contents loaded by all the loading requests with the loading contents exceeding the first preset threshold value.
Wherein the processing module 502 is configured to:
determining whether the current loading request queue has a loading request of the target page;
if yes, determining that the loading content in the current loading request queue exceeds a second preset threshold and the loading priority level of the loading request is higher than that of the target page, and continuing to execute the determined loading request;
and if not, determining the loading request with the loading content exceeding a second preset threshold value in the current loading request queue, and continuing to execute the determined loading request.
Wherein the execution module 503 is further configured to:
and after the loading of the target page is finished, resuming the execution of the loading request in the current loading request queue.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
The page loading device disclosed by the invention can be used for timely and preferentially loading the target page required by the user in the weak network environment and then loading other pre-loading items, so that the page loading efficiency in the weak network environment can be greatly improved, and the user experience is improved.
FIG. 6 is a block diagram illustrating an apparatus 600 for page loading in accordance with an example embodiment. For example, the apparatus 600 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 6, apparatus 600 may include one or more of the following components: a processing component 602, a memory 604, a power component 606, a multimedia component 608, an audio component 610, an interface to input/output (I/O) 612, a sensor component 614, and a communication component 616.
The processing component 602 generally controls overall operation of the device 600, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 602 may include one or more processors 620 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 602 can include one or more modules that facilitate interaction between the processing component 602 and other components. For example, the processing component 602 can include a multimedia module to facilitate interaction between the multimedia component 608 and the processing component 602.
The memory 604 is configured to store various types of data to support operation at the device 600. Examples of such data include instructions for any application or method operating on device 600, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 604 may be implemented by any type or combination of volatile or non-volatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
The multimedia component 608 includes a screen that provides an output interface between the device 600 and a user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 608 includes a front facing camera and/or a rear facing camera. The front camera and/or the rear camera may receive external multimedia data when the device 600 is in an operating mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 610 is configured to output and/or input audio signals. For example, audio component 610 includes a Microphone (MIC) configured to receive external audio signals when apparatus 600 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signal may further be stored in the memory 604 or transmitted via the communication component 616. In some embodiments, audio component 610 further includes a speaker for outputting audio signals.
The I/O interface 612 provides an interface between the processing component 602 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor component 614 includes one or more sensors for providing status assessment of various aspects of the apparatus 600. For example, the sensor component 614 may detect an open/closed state of the device 600, the relative positioning of components, such as a display and keypad of the apparatus 600, the sensor component 614 may also detect a change in position of the apparatus 600 or a component of the apparatus 600, the presence or absence of user contact with the apparatus 600, orientation or acceleration/deceleration of the apparatus 600, and a change in temperature of the apparatus 600. The sensor assembly 614 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 614 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 614 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 616 is configured to facilitate communications between the apparatus 600 and other devices in a wired or wireless manner. The apparatus 600 may access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 616 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 616 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 600 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer readable storage medium comprising instructions, such as the memory 604 comprising instructions, executable by the processor 620 of the apparatus 600 to perform the method of page loading described above is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
A non-transitory computer readable storage medium having instructions therein which, when executed by a processor of a mobile terminal, enable the mobile terminal to perform a method of page loading, the method comprising: when a loading request of a target page is received, acquiring the loading request in a current loading request queue; processing the loading request in the current loading request queue according to a first preset rule; and executing the loading request of the target page.
FIG. 7 is a block diagram illustrating an apparatus 700 for page loading in accordance with an example embodiment. For example, the apparatus 700 may be provided as a server. Referring to fig. 7, apparatus 700 includes a processing component 722 that further includes one or more processors and memory resources, represented by memory 732, for storing instructions, such as applications, that are executable by processing component 722. The application programs stored in memory 732 may include one or more modules that each correspond to a set of instructions. Further, the processing component 722 is configured to execute instructions to perform the above-described method: when a loading request of a target page is received, acquiring the loading request in a current loading request queue; processing the loading request in the current loading request queue according to a first preset rule; and executing the loading request of the target page.
The apparatus 700 may also include a power component 726 configured to perform power management of the apparatus 700, a wired or wireless network interface 750 configured to connect the apparatus 700 to a network, and an input output (I/O) interface 758. The apparatus 700 may operate based on an operating system stored in memory 732, such as Windows Server, Mac OSXTM, UnixTM, LinuxTM, FreeBSDTM, or the like.
Other embodiments of the invention will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the invention following, in general, the principles of the invention and including such departures from the present disclosure as come within known or customary practice within the art to which the invention pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the invention being indicated by the following claims.
It will be understood that the invention is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the invention is limited only by the appended claims.
Claims (12)
1. A page loading method is applied to electronic equipment, and is characterized in that the method comprises the following steps:
when a loading request of a target page is received, acquiring the loading request in a current loading request queue;
processing the loading request in the current loading request queue according to a first preset rule;
and executing the loading request of the target page.
2. The method according to claim 1, wherein the processing the load request in the current load request queue according to a first preset rule comprises:
determining whether the current loading request queue has a loading request of the target page;
if so, suspending other loading requests except the loading request of the target page in the current loading request queue, and processing the content loaded by other loading requests except the loading request of the target page in the current loading request queue according to a second preset rule;
if not, suspending all the loading requests in the current loading request queue, and processing the content loaded by all the loading requests in the current loading request queue according to a second preset rule.
3. The method according to claim 2, wherein the second preset rule comprises one of the following rules:
rule one is as follows: emptying the contents loaded by other loading requests except the loading request of the target page in the current loading request queue or emptying the contents loaded by all the loading requests in the current loading request queue;
rule two: determining the loading requests with loading contents exceeding a first preset threshold value in the current loading request queue, caching the contents loaded by other loading requests except the loading request of the target page in the determined loading requests with the loading contents exceeding the first preset threshold value or caching the contents loaded by all the loading requests with the loading contents exceeding the first preset threshold value.
4. The method according to claim 1, wherein the processing the load request in the current load request queue according to a first preset rule comprises:
determining whether the current loading request queue has a loading request of the target page;
if yes, determining that the loading content in the current loading request queue exceeds a second preset threshold and the loading priority level of the loading request is higher than that of the target page, and continuing to execute the determined loading request;
and if not, determining the loading request with the loading content exceeding a second preset threshold value in the current loading request queue, and continuing to execute the determined loading request.
5. The method of claim 1, further comprising:
and after the loading of the target page is finished, resuming the execution of the loading request in the current loading request queue.
6. An apparatus for page loading, the apparatus comprising:
the acquisition module is configured to acquire a loading request in a current loading request queue when receiving the loading request of a target page;
the processing module is configured to process the loading requests in the current loading request queue according to a first preset rule;
an execution module configured to execute the load request of the target page.
7. The apparatus of claim 6, wherein the processing module is configured to:
determining whether the current loading request queue has a loading request of the target page;
if so, suspending other loading requests except the loading request of the target page in the current loading request queue, and processing the content loaded by other loading requests except the loading request of the target page in the current loading request queue according to a second preset rule;
if not, suspending all the loading requests in the current loading request queue, and processing the content loaded by all the loading requests in the current loading request queue according to a second preset rule.
8. The apparatus of claim 7, wherein the second predetermined rule comprises one of the following rules:
rule one is as follows: emptying the contents loaded by other loading requests except the loading request of the target page in the current loading request queue or emptying the contents loaded by all the loading requests in the current loading request queue;
rule two: determining the loading requests with loading contents exceeding a first preset threshold value in the current loading request queue, caching the contents loaded by other loading requests except the loading request of the target page in the determined loading requests with the loading contents exceeding the first preset threshold value or caching the contents loaded by all the loading requests with the loading contents exceeding the first preset threshold value.
9. The apparatus of claim 6, wherein the processing module is configured to:
determining whether the current loading request queue has a loading request of the target page;
if yes, determining that the loading content in the current loading request queue exceeds a second preset threshold and the loading priority level of the loading request is higher than that of the target page, and continuing to execute the determined loading request;
and if not, determining the loading request with the loading content exceeding a second preset threshold value in the current loading request queue, and continuing to execute the determined loading request.
10. The apparatus of claim 6, wherein the execution module is configured to:
and after the loading of the target page is finished, resuming the execution of the loading request in the current loading request queue.
11. An apparatus for page loading, the apparatus comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to:
when a loading request of a target page is received, acquiring the loading request in a current loading request queue;
processing the loading request in the current loading request queue according to a first preset rule;
and executing the loading request of the target page.
12. A non-transitory computer readable storage medium having instructions therein which, when executed by a processor of a mobile terminal, enable the mobile terminal to perform a method of page loading, the method comprising:
when a loading request of a target page is received, acquiring the loading request in a current loading request queue;
processing the loading request in the current loading request queue according to a first preset rule;
and executing the loading request of the target page.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202010597766.8A CN111753235B (en) | 2020-06-28 | 2020-06-28 | Page loading method, device and storage medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202010597766.8A CN111753235B (en) | 2020-06-28 | 2020-06-28 | Page loading method, device and storage medium |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN111753235A true CN111753235A (en) | 2020-10-09 |
| CN111753235B CN111753235B (en) | 2024-10-01 |
Family
ID=72677522
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202010597766.8A Active CN111753235B (en) | 2020-06-28 | 2020-06-28 | Page loading method, device and storage medium |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN111753235B (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN118802882A (en) * | 2024-06-17 | 2024-10-18 | 中移物联网有限公司 | Page request processing method, device, electronic device, storage medium and product |
Citations (13)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20040030882A1 (en) * | 2002-08-08 | 2004-02-12 | Forman George Henry | Managed application pre-launching |
| US20070220211A1 (en) * | 2006-03-16 | 2007-09-20 | Johns Charles R | Load when reservation lost instruction for performing cacheline polling |
| CN103699670A (en) * | 2013-12-30 | 2014-04-02 | 北京奇虎科技有限公司 | Processing device and method for E-map tile request queues |
| US20140250365A1 (en) * | 2013-03-04 | 2014-09-04 | International Business Machines Corporation | User influenced asynchronous module definition loader |
| US20150242325A1 (en) * | 2014-02-24 | 2015-08-27 | Jason Caulkins | Progressive Pre-Caching |
| CN105824533A (en) * | 2016-03-21 | 2016-08-03 | 青岛海信移动通信技术股份有限公司 | A picture loading method, device and terminal |
| CN105955766A (en) * | 2016-04-22 | 2016-09-21 | 北京小米移动软件有限公司 | Method and device for application preloading |
| CN106294609A (en) * | 2016-07-29 | 2017-01-04 | 北京小米移动软件有限公司 | Page loading method and device |
| CN107398070A (en) * | 2017-07-19 | 2017-11-28 | 腾讯科技(深圳)有限公司 | Display control method and device, the electronic equipment of a kind of game picture |
| CN108509243A (en) * | 2018-03-15 | 2018-09-07 | 广州虎牙信息科技有限公司 | The method, apparatus and electronic equipment of a kind of page load in application |
| CN108595228A (en) * | 2018-05-10 | 2018-09-28 | Oppo广东移动通信有限公司 | Application program prediction model establishing method and device, storage medium and mobile terminal |
| CN108762831A (en) * | 2018-05-15 | 2018-11-06 | Oppo广东移动通信有限公司 | Application program preloads method, apparatus, storage medium and terminal |
| CN108846113A (en) * | 2018-06-25 | 2018-11-20 | 郑州云海信息技术有限公司 | A kind of method, system and associated component that picture preloads |
-
2020
- 2020-06-28 CN CN202010597766.8A patent/CN111753235B/en active Active
Patent Citations (14)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20040030882A1 (en) * | 2002-08-08 | 2004-02-12 | Forman George Henry | Managed application pre-launching |
| US20070220211A1 (en) * | 2006-03-16 | 2007-09-20 | Johns Charles R | Load when reservation lost instruction for performing cacheline polling |
| US20140250365A1 (en) * | 2013-03-04 | 2014-09-04 | International Business Machines Corporation | User influenced asynchronous module definition loader |
| CN103699670A (en) * | 2013-12-30 | 2014-04-02 | 北京奇虎科技有限公司 | Processing device and method for E-map tile request queues |
| US20150242325A1 (en) * | 2014-02-24 | 2015-08-27 | Jason Caulkins | Progressive Pre-Caching |
| CN110058764A (en) * | 2016-03-21 | 2019-07-26 | 青岛海信移动通信技术股份有限公司 | A kind of picture loading method, device and terminal |
| CN105824533A (en) * | 2016-03-21 | 2016-08-03 | 青岛海信移动通信技术股份有限公司 | A picture loading method, device and terminal |
| CN105955766A (en) * | 2016-04-22 | 2016-09-21 | 北京小米移动软件有限公司 | Method and device for application preloading |
| CN106294609A (en) * | 2016-07-29 | 2017-01-04 | 北京小米移动软件有限公司 | Page loading method and device |
| CN107398070A (en) * | 2017-07-19 | 2017-11-28 | 腾讯科技(深圳)有限公司 | Display control method and device, the electronic equipment of a kind of game picture |
| CN108509243A (en) * | 2018-03-15 | 2018-09-07 | 广州虎牙信息科技有限公司 | The method, apparatus and electronic equipment of a kind of page load in application |
| CN108595228A (en) * | 2018-05-10 | 2018-09-28 | Oppo广东移动通信有限公司 | Application program prediction model establishing method and device, storage medium and mobile terminal |
| CN108762831A (en) * | 2018-05-15 | 2018-11-06 | Oppo广东移动通信有限公司 | Application program preloads method, apparatus, storage medium and terminal |
| CN108846113A (en) * | 2018-06-25 | 2018-11-20 | 郑州云海信息技术有限公司 | A kind of method, system and associated component that picture preloads |
Non-Patent Citations (1)
| Title |
|---|
| 邓妙怡: "网络电视用户切换行为特征分析与预加载策略研究", 中国优秀硕士学位论文全文数据库 信息科技辑, 15 May 2017 (2017-05-15), pages 136 - 303 * |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN118802882A (en) * | 2024-06-17 | 2024-10-18 | 中移物联网有限公司 | Page request processing method, device, electronic device, storage medium and product |
| CN118802882B (en) * | 2024-06-17 | 2025-12-09 | 中移物联网有限公司 | Page request processing method and device, electronic equipment, storage medium and product |
Also Published As
| Publication number | Publication date |
|---|---|
| CN111753235B (en) | 2024-10-01 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN105338409B (en) | Network video preloading method and device | |
| CN106033397B (en) | Memory buffer area adjusting method, device and terminal | |
| CN109600303B (en) | Content sharing method, device and storage medium | |
| CN109388625B (en) | Method and device for processing configuration file in multi-distributed file system | |
| CN104462296B (en) | File management method and device and terminal | |
| CN109521918B (en) | Information sharing method and device, electronic equipment and storage medium | |
| CN106851695B (en) | Method, device and system for testing network speed | |
| CN107529065A (en) | Multi-medium data caching method, device and computer-readable recording medium | |
| CN112291631A (en) | Information acquisition method, device, terminal and storage medium | |
| CN107423394A (en) | Page display method and device | |
| CN111259289A (en) | Picture loading method and device, electronic equipment and storage medium | |
| CN105517078A (en) | Network connection switching method and device | |
| CN112685269A (en) | Data acquisition method and device, electronic equipment and storage medium | |
| CN104572230B (en) | Script file loading method and device and script file generating method and device | |
| CN111753235B (en) | Page loading method, device and storage medium | |
| CN112083841B (en) | Information input method, device and storage medium | |
| CN114077461A (en) | Application running method, device, device and storage medium | |
| CN109245992B (en) | Request processing method and device, electronic equipment and storage medium | |
| CN112307229A (en) | Data processing method and apparatus, electronic device, computer-readable storage medium | |
| CN109981729B (en) | File processing method and device, electronic equipment and computer readable storage medium | |
| CN113885986A (en) | Data transmission method and device and electronic equipment | |
| CN107885553B (en) | Animation loading method, device and electronic device | |
| CN107016081A (en) | page loading method and device | |
| CN106339470A (en) | Method and device for processing file | |
| CN113259995A (en) | Information processing method, device and storage medium |
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 |