Document display method, device, apparatus and storage medium

By retrieving and caching the content of the first screen of the online document before displaying the target online document, the problem of low efficiency in online document display is solved, improving user experience and saving data.

CN117009688BActive Publication Date: 2025-12-23TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210852336.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-20
Publication Date
2025-12-23
Estimated Expiration
2042-07-20

AI Technical Summary

Technical Problem

The current online document display efficiency is low, affecting user experience and efficiency.

Method used

Before displaying the target online document, the content of the first screen document is retrieved and cached as local content, and then displayed in the document display area according to the local content, avoiding the retrieval of unnecessary document content.

Benefits of technology

It improves the display efficiency and user experience of online documents, saves bandwidth, and avoids resource waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117009688B_ABST
    Figure CN117009688B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a document display method, device and equipment, and a storage medium. The document display method comprises the following steps: determining a target online document to be displayed in a document display area, and sending a first acquisition request about the first-screen document content in the target online document to a target server; the first-screen document content is the document content displayed in the document display area when the target online document is opened; acquiring the first-screen document content fed back by the target server in response to the first acquisition request, and locally caching and storing the first-screen document content as local content; displaying the target online document, and displaying the target online document in the document display area according to the local content. The embodiments of the present application can improve the efficiency of displaying the target online document.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer, in particular to a document display method and device, equipment and storage medium. BACKGROUND

[0002] At present, online documents have been widely used, and many application programs support online document functions. The so-called online document is a kind of efficient online collaborative document, and an online document supports at least one user to view or edit simultaneously. A user can pull the document content of the corresponding online document through the document portal of the online document, so as to display the online document based on the obtained document content. However, it is found in practice that the current display method of the online document has the problem of low efficiency. Therefore, how to improve the display efficiency of the online document has become a research hotspot. SUMMARY

[0003] The embodiments of the present application provide a document display method, device, equipment and storage medium, which can cache and store the obtained first-screen document content as local content in the local, display the target online document, and display the target online document according to the local content in the document display area, so as to effectively improve the display efficiency of the target online document, improve the user experience, and enhance the user stickiness.

[0004] In one aspect, the embodiments of the present application provide a document display method, which comprises:

[0005] determining a target online document to be displayed in a document display area, and sending a first acquisition request about first-screen document content in the target online document to a target server; the first-screen document content is the document content displayed in the document display area when the target online document is opened;

[0006] acquiring the first-screen document content fed back by the target server in response to the first acquisition request, and caching and storing the first-screen document content as local content in the local;

[0007] displaying the target online document, and displaying the target online document according to the local content in the document display area.

[0008] In another aspect, the embodiments of the present application provide a document display device, which comprises:

[0009] a processing unit configured to determine a target online document to be displayed in a document display area, and send a first acquisition request about first-screen document content in the target online document to a target server; the first-screen document content is the document content displayed in the document display area when the target online document is opened;

[0010] The processing unit is further configured to acquire first-screen document content fed back by the target server in response to the first acquisition request, and cache and store the first-screen document content locally as local content;

[0011] The output unit is configured to display the target online document and display the target online document in the document display area according to the local content.

[0012] In another aspect, an embodiment of the present application provides a computer device, which comprises a processor and a memory, wherein the memory is configured to store a computer program, and the computer program is configured to implement the following steps when executed by the processor:

[0013] determining a target online document to be displayed in a document display area, and sending a first acquisition request about first-screen document content in the target online document to a target server; the first-screen document content is document content displayed in the document display area when the target online document is opened;

[0014] acquiring first-screen document content fed back by the target server in response to the first acquisition request, and caching and storing the first-screen document content locally as local content;

[0015] displaying the target online document and displaying the target online document in the document display area according to the local content.

[0016] In another aspect, an embodiment of the present application provides a computer storage medium, which stores a computer program, and the computer program is adapted to be loaded and executed by a processor to implement the following steps:

[0017] determining a target online document to be displayed in a document display area, and sending a first acquisition request about first-screen document content in the target online document to a target server; the first-screen document content is document content displayed in the document display area when the target online document is opened;

[0018] acquiring first-screen document content fed back by the target server in response to the first acquisition request, and caching and storing the first-screen document content locally as local content;

[0019] displaying the target online document and displaying the target online document in the document display area according to the local content.

[0020] In another aspect, an embodiment of the present application provides a computer program product, which comprises a computer program, and the computer program is configured to implement the above-mentioned document display method when executed by a processor.

[0021] After determining the target online document to be displayed in the document display area, the embodiment of the present application can send a first acquisition request about the first-screen document content in the target online document to the target server, the first-screen document content being the document content displayed in the document display area when the target online document is opened; then, the first-screen document content fed back by the target server in response to the first acquisition request can be acquired, and the first-screen document content can be cached locally and stored as local content, so as to display the target online document and display the target online document in the document display area according to the local content, which can effectively improve the efficiency of displaying the target online document. It can be seen that, before displaying the target online document, the embodiment of the present application can acquire the first-screen document content in the target online document to store as local content, thereby improving the efficiency and experience of using the target online document by the user and improving the user stickiness; and the embodiment of the present application can acquire the first-screen document content in the target online document based on the first acquisition request only, without acquiring the document content in the target online document other than the first-screen document content, so as to achieve the purpose of flow control, which can ensure that the user can quickly see the corresponding first-screen document content when opening the target online document, and can reduce unnecessary acquisition of document content when not displaying the target online document, that is, unnecessary data acquisition can be saved, thereby effectively saving traffic and avoiding resource waste. BRIEF DESCRIPTION OF DRAWINGS

[0022] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced. Obviously, the drawings in the following description are some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0023] Figure 1a is a flow diagram of a document display scheme provided by the embodiment of the present application;

[0024] Figure 1b is a schematic diagram of interaction between a terminal and a server provided by the embodiment of the present application;

[0025] Figure 2 is a flow diagram of a document display method provided by the embodiment of the present application;

[0026] Figure 3a is a schematic diagram of a document entry of a target online document provided by the embodiment of the present application;

[0027] Figure 3b is a schematic diagram of another document entry of a target online document provided by the embodiment of the present application;

[0028] Figure 3cis a schematic view of a document entry of a target online document provided by an embodiment of the present application;

[0029] Figure 3d is a schematic view of a document entry of a target online document provided by an embodiment of the present application;

[0030] Figure 3e is a schematic view of an updated document entry display interface provided by an embodiment of the present application;

[0031] Figure 3f is a schematic view of a brightness highlight provided by an embodiment of the present application;

[0032] Figure 3g is a schematic view of a color highlight provided by an embodiment of the present application;

[0033] Figure 3h is a schematic view of an identification highlight provided by an embodiment of the present application;

[0034] Figure 3i is a schematic view of a deletion mark provided by an embodiment of the present application;

[0035] Figure 3j is a schematic view of a deletion prompt provided by an embodiment of the present application;

[0036] Figure 4 is a flowchart of another document display method provided by an embodiment of the present application;

[0037] Figure 5a is a schematic view of a module interaction provided by an embodiment of the present application;

[0038] Figure 5b is a flowchart of initiating a pre-pull document data request provided by an embodiment of the present application;

[0039] Figure 5c is a flowchart of triggering a timer provided by an embodiment of the present application;

[0040] Figure 5d is a flowchart of displaying document content provided by an embodiment of the present application;

[0041] Figure 6 is a structural schematic view of a document display apparatus provided by an embodiment of the present application;

[0042] Figure 7 is a structural schematic view of a computer device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0043] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application.

[0044] With the continuous development of Internet technology, artificial intelligence (AI) technology has also been better developed. Artificial intelligence is to use a digital computer or a machine controlled by a digital computer to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use the knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology of computer science, which attempts to understand the essence of intelligence and produce a new intelligent machine that can react in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines, so that the machine has the functions of perception, reasoning and decision-making.

[0045] Artificial intelligence technology is a comprehensive discipline, involving a wide range of fields, both hardware and software technologies. Artificial intelligence basic technologies generally include technologies such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction system, mechatronics, etc. Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning, etc.

[0046] Among them, machine learning (Machine Learning, ML) is a multi-field interdisciplinary subject, involving probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory, etc. It is a subject that studies how computers simulate or implement human learning behavior to acquire new knowledge or skills, and reorganize existing knowledge structure to continuously improve their performance. Machine learning is the core of artificial intelligence and the fundamental approach to making computers intelligent, and its applications are widespread in various fields of artificial intelligence. Deep learning is a technology that uses deep neural network systems for machine learning; machine learning and deep learning usually include artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and rule-based learning.

[0047] Based on the machine learning / deep learning technology in the AI technology, the embodiments of the present application propose a document display scheme to improve the rate of displaying target online documents. It should be noted that the embodiments of the present application can be applied to various scenarios, including but not limited to cloud technology, artificial intelligence, intelligent transportation, and assisted driving.

[0048] Referring to Figure 1aAs shown, the general principle of the document display scheme proposed in the embodiments of the present application is as follows: first, the target online document to be displayed in the document display area is determined, and a first acquisition request about the first-screen document content in the target online document is sent to the target server; based on this, the corresponding first-screen document content can be obtained from the target server, and the first-screen document content is cached and stored as local content; further, the target online document can be displayed, and the target online document is displayed according to the local content in the document display area.

[0049] It is proved by practice that the document display scheme proposed in the embodiments of the present application can have at least the following beneficial effects: ①the first-screen document content in the target online document can be obtained and stored as local content before the target online document is displayed, so as to accelerate the display of the first-screen document content in the target online document when the target online document is displayed, and improve the display efficiency of the target online document; ②the user experience of opening the target online document is improved, and the user stickiness is improved.

[0050] In specific implementation, the above-mentioned document display scheme can be executed by a computer device, which can be a terminal or a server; wherein the terminal mentioned here can include but is not limited to: smart phones, tablet computers, notebook computers, desktop computers, smart watches, smart voice interaction devices, smart home appliances, vehicle-mounted terminals, aircraft, etc.; various kinds of clients (application, APP) can be run in the terminal, such as video playing clients, social clients, browser clients, information flow clients, education clients, etc. The server mentioned here can be a standalone physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and basic cloud computing services such as big data and artificial intelligence platforms, etc.; the so-called cloud computing is a computing mode that distributes computing tasks on a resource pool composed of a large number of computers, so that various application systems can obtain computing power, storage space and information services according to needs. Moreover, the computer device mentioned in the embodiments of the present application can be located outside the blockchain network, or can be located inside the blockchain network, which is not limited; the so-called blockchain network is a network composed of a point-to-point network (P2P network) and a blockchain, and the blockchain refers to a new application mode of distributed data storage, point-to-point transmission, consensus mechanism, encryption algorithm and other computer technologies, which is essentially a decentralized database, and is a series of data blocks (or blocks) associated by using cryptographic methods.

[0051] Alternatively, in other embodiments, the above-mentioned document display scheme can also be executed by the server and the terminal together; the terminal and the server can be directly or indirectly connected through wired or wireless communication, which is not limited in the present application. For example: the terminal can be responsible for determining the target online document to be displayed in the document display area, and sending a first acquisition request about the first-screen document content in the target online document to the server; so that the server receiving the first acquisition request can send the first acquisition request to the target server to obtain the corresponding first-screen document content from the target server, and send the first-screen document content to the terminal; then the terminal stores the first-screen document content as local content, and displays the target online document according to the local content, as shown in Figure 1b For another example, the terminal can be responsible for determining the target online document to be displayed in the document display area, and sending a first acquisition request about the first-screen document content in the target online document to the target server, so that the target server can send the corresponding first-screen document content to the intermediate server, and then the intermediate server sends the first-screen document content to the terminal; then the terminal stores the first-screen document content, and displays the target online document according to the local content in the document display area when displaying the target online document. It should be understood that the above-mentioned two cases of the terminal and the server executing the above-mentioned document display scheme together are only exemplary, and are not exhaustive.

[0052] Based on the above description of the document display scheme, the embodiment of the present application proposes a document display method, which can be executed by the above-mentioned computer device (terminal or server) or the client in the computer device; or the document display method can be executed by the terminal and the server together. For convenience of description, the computer device executes the document display method in the following description; please refer to Figure 2 The document display method can include the following steps S201-S203:

[0053] S201, determining a target online document to be displayed in a document display area, and sending a first acquisition request about the first-screen document content in the target online document to a target server.

[0054] The first-screen document content refers to the document content displayed in the document display area when the target online document is opened; further, the first-screen document content refers to the document content displayed in the document display area when the target online document is opened and the document display area is not executed content update operation, that is, the part of the content that the user first sees visually when viewing the document content in the target online document; wherein the content update operation can refer to a vertical sliding operation, a horizontal sliding operation, or an input display update voice operation, which is not limited in the present application. In the embodiment of the present application, the first-screen document content can also be referred to as first-screen data.

[0055] It should be noted that the first screen document content in any online document can be the first screen document content of the any online document (i.e., the document content in the target online document located before other document content), or can be the last presented document content of the any online document at the last time of display (i.e., the document content displayed when the last time of display is closed), which is not limited in the present application.

[0056] Correspondingly, the above document display area can refer to the entire display area in the display interface, or can refer to the preset display area in the display interface, which is not limited in the present application; wherein, the preset display area can be set according to experience, or can be set according to actual needs, which is not limited in the present application.

[0057] In the embodiment of the present application, the target server can be an independent physical server, or can be a server cluster or distributed system composed of multiple physical servers, or can be a cloud server, which is not limited in the present application; correspondingly, the document content in the target online document is stored in the target server. And, the target server can also be referred to as a document background or background in the embodiment of the present application.

[0058] It should be noted that the document format (i.e., the document category) of the online document includes but is not limited to: document, table, PPT (Microsoft Office PowerPoint, slide), collection table, mind map (i.e., mind map) and flowchart, etc. In this case, different document categories can be distinguished by URL Path; for example, the URL Path prefixes of the document, table, PPT, collection table, mind map and flowchart can be as follows, respectively:

[0059] https: / / doc.XXX.com / doc

[0060] https: / / doc.XXX.com / sheet

[0061] https: / / doc.XXX.com / slide

[0062] https: / / doc.XXX.com / forms

[0063] https: / / doc.XXX.com / mind

[0064] https: / / doc.XXX.com / flowchart

[0065] Correspondingly, taking the online document with the document category of flowchart as an example for description, the online document of this kind can comply with the following format:

[0066] https: / / doc.XXX.com / flowchart / f3_ACwAQwbdAFwqLuBi43MTNutMrbP0J; where f3_ACwAQwbdAFwqLuBi43MTNutMrbP0J can be referred to as the id (identity) of the online document, i.e., the document identifier.

[0067] In a specific implementation, the computer device can display a document entry of the target online document, the document entry of the target online document being used to start the target online document to display the document content contained in the target online document; where the target online document to be displayed in the document display area can be determined when the document entry of the target online document is displayed; that is, the online document displaying the document entry can be taken as the online document that the user can open, and as the target online document to be displayed in the document display area; in this case, for any displayed document entry, the online document corresponding to the document entry can be taken as the target online document. Correspondingly, one document entry can correspond to one URL Path (Uniform Resource Locator Path, Uniform Resource Locator Path), that is, the online document indicated by the corresponding URL Path (i.e., the online document corresponding to the document entry) can be started through the document entry. It should be noted that the presentation form of the document entry can be a picture, a text, or a link, which is not limited in the present application.

[0068] It should be understood that when the user enters the scene where the online document appears, that is, the document entry display interface (the interface that the user can visually see and can view the document content through further operation) is displayed, the scene where the user can open the online document can be automatically recognized, so that the online document displaying the document entry is taken as the target online document to determine the target online document to be displayed in the document display area. Wherein the document entry display interface can also be referred to as the place where the document entry is displayed.

[0069] In the embodiments of the present application, the determination of the target online document to be displayed in the document display area includes but is not limited to the following several ways:

[0070] The first determination method: the computer device can display the document entry of the target online document in the document list, that is, the document list interface can be displayed, and the document entry of the online document is displayed in the document list interface, so as to take the online document corresponding to the displayed document entry as the target online document, that is, to determine the target online document to be displayed in the document display area; for example, as shown in Figure 3a The document 1 corresponding to the document entry displayed in the document list interface can be taken as the target online document in this case. In this case, the document entry display interface refers to the document list interface.

[0071] The second determining manner: the computer device can display the document entry of the online document in the conversation message, that is, a conversation interface in which the document entry of the online document is displayed is displayed, so as to take the online document corresponding to the displayed document entry as the target online document, that is, to determine the target online document to be displayed in the document display area; for example, as shown in Figure 3b The document 1 corresponding to the document entry displayed in the conversation interface is taken as the target online document. In this case, the document entry display interface refers to the conversation interface.

[0072] The third determining manner: the computer device can display the document entry of the online document in the collection list, that is, a collection interface in which the document entry of the online document is displayed is displayed, so as to take the online document corresponding to the displayed document entry as the target online document, that is, to determine the target online document to be displayed in the document display area; for example, as shown in Figure 3c The document 1 corresponding to the document entry displayed in the collection interface is taken as the target online document. In this case, the document entry display interface refers to the collection interface.

[0073] The fourth determining manner: the computer device can display the document entry of the online document in the micro disk, that is, a micro disk interface in which the document entry of the online document is displayed is displayed, so as to take the online document corresponding to the displayed document entry as the target online document, that is, to determine the target online document to be displayed in the document display area; for example, as shown in Figure 3d The online documents corresponding to the five document entries displayed in the micro disk interface are all taken as the target online document, and the like. In this case, the document entry display interface refers to the micro disk interface.

[0074] Further, when detecting an interface updating operation on the document entry display interface, the document entry display interface can be updated to obtain an updated document entry display interface; then, the online document corresponding to the new document entry in the updated document entry display interface is taken as the target online document. The document entry display interface includes but is not limited to: a document list interface, a conversation interface, a collection interface, and a micro disk interface, and the like. The new document entry refers to: the document entry displayed in the updated document entry display interface; or refers to: the document entry displayed in the updated document entry display interface, and the corresponding online document has not been taken as the target online document before the current system time; or refers to: the document entry displayed in the updated document entry display interface, and the corresponding online document has not been taken as the target online document within a preset time range, and the like.

[0075] For example, as shown in Figure 3eAs shown, the document entry display interface is taken as an example of the session interface, and when the interface update operation for the session interface is detected, the updated document entry display interface can be obtained, and the updated document entry display interface includes the new document entry (i.e., the document entry of document 2); in this case, the computer device can also take document 2 as the target online document.

[0076] It should be understood that, Figures 3a-3e The schematic diagrams shown in FIGS. 1A and 1B each exemplarily represent a document entry display interface of a target online document, and the present application does not limit the same; for example, the presentation manner of the document entry can also be text; for another example, the presentation manner of the document entry can also be a link, and the like.

[0077] S202, obtaining the first-screen document content fed back by the target server in response to the first acquisition request, and caching and storing the first-screen document content locally as local content.

[0078] The first-screen document content fed back by the target server in response to the first acquisition request is the first-screen document content in the target online document; in the embodiment of the present application, after obtaining the first-screen document content in the target online document, the computer device can store the first-screen document content in the local cache, that is, when the first-screen document content is cached locally, the first-screen document content can be cached in the local cache as local content. It should be noted that the process of obtaining the first-screen document content from the target server based on the first acquisition request by the computer device can also be referred to as a pre-pull process of the document first screen.

[0079] It should be understood that the computer device can obtain the corresponding document content from the target server based on the first acquisition request, that is, only obtain the first-screen document content in the target online document from the target server, and then cache and store it locally as local content, so that the local content only includes the first-screen document content in the target online document; in this case, when the local content is not used, a large amount of waste of traffic required to obtain the document content can be avoided, thereby saving traffic in a throttling manner.

[0080] Optionally, the local storage structure can be a K-V structure (i.e., a Key (keyword)-Value (value) structure), wherein the Key can be a document identifier (such as docid), and the Value can be a DocPrepareRspItem object (a data object) corresponding to the document identifier; specifically, the document first-screen data structure of any online document can be as follows:

[0081]

[0082] Wherein, the prepare_docid is used to represent the document identification of the pre-pulled online document, the cookie is used to represent the session content, the is_delete is used to judge whether the online document is deleted (for example, the value of the is_delete is true, which can represent that the corresponding online document is not deleted, the value of the is_delete is false, which can represent that the corresponding online document is deleted, and the like), and the expire_time field indicates the valid time length of the local content, which can avoid that the first screen document content of a target online document is frequently requested.

[0083] Further, after successfully obtaining the first screen document content, the computer device can highlight the document entry of the target online document, which includes any one of the following: highlight display, color display and identification display; or, the target online document is started, and the local content of the target online document is displayed in the document display area. Wherein, when the highlight display is the identification display, the highlight identification for highlighting the document entry of the target online document can be displayed, which can be a text identification or a symbol identification, which is not limited in the present application.

[0084] For example, if the above highlight display is the brightness highlight display, the schematic diagram of the highlight display is as shown in Figure 3f For example, if the above highlight display is the color highlight display, the schematic diagram of the highlight display is as shown in Figure 3g For example, if the above highlight display is the identification highlight display, the schematic diagram of the highlight display is as shown in Figure 3h It should be noted that Figures 3f-3h which are all exemplary schematic diagrams of highlighting the document entry, which are not limited in the present application; for example, the color, brightness and highlight identification of the document entry can be adjusted.

[0085] Correspondingly, if the target online document is deleted, that is, the target online document is not stored in the target server, the computer device can output a deletion identification, which is used to prompt the target object (i.e. the user) that the target online document has been deleted. Optionally, when the computer device has a document starting permission for starting the target online document, and the target online document is deleted, the deletion identification can be outputted.

[0086] It should be noted that the deletion identification can be a text identification or a symbol identification, which is not limited in the present application; for example, as shown in Figure 3i For example, the deletion identification is a text identification, when the target online document is deleted, the deletion identification "the document has been deleted" can be outputted. It should be understood that Figure 3iThe figure only exemplarily shows the display of the deletion identifier, and the application is not limited thereto; for example, when the deletion identifier is a character identifier, the deletion identifier can also be "deleted" and "delete", etc.

[0087] S203, displaying the target online document and displaying the target online document according to local content in the document display area.

[0088] It should be noted that the computer device can display the target online document when detecting a display operation on the target online document; wherein the display operation can refer to a trigger operation on the document entry of the target online document, or an operation of inputting a voice for displaying the target online document, and the application is not limited thereto; and the trigger operation includes but is not limited to a click operation, a long press operation (i.e. an operation of pressing for a time longer than a preset pressing time), a continuous click operation (i.e. an operation of clicking a preset number of times within a preset click time), etc.

[0089] In the embodiment of the application, when the target online document is opened (i.e. displayed), the document content in the target online document can be displayed, and the first screen document content in the target online document is displayed in the document display area, as shown in Figure 3a Further, if the target online document is deleted, when the target online document is opened, a document deletion prompt can be displayed, as shown in Figure 3j It should be noted that, Figure 3j The figure only exemplarily shows the display of the document deletion prompt, and the application is not limited thereto.

[0090] The embodiment of the present application can determine the target online document to be displayed in the document display area, send a first acquisition request about the first-screen document content in the target online document to the target server, the first-screen document content being the document content displayed in the document display area when the target online document is opened, then acquire the first-screen document content fed back by the target server in response to the first acquisition request, and cache and store the first-screen document content locally as local content, so as to display the target online document and display the target online document according to the local content in the document display area, which can effectively improve the efficiency of displaying the target online document. It can be seen that the embodiment of the present application can acquire the first-screen document content in the target online document before displaying the target online document to store as local content, thereby improving the efficiency and experience of using the target online document by the user and improving the user stickiness. Moreover, the embodiment of the present application can acquire the first-screen document content in the target online document based on the first acquisition request only, without acquiring the document content other than the first-screen document content in the target online document, so as to achieve the purpose of flow control, which can ensure that the user can quickly see the corresponding first-screen document content when opening the target online document, and reduce unnecessary acquisition of document content when the target online document is not displayed, that is, unnecessary data acquisition can be saved, thereby effectively saving traffic and avoiding resource waste.

[0091] Please refer to Figure 4 is a flowchart of another document display method provided by the embodiment of the present application. The document display method can be executed by the computer device (terminal or server) mentioned above, or can be executed by the client in the computer device. For convenience of description, the computer device is taken as an example to describe the document display method in the following; please refer to Figure 4 When the number of target online documents is multiple, the document display method can include the following steps S401-S404:

[0092] S401, determining a target online document to be displayed in a document display area.

[0093] It should be understood that when the number of target online documents is multiple, the computer device can determine each target online document to be displayed in the document display area, based on which each target online document is an online document possibly opened by the user, that is, each target online document is an online document possibly opened, and the first-screen document content in each target online document is to be displayed, and the document content in each target online document is stored in the target server.

[0094] S402, acquiring the document identifier of each target online document respectively, and adding the acquired document identifier to a resource request queue, the resource request queue arranging the acquired document identifiers in sequence.

[0095] It should be noted that after each target online document to be displayed in the document display area is determined, the computer device can initiate a pre-pull operation for the first-screen document content in each target online document, i.e., a document first-screen data pulling operation, to trigger the execution of the document identifier acquisition of each target online document respectively.

[0096] Optionally, the computer device can include a document data management module. For any acquired document identifier, after the any document identifier is acquired, a pre-pull operation for the first-screen document content in the target online document corresponding to the any document identifier (i.e., a document first-screen data pulling operation) can be initiated, that is, a pre-pull document data request can be initiated to the document data management module using the any document identifier to request pre-pull data, so as to add the any document identifier to the resource request queue (i.e., the pre-pull document data queue), as shown in Figure 5a

[0097] Specifically, when the acquired document identifier is added to the resource request queue, for any acquired document identifier, the computer device can perform frequency limiting detection on the acquisition of the first-screen document content in the target online document corresponding to the any document identifier; and the frequency limiting detection is used to determine whether the any document identifier already exists in the resource request queue; based on this, if the frequency limiting detection is passed, the any document identifier is added to the resource request queue.

[0098] In an implementation manner, when the acquisition of the first-screen document content in the target online document corresponding to any document identifier is subjected to frequency limiting detection, the computer device can determine that the acquisition of the first-screen document content in the target online document corresponding to the any document identifier passes the frequency limiting detection when the any document identifier is not located in the resource request queue, i.e., it is determined that the frequency limiting detection is passed; that is, before the any document identifier is added to the resource request queue, it can be judged whether the any document identifier is already included in the resource request queue, if the any document identifier is not included in the resource request queue, it is determined that the acquisition of the first-screen document content in the target online document corresponding to the any document identifier passes the frequency limiting detection; if the any document identifier is already included in the resource request queue, it is determined that the acquisition of the first-screen document content in the target online document corresponding to the any document identifier does not pass the frequency limiting detection.

[0099] ​In another implementation, when performing the frequency-limiting detection on the acquisition of the first-screen document content in the target online document corresponding to any document identifier, if the any document identifier is not located in the resource request queue and the local content of the target online document corresponding to the any document identifier fails the validity determination (i.e., in the case where the local content is determined to be expired), it can be determined that the acquisition of the first-screen document content in the target online document corresponding to the any document identifier passes the frequency-limiting detection. In this case, if the any document identifier is not located in the resource request queue, the local content of the target online document corresponding to the any document identifier needs to be determined for validity, and if the local content fails the validity determination (i.e., the local content is determined to be expired), it is determined that the acquisition of the first-screen document content in the target online document corresponding to the any document identifier passes the frequency-limiting detection, and then the any document identifier is added to the resource request queue, as shown in FIG. 8. Figure 5b

[0100] In this case, if the computer device manages the resource request queue through the document data management module, the computer device can process the frequency of requests, redundancy and cache work through the document data management module, that is, the computer device can add the document identifier that passes the frequency-limiting detection to the resource request queue through the document data management module to control the frequency of requests for the first-screen document content in the corresponding target online document and avoid the occurrence of redundant document identifiers in the resource request queue, thereby avoiding repeated requests for the first-screen document content in the target online document corresponding to the same document identifier at the same system time, and also avoiding frequent requests for the local content that passes the validity determination (i.e., the first-screen document content that is not expired).

[0101] It can be understood that when determining the validity of the local content of the target online document corresponding to any document identifier, the local content can be retrieved according to the any document identifier to determine the validity of the local content; specifically, the document identifier can be used as the Key to retrieve the corresponding local content according to the above data structure. In this case, the expiration time can be determined based on the corresponding valid duration (i.e., expire_time) and the receiving time in DocPrepareRspItem; accordingly, if the current system time has exceeded the expiration time, it can be determined that the corresponding local content fails the validity determination; or if the corresponding local content is not found based on the retrieval of the any document identifier, i.e., the corresponding local content is not found in the local cache, it can be determined that the corresponding local content fails the validity determination; it should be understood that if the current system time has not exceeded the expiration time, it can be determined that the corresponding local content passes the validity determination.

[0102] ​The receiving time of any local content can refer to the system time when the first-screen document content in the target online document is received, or the system time when the obtained first-screen document content is stored in the local cache to obtain the local content, and the like. The application does not limit this. Correspondingly, the expiration time can be calculated and stored in the above data structure when the corresponding first-screen document content is stored, and based on this, the expiration time of the corresponding local content can be obtained from the local cache to perform validity discrimination when performing validity discrimination. The expiration time can also be determined when performing validity discrimination, which is not limited by the application.

[0103] Further, after adding the document identifier to the resource request queue, the next signaling scheduling to initiate the first acquisition request to the target server can be waited.

[0104] Correspondingly, the obtained document identifier is added to the resource request queue according to a target order, which can be an order obtained by arranging the display order of the document identifier, or an order obtained by arranging the time of arrival or addition to the resource request queue, which is not limited by the application. Based on this, the computer device can trigger the timer to perform timing processing after the first document identifier is added to the resource request queue, to obtain the timing result of adding the document identifier in the resource request queue; then, when the time length indicated by the timing result reaches the target time length, the execution of sending the resource request queue as the first acquisition request to the target server is triggered.

[0105] The target time length can be set according to experience, or set according to actual needs, such as 500ms (milliseconds) and 600ms, and the like, which is not limited by the application.

[0106] It should be noted that the timing method of the above-mentioned timer can be forward timing or countdown, which is not limited by the application. If the timing method of the timer is forward timing, the timing result is the time length when the timer is triggered, that is, the difference between the timer triggering time and the current system time, and correspondingly, the time length indicated by the timing result is equal to the timing result. If the timing method of the timer is countdown (the timer with countdown timing method can also be called timer), the timing result refers to the time length required to reach the target time length at the current system time, and correspondingly, the time length indicated by the timing result is the difference between the target time length and the timing result.

[0107] For example, if the timer is counting in a forward direction, and assuming the target duration is 500 ms, at the current system time, the counting result is 400 ms, at this time, the counting result indicates a duration of 400 ms; further, when the counting result is 500 ms, it can be determined that the duration indicated by the counting result reaches the target duration. If the timer is counting in a reverse direction, and at the current system time, assuming the counting result is 100 ms, at this time, the counting result indicates a duration of 400 ms; further, when the counting result is 0, it can be determined that the duration indicated by the counting result reaches the target duration.

[0108] It should be understood that each time a document identifier is added to the resource request queue, i.e., each time a pre-pull behavior enters the queue, it can be determined whether to trigger the start of the timer; if the timer has been triggered (i.e., has been started), the document identifier can be added to the resource request queue; if the timer has not been triggered (i.e., before the first document identifier is added to the resource request queue), after the first document identifier is added, the timer can be triggered for counting processing, as shown in Figure 5c .

[0109] It should be noted that the counting logic of the timer is to perform a background request once according to the target duration, and accordingly, after triggering the timer for counting processing each time, and when the duration indicated by the counting result reaches the target duration, the first acquisition request is executed once, the timer can be closed, i.e., the counting processing of the timer can be stopped. In this case, the resource request queue can again trigger the timer for counting processing after the first document identifier is added next time.

[0110] S403, sending the resource request queue to the target server as the first acquisition request.

[0111] In the embodiments of the present application, based on the batch request protocol, the first acquisition request for the first screen document content in the target online document corresponding to each document identifier included in the resource request queue can be sent to the target server, so that the first screen document content accumulated in the target online document corresponding to each document identifier included in the resource request queue within the target duration is batch requested. The batch request protocol is as follows:

[0112]

[0113] The batch request protocol supports requesting the first screen document content in multiple target online documents at a time, and after the request is completed, the document identifiers in the current resource request queue can be cleaned up.

[0114] Specifically, after the computer device sends the resource request queue to the target server as the first acquisition request, when it is determined that the target server responds to the first acquisition request, the document identifiers in the resource request queue can be cleared.

[0115] S404, obtaining the first-screen document content fed back by the target server in response to the first obtaining request, and caching and storing the first-screen document content locally as local content.

[0116] In the embodiments of the present application, the computer device can obtain the first-screen document content in the target online document based on the response protocol to update the local content corresponding to each document identifier in the resource request queue. The response protocol is as follows:

[0117]

[0118] The response protocol supports responding to the first obtaining request about the first-screen document content in multiple target online documents at one time.

[0119] S405, displaying the target online document and displaying the target online document according to the local content in the document display area.

[0120] It should be understood that the displayed target online document can be any one of the multiple target online documents. Specifically, when a display operation for any one of the multiple target online documents is detected, the displayed target online document can be determined to be the target online document (i.e., the target online document acted on by the display operation), so that the corresponding target online document is displayed.

[0121] It should be noted that when the target online document is displayed according to the local content in the document display area, the computer device can display the local content in the document display area and send a second obtaining request to the target server. Further, other document content fed back by the target server in response to the second obtaining request can be obtained to display the other document content in the document display area. The other document content refers to the document content in the target online document other than the first-screen document content. Based on this, the computer device can first load the local content to enable the user to quickly see the corresponding document content (i.e., the first-screen document content in the target online document).

[0122] Optionally, the second obtaining request can also be used to obtain all the document content in the target online document from the target server. In this case, the computer device can obtain the document content in the target online document fed back by the target server in response to the second obtaining request, and the document content in the target online document includes the other document content.

[0123] It should be noted that after the local content is displayed, the computer device can display the other document content in the document display area when a content update operation for the document display area is detected.

[0124] In a specific implementation, when the computer device displays the local content in the document display area, the computer device can acquire the valid duration of the local content, and perform validity discrimination on the local content according to the valid duration. Based on this, when the local content passes the validity discrimination, the computer device displays the local content in the document display area. Correspondingly, when the local content does not pass the validity discrimination, the computer device can reacquire the first-screen document content in the target online document from the target server, and display the reacquired first-screen document content as the local content in the document display area. In this case, the computer device can perform validity discrimination on the local content according to the receiving time of the local content and the valid duration. The valid duration can be stored in the local cache, that is, the computer device can acquire the valid duration of the local content in the local cache.

[0125] It should be noted that when the local content does not pass the validity discrimination (that is, the current system time has exceeded the expiration time, or the corresponding local content is not queried in the local cache), it can be determined that the local content has expired, and a third acquisition request is sent to the target server to reacquire the first-screen document content in the target online document from the target server. The third acquisition request can be used to acquire the document content (that is, all the document content in the target online document) in the target online document from the target server, and the document content in the target online document includes the corresponding first-screen document content.

[0126] Alternatively, the third acquisition request described above can be used to acquire the first-screen document content in the target online document from the target server, that is, only used to acquire the first-screen document content in the target online document from the target server. In this case, the second acquisition request can be sent to the target server again to acquire other document content from the target server while the first-screen document content is displayed, so as to display the other document content in the document display area, and the like.

[0127] It should be understood that the processes of acquiring the corresponding document content based on the second acquisition request and the third acquisition request can be referred to as processes of requesting live document data (that is, live data). The live document data refers to the document content acquired from the target server in real time based on the user's demand for processing the online document. In this case, the computer device sends the second acquisition request or the third acquisition request to the target server only when the document content needs to be refreshed (that is, the first-screen document content is displayed, or the document display area is updated to display other document content), and then refreshes the current document page based on the acquired document content, that is, refreshes the current document display area. In addition, subsequent operations of the user in the document are operations on the live data, and the operations on the live data can be understood as operations on the document content acquired from the target server in real time. Therefore, this process can be understood as acquiring the document content from the target server only when it is determined that the user needs to process the document.

[0128] For example, as shown in Figure 5d shown, when a user opens a target online document, i.e., performs a display operation on the target online document, it can be detected in the local cache whether the corresponding local content has expired, i.e., the local content is subjected to validity discrimination; if not expired (i.e., the local content passes the validity discrimination), the local content is loaded to display the local content, i.e., the first-screen document content in the target online document is displayed, and the live document data is requested based on the second acquisition request to refresh the document content (i.e., the document display area is updated to display other document content); if expired (i.e., the local content does not pass the validity discrimination), the live document data is requested based on the third acquisition request to refresh the document content (i.e., the first-screen document content is displayed).

[0129] It should be noted that, Figure 5d only a flow diagram for displaying document content of an online document is exemplarily shown, and the present application is not limited thereto; for example, if the local content passes the validity discrimination, the computer device needs to detect a content update operation on the document display area before the live document data is requested based on the second acquisition request.

[0130] The embodiments of the present application can determine the target online documents to be displayed in the document display area, acquire the document identifiers of each target online document, and add the acquired document identifiers to the resource request queue; then, the resource request queue is sent as the first acquisition request to the target server to acquire the first-screen document content in each target online document from the target server, thereby realizing batch request of the first-screen document content in each target online document; further, the target online documents can be displayed, and the target online documents are displayed in the document display area according to the corresponding local content, which effectively improves the efficiency of displaying the target online documents and improves the user experience. In addition, the embodiments of the present application can detect the frequency limitation of acquiring the first-screen document content in the target online document corresponding to each document identifier, avoid the corresponding first-screen document content being frequently requested, and acquire only the corresponding first-screen document content based on the first acquisition request, which can effectively save traffic; it can be seen that the embodiments of the present application can capture the timing of using online documents by the user, i.e., automatically identify the scenario in which the user is likely to open the online document, acquire the first-screen document content of the target online document that the user is likely to access, and intelligently control the request mode and frequency, thereby improving the visual experience of the user while ensuring the performance experience.

[0131] Based on the description of the related embodiments of the above document display method, the embodiments of the present application further propose a document display apparatus, which can be a computer program (including program code) running in a computer device. The document display apparatus can perform the document display method shown in Figure 2 or Figure 4 ; please refer toFigure 6 The document display device can run the following units:

[0132] a processing unit 601 configured to determine a target online document to be displayed in a document display area, and send a first acquisition request about a first-screen document content in the target online document to a target server; the first-screen document content is document content displayed in the document display area when the target online document is opened;

[0133] The processing unit 601 is further configured to acquire the first-screen document content fed back by the target server in response to the first acquisition request, and cache and store the first-screen document content locally as local content;

[0134] an output unit 602 configured to display the target online document, and display the target online document according to the local content in the document display area.

[0135] In an embodiment, when the output unit 602 displays the target online document according to the local content in the document display area, the output unit 602 can be specifically configured to:

[0136] display the local content in the document display area, and send a second acquisition request to the target server;

[0137] acquire other document content fed back by the target server in response to the second acquisition request, to display the other document content in the document display area; the other document content refers to document content in the target online document other than the first-screen document content.

[0138] In another embodiment, when the output unit 602 displays the local content in the document display area, the output unit 602 can be specifically configured to:

[0139] acquire an effective time length of the local content, and perform validity discrimination on the local content according to the effective time length; when the local content passes the validity discrimination, display the local content in the document display area;

[0140] when the local content fails the validity discrimination, reacquire the first-screen document content in the target online document from the target server, and display the reacquired first-screen document content as the local content in the document display area.

[0141] In another embodiment, if the number of target online documents is multiple; when the processing unit 601 sends the first acquisition request about the first-screen document content in the target online document to the target server, the processing unit 601 can be specifically configured to:

[0142] acquire a document identifier of each target online document respectively, and add the acquired document identifier to a resource request queue, the resource request queue being arranged in sequence according to the acquired document identifier;

[0143] send the resource request queue as a first acquisition request to the target server.

[0144] In another implementation, the processing unit 601, when adding the acquired document identifier to the resource request queue, can be specifically configured to:

[0145] perform a frequency limiting detection on acquisition of the first screen document content in the target online document corresponding to any document identifier; the frequency limiting detection is used to determine whether the any document identifier already exists in the resource request queue;

[0146] If the frequency limiting detection is passed, the any document identifier is added to the resource request queue.

[0147] In another implementation, the processing unit 601, when performing the frequency limiting detection on acquisition of the first screen document content in the target online document corresponding to the any document identifier, can be specifically configured to:

[0148] when the any document identifier is not located in the resource request queue, it is determined that the acquisition of the first screen document content in the target online document corresponding to the any document identifier passes the frequency limiting detection;

[0149] or, when the any document identifier is not located in the resource request queue, and the local content of the target online document corresponding to the any document identifier does not pass the validity discrimination, it is determined that the acquisition of the first screen document content in the target online document corresponding to the any document identifier passes the frequency limiting detection.

[0150] In another implementation, after the processing unit 601 sends the resource request queue as the first acquisition request to the target server, the processing unit 601 can be further configured to:

[0151] when it is determined that the target server responds to the first acquisition request, clear the document identifier in the resource request queue.

[0152] In another implementation, the acquired document identifier is added to the resource request queue in a target order; the processing unit 601 can be further configured to:

[0153] after the resource request queue is added with the first document identifier, trigger a timer to perform timing processing, and obtain a timing result of adding the document identifier in the resource request queue;

[0154] When the duration indicated by the timing result reaches the target duration, execution is triggered to send the resource request queue as the first acquisition request to the target server.

[0155] According to one embodiment of this application, Figure 2 or Figure 4 Each step involved in the method shown can be derived from... Figure 6 This is performed by the individual units in the document display device shown. For example, Figure 2 Both steps S201 and S202 shown can be performed by Figure 6 The processing unit 601 shown executes the step S203, which can be performed by... Figure 6 The output unit 602 shown is executed. For example, Figure 4 Steps S401-S404 shown can all be performed by Figure 6 The processing unit 601 shown executes the step S405, which can be performed by... Figure 6 The output unit 602 shown executes, etc.

[0156] According to another embodiment of this application, Figure 6 The various units in the document display device shown can be individually or entirely merged into one or more other units, or some of the units can be further divided into multiple functionally smaller units. This achieves the same operation without affecting the technical effects of the embodiments of this application. The above-mentioned units are based on logical function division. In practical applications, the function of one unit can also be implemented by multiple units, or the function of multiple units can be implemented by one unit. In other embodiments of this application, the document display device may also include other units. In practical applications, these functions can also be implemented with the assistance of other units, and can be implemented collaboratively by multiple units.

[0157] According to another embodiment of this application, the following can be achieved by running on a general-purpose computing device, such as a computer, which includes processing elements and storage elements such as a central processing unit (CPU), random access memory (RAM), and read-only memory (ROM), a device capable of performing operations such as... Figure 2 or Figure 4 The computer program (including program code) for each step involved in the corresponding method shown, to construct such... Figure 6 The document display device shown herein, and the document display method for implementing the embodiments of this application, are described. The computer program may be recorded on, for example, a computer storage medium, loaded onto the aforementioned computing device via the computer storage medium, and run therein.

[0158] The embodiment of the present application can determine the target online document to be displayed in the document display area, send a first acquisition request about the first-screen document content in the target online document to the target server, the first-screen document content being the document content displayed in the target online document in the document display area when the target online document is opened, then acquire the first-screen document content fed back by the target server in response to the first acquisition request, and cache and store the first-screen document content locally as local content, so as to display the target online document and display the target online document according to the local content in the document display area, which can effectively improve the efficiency of displaying the target online document. It can be seen that the embodiment of the present application can acquire the first-screen document content in the target online document before displaying the target online document to store as local content, thereby improving the efficiency and experience of using the target online document by the user and improving the user stickiness. Moreover, the embodiment of the present application can acquire the first-screen document content in the target online document based on the first acquisition request only, without acquiring the document content other than the first-screen document content in the target online document, so as to achieve the purpose of flow limiting, which can ensure that the user can quickly see the corresponding first-screen document content when opening the target online document, and reduce unnecessary acquisition of document content when the target online document is not displayed, that is, unnecessary data acquisition can be saved, thereby effectively saving the flow and avoiding resource waste.

[0159] Based on the description of the method embodiment and the device embodiment, the embodiment of the present application further provides a computer device. Please refer to Figure 7 The computer device at least includes a processor 701, an input interface 702, an output interface 703, and a computer storage medium 704. The processor 701, the input interface 702, the output interface 703, and the computer storage medium 704 in the computer device can be connected through a bus or other means.

[0160] The computer storage medium 704 can be stored in the memory of the computer device, and is used to store a computer program including program instructions. The processor 701 is used to execute the program instructions stored in the computer storage medium 704. The processor 701 (or CPU (Central Processing Unit, central processor)) is the computing core and control core of the computer device, and is adapted to implement one or more instructions, and is specifically adapted to load and execute one or more instructions to implement a corresponding method flow or a corresponding function. In one embodiment, the processor 701 of the embodiment of the present application can be used to perform a series of document display, and specifically includes: determining a target online document to be displayed in a document display area, and sending a first acquisition request about first-screen document content in the target online document to a target server; the first-screen document content is document content displayed in the document display area when the target online document is opened; acquiring first-screen document content fed back by the target server in response to the first acquisition request, and locally caching and storing the first-screen document content as local content; displaying the target online document, and displaying the target online document in the document display area according to the local content, and the like.

[0161] The embodiment of the present application further provides a computer storage medium (Memory). The computer storage medium is a memory device in a computer device, and is used to store programs and data. It can be understood that the computer storage medium herein can include an internal storage medium in the computer device, and of course can include an extended storage medium supported by the computer device. The computer storage medium provides a storage space, and the storage space stores an operating system of the computer device. In addition, one or more instructions adapted to be loaded and executed by the processor are stored in the storage space, and the instructions can be one or more computer programs (including program codes). It should be noted that the computer storage medium herein can be a high-speed RAM memory, or a non-volatile memory such as at least one disk memory. Optionally, the computer storage medium can also be at least one computer storage medium located away from the processor. In one embodiment, one or more instructions stored in the computer storage medium can be loaded and executed by the processor to implement the above-mentioned embodiments of the document display method. Figure 2 or Figure 4 The various method steps in the embodiments of the document display method shown.

[0162] The embodiment of the present application can determine the target online document to be displayed in the document display area, send a first acquisition request about the first-screen document content in the target online document to the target server, the first-screen document content being the document content displayed in the target online document in the document display area when the target online document is opened, then acquire the first-screen document content fed back by the target server in response to the first acquisition request, and cache and store the first-screen document content locally as local content, so as to display the target online document and display the target online document according to the local content in the document display area, which can effectively improve the efficiency of displaying the target online document. It can be seen that the embodiment of the present application can acquire the first-screen document content in the target online document before displaying the target online document to store as local content, thereby improving the efficiency and experience of using the target online document by the user and improving the user stickiness. Moreover, the embodiment of the present application can acquire the first-screen document content in the target online document based on the first acquisition request only, without acquiring the document content other than the first-screen document content in the target online document, so as to achieve the purpose of flow limiting, which can ensure that the user can quickly see the corresponding first-screen document content when opening the target online document, and reduce unnecessary acquisition of document content when the target online document is not displayed, that is, unnecessary data acquisition can be saved, thereby effectively saving the flow and avoiding resource waste.

[0163] It should be noted that, according to an aspect of the present application, a computer program product or computer program is also provided, which includes computer instructions stored in a computer storage medium. The processor of the computer device reads the computer instructions from the computer storage medium, and the processor executes the computer instructions to enable the computer device to perform the above-mentioned Figure 2 or Figure 4 the various optional manners of the document display method embodiment aspects shown in the document display method embodiments.

[0164] It should be understood that the above disclosure is only the preferred embodiment of the present application, and of course cannot limit the scope of the rights of the present application, so the equivalent changes made according to the claims of the present application still fall within the scope covered by the present application.

Claims

1. A document display method characterized by, The method comprises the following steps: determining a target online document to be displayed in a document display area, and sending a first acquisition request about first page document content in the target online document to a target server; the first page document content is document content displayed in the document display area when the target online document is opened; acquiring first page document content fed back by the target server in response to the first acquisition request, and caching the first page document content locally as local content; when a display operation on the target online document is detected, displaying the target online document and displaying the target online document according to the local content in the document display area; the step of displaying the target online document and displaying the target online document according to the local content in the document display area comprises the following steps: displaying the local content in the document display area, and sending a second acquisition request to the target server to acquire other document content fed back by the target server in response to the second acquisition request, so as to display the other document content in the document display area; 2. The method of claim 1, wherein, the other document content refers to document content in the target online document other than the first page document content. The step of displaying the local content in the document display area comprises the following steps: acquiring an effective time length of the local content, and performing validity discrimination on the local content according to the effective time length; when the local content passes the validity discrimination, displaying the local content in the document display area; 3. The method of claim 2, wherein, when the local content does not pass the validity discrimination, reacquiring first page document content in the target online document from the target server, and displaying the reacquired first page document content as the local content in the document display area. If the number of target online documents is multiple; the step of sending a first acquisition request about first page document content in the target online document to a target server comprises the following steps: respectively acquiring document identifiers of each target online document, and adding the acquired document identifiers to a resource request queue; the resource request queue arranges the acquired document identifiers in sequence; 4. The method of claim 3, wherein, sending the resource request queue as a first acquisition request to the target server. The step of adding the acquired document identifiers to the resource request queue comprises the following steps: for any document identifier acquired, performing frequency limiting detection on acquisition of first page document content in a target online document corresponding to the any document identifier; the frequency limiting detection is used to determine whether the any document identifier already exists in the resource request queue; 5. The method of claim 4, wherein, if the frequency limiting detection is passed, the any document identifier is added to the resource request queue. The step of performing frequency limiting detection on acquisition of first page document content in a target online document corresponding to the any document identifier comprises the following steps: when the any document identifier is not located in the resource request queue, it is determined that acquisition of first page document content in the target online document corresponding to the any document identifier passes the frequency limiting detection; Or, in the case that the any document identifier is not located in the resource request queue, and the corresponding target online document of the any document identifier does not have local content passing the validity judgment, it is determined that the acquisition of the first-screen document content in the target online document corresponding to the any document identifier passes the frequency limitation detection.

6. The method of claim 5, wherein, After the resource request queue is sent as the first acquisition request to the target server, the method further comprises: When it is determined that the target server responds to the first acquisition request, the document identifiers in the resource request queue are cleared.

7. The method of claim 3, wherein, The obtained document identifiers are added to the resource request queue in a target order; the method further comprises: After the first document identifier is added to the resource request queue, a timer is triggered to perform timing processing, and a timing result of adding the document identifiers in the resource request queue is obtained; When the time length indicated by the timing result reaches a target time length, the resource request queue is triggered to be sent as the first acquisition request to the target server.

8. A document display device characterized by comprising: Comprise: A processing unit is configured to determine a target online document to be displayed in a document display area, and send a first acquisition request about first-screen document content in the target online document to a target server; the first-screen document content is document content displayed in the document display area when the target online document is opened; The processing unit is further configured to acquire first-screen document content fed back by the target server in response to the first acquisition request, and cache and store the first-screen document content locally as local content; An output unit is configured to display the target online document when a display operation on the target online document is detected, and display the target online document in the document display area according to the local content; the displaying of the target online document in the document display area according to the local content comprises displaying the local content in the document display area, and sending a second acquisition request to the target server to acquire other document content fed back by the target server in response to the second acquisition request, so as to display the other document content in the document display area. The other document content refers to document content in the target online document other than the first-screen document content.

9. A computer device, comprising: The computer program is stored in the computer storage medium, and when executed by the processor, the computer program implements the method according to any one of claims 1-7.

10. A computer storage medium, characterized in that, The computer storage medium stores a computer program, and when the computer program is executed by a processor, the computer program implements the method according to any one of claims 1-7.

11. A computer program product, characterised in that, The computer program is stored in the computer storage medium, and when executed by the processor, the computer program implements the method according to any one of claims 1-7.

Citation Information

Patent Citations

  • Document display method and device and electronic equipment

    CN113051505A