CN111581556A - Page data processing method and device, electronic equipment and readable medium - Google Patents

Page data processing method and device, electronic equipment and readable medium Download PDF

Info

Publication number
CN111581556A
CN111581556A CN202010344959.2A CN202010344959A CN111581556A CN 111581556 A CN111581556 A CN 111581556A CN 202010344959 A CN202010344959 A CN 202010344959A CN 111581556 A CN111581556 A CN 111581556A
Authority
CN
China
Prior art keywords
data
page
multimedia
multimedia data
response
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
Application number
CN202010344959.2A
Other languages
Chinese (zh)
Other versions
CN111581556B (en
Inventor
易华琦
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing ByteDance Network Technology Co Ltd
Original Assignee
Beijing ByteDance Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing ByteDance Network Technology Co Ltd filed Critical Beijing ByteDance Network Technology Co Ltd
Priority to CN202010344959.2A priority Critical patent/CN111581556B/en
Publication of CN111581556A publication Critical patent/CN111581556A/en
Application granted granted Critical
Publication of CN111581556B publication Critical patent/CN111581556B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking

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 provides a page data processing method and device, electronic equipment and a readable medium, and relates to the technical field of information processing. The method comprises the following steps: sending a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indication information, and receiving a first response data packet returned by the server when the indication information indicates that text data and multimedia data are acquired synchronously; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; analyzing the first response data packet to obtain analysis position information; and analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data. According to the technical scheme, the terminal can load the text data and the multimedia data only by requesting the server for one time, so that the loading delay caused by repeated data requests is avoided, and the fluency of user experience is improved.

Description

Page data processing method and device, electronic equipment and readable medium
Technical Field
The present disclosure relates to the field of information processing technologies, and in particular, to a page data processing method and apparatus, an electronic device, and a readable medium.
Background
With the rapid development of computer technology and communication technology, the internet is widely used, and the life style of people is changed. The user can access the internet through the terminal equipment, browse news, shop, transact various services, publish information on a social platform and the like, and the convenience and richness of daily life are improved.
For the pages presented to the user by the terminal device, for example, the pages of an Application (APP), the pages of a web page, and the like, each page contains rich elements including text data, picture data, web page links, video data, audio data, and the like. Most APP usually give users priority to loading and displaying some text contents based on content classification at present, so that the users can see webpage contents in time, but content loading delay can occur under many conditions, so that the webpage display is not smooth enough, and the phenomenon of rendering blocking can occur in severe cases.
Disclosure of Invention
The disclosure provides a page data processing method, a page data processing device, an electronic device and a readable medium, which are used for solving the problems in the prior art.
In a first aspect, a method for processing page data is provided, where the method includes:
sending a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
when the indication information indicates that the text data and the multimedia data are synchronously acquired, receiving a first response data packet returned by the server based on the page identification and the indication information; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
analyzing the first response data packet to obtain analysis position information;
and analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data.
In a second aspect, a method for processing page data is provided, and the method includes:
receiving a page data acquisition request sent by a terminal, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode;
when the indication information indicates that the text data and the multimedia data are synchronously acquired, determining a first response data packet based on the page identification and the indication information, wherein the first response data packet comprises the first page data and the analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
and sending the first response data packet to the terminal so that the terminal analyzes the first response data packet to obtain analysis position information, and analyzing the first response data packet based on the analysis position information to obtain and display first page data.
In a third aspect, there is provided a page data processing apparatus, including:
the system comprises a sending module, a receiving module and a sending module, wherein the sending module is used for sending a page data acquisition request to a server, the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
the receiving module is used for receiving a first response data packet returned by the server based on the page identifier and the indicating information when the indicating information indicates that the text data and the multimedia data are synchronously acquired; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
the analysis module is used for analyzing the first response data packet to obtain analysis position information;
and the display module is used for analyzing the first response data packet to obtain first page data based on the analysis position information and displaying the first page data.
In a fourth aspect, there is provided a page data processing apparatus, including:
the receiving module is used for receiving a page data acquisition request sent by a terminal, wherein the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
the determining module is used for determining a first response data packet based on the page identifier and the indicating information when the indicating information indicates that the text data and the multimedia data are synchronously acquired, wherein the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
and the sending module is used for sending the first response data packet to the terminal so that the terminal analyzes the first response data packet to obtain analysis position information, and analyzes the first response data packet based on the analysis position information to obtain and display the first page data.
In a fifth aspect, the present disclosure provides an electronic device comprising:
one or more processors;
a memory;
one or more application programs, wherein the one or more application programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: and executing the corresponding operation of the page data processing method as shown in the first aspect or the second aspect of the disclosure.
In a sixth aspect, the present disclosure provides a computer-readable medium for storing computer instructions which, when run on a computer, cause the computer to perform the page data processing method as shown in the first or second aspect of the present disclosure.
The technical scheme provided by the disclosure has the following beneficial effects:
the page data processing method, the page data processing device, the electronic device and the readable medium provided by the embodiment of the disclosure send a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode; when the indication information indicates that the text data and the multimedia data are synchronously acquired, receiving a first response data packet returned by the server based on the page identification and the indication information; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data; analyzing the first response data packet to obtain analysis position information; and analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data. According to the technical scheme, the terminal sends the data acquisition request to the server once, so that the text data and the multimedia data can be obtained, the text data and the multimedia data are analyzed and displayed according to the analysis position information in the response data packet sent by the server, delay caused by the fact that the text data and the multimedia data need to be acquired respectively through two data acquisition requests in the initial page rendering process is avoided, and smoothness of user experience is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure, the drawings used in the description of the embodiments of the present disclosure will be briefly described below.
Fig. 1 is a flowchart of a page data processing method according to an embodiment of the present disclosure;
fig. 2 is a flowchart of a page data processing method according to an embodiment of the disclosure;
FIG. 3 is a diagram illustrating a prior art method for displaying multimedia information via a bitmap;
FIG. 4 is a diagram illustrating a multimedia information replacing occupied bitmap displayed in a page according to the prior art;
FIG. 5 is a diagram illustrating a Preload data structure provided by an embodiment of the present disclosure;
fig. 6 is a schematic diagram illustrating a process of data transmission and reception between a terminal and a server in the prior art;
fig. 7 is a schematic diagram of a process of data transceiving between a terminal and a server according to an embodiment of the present disclosure;
fig. 8 is a schematic structural diagram of a page data processing apparatus according to an embodiment of the present disclosure;
fig. 9 is a schematic structural diagram of a page data processing apparatus according to an embodiment of the present disclosure;
fig. 10 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
Detailed Description
Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure are shown in the drawings, it is to be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the disclosure are for illustration purposes only and are not intended to limit the scope of the disclosure.
It should be understood that the various steps recited in the method embodiments of the present disclosure may be performed in a different order, and/or performed in parallel. Moreover, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the present disclosure is not limited in this respect.
The term "include" and variations thereof as used herein are open-ended, i.e., "including but not limited to". The term "based on" is "based, at least in part, on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Relevant definitions for other terms will be given in the following description.
It should be noted that the terms "first", "second", and the like in the present disclosure are only used for distinguishing the devices, modules or units, and are not used for limiting the devices, modules or units to be different devices, modules or units, and also for limiting the sequence or interdependence relationship of the functions executed by the devices, modules or units.
It is noted that references to "a", "an", and "the" modifications in this disclosure are intended to be illustrative rather than limiting, and that those skilled in the art will recognize that "one or more" may be used unless the context clearly dictates otherwise.
The names of messages or information exchanged between devices in the embodiments of the present disclosure are for illustrative purposes only, and are not intended to limit the scope of the messages or information.
The following describes the technical solutions of the present disclosure and how to solve the above technical problems in specific embodiments. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present disclosure will be described below with reference to the accompanying drawings.
Fig. 1 is a flowchart of a page data processing method provided in an embodiment of the present disclosure, and as shown in fig. 1, the method may include:
step S101, sending a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
the execution main body of the embodiment of the disclosure is a terminal, and when the terminal receives a trigger action of refreshing a page by a user or the terminal updates page data, the terminal sends a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indication information, and the page identifier is unique identification information of the page which is distinguished from other pages; the indication information is used to indicate a data acquisition mode in which the terminal requests data from the server, for example, a private protocol may be established between the terminal and the server, the private protocol may specify the data acquisition mode, and whether both communication parties support the data acquisition mode specified by the private protocol can be determined by verifying the indication information, and the specific data acquisition mode may be set according to specific needs. The server can determine to return corresponding data to the terminal based on the indication information in the page data acquisition request sent by the terminal. The indication information may specifically be a certain field in the page data obtaining request.
The page data includes data displayed in the page, such as text data and multimedia data, and the multimedia data may include data in the page, such as pictures, videos, audios, and the like.
The page may include a page that is displayed to the user by the terminal device, for example, a page of an application APP, a page of a web page, and the like; the page identification is the unique identification information of the page corresponding to the data acquisition request. For example, when a user a logs in an APP of a news browsing class and clicks a tag of "domestic news" of the APP, the terminal requests page data of the "domestic news" from the server, and the request includes a page identifier of the "domestic news" page.
Step S102, when the indication information indicates that the text data and the multimedia data are synchronously acquired, receiving a first response data packet returned by the server based on the page identification and the indication information; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
specifically, after receiving the page data acquisition request, the server extracts and verifies the indication information from the page data acquisition request, determines the data acquisition mode of the terminal, and sends a first response data packet containing the first page data and the analysis position information of the first page data to the terminal when the indication information indicates that the text data and the multimedia data are acquired synchronously.
The first page data is acquired by the server based on the page identifier. The specific obtaining mode may include that the server queries corresponding page data in the database based on the page identifier, or requests corresponding first page data from other servers based on the page identifier.
The parsing position information of the first page data in the response packet may specifically include parsing start position information and parsing end position information, that is, a start position and an end position of the data in the first response packet.
In addition, when the indication information indicates that the metadata of the text data and the multimedia data is acquired, the method further includes:
receiving a second response data packet returned by the server based on the page identification and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of the entire multimedia data.
In practical application, when the indication information indicates to acquire the text data and the metadata of the multimedia data, the server returns a second response data packet containing the text data and the metadata of all the multimedia data to the terminal, and if the terminal needs to acquire the multimedia data, the terminal needs to send a data acquisition request to the server again through the metadata of all the multimedia data, and receives the multimedia data sent by the server according to the metadata of all the multimedia data.
The metadata of the multimedia data may include network links of pictures, videos, and audios, and information such as picture resolution, video definition, and audio duration.
Step S103, analyzing the first response data packet to obtain analysis position information;
the terminal analyzes the first response data packet received from the server to obtain the text data and the analysis position information of the first multimedia data in the response data packet.
And step S104, analyzing the first response data packet based on the analysis position information to obtain first page data and displaying the first page data.
Analyzing and displaying the text data based on the analysis starting position information and the analysis ending position information of the text data received from the server in the first response data packet; and analyzing and displaying the first multimedia data based on the analysis starting position information and the analysis ending position information of the first multimedia data received from the server in the first response data packet.
The terminal analyzes and displays the text data and the multimedia data respectively according to the analysis position information, the text data can be analyzed and rendered firstly, then the multimedia data is analyzed and rendered, and then the multimedia data is displayed.
The first multimedia data sent by the server to the terminal may be all multimedia data of the corresponding page or part of multimedia data.
In one possible implementation, when the first response packet includes metadata of the multimedia data, the method further includes:
and acquiring second multimedia data based on the metadata of the multimedia data, wherein the second multimedia data is the remaining multimedia data corresponding to the page identifier except the first multimedia data.
In practical application, the server may send part of the multimedia data corresponding to the page identifier to the terminal, or may send all the multimedia data, optionally, the server may preset a threshold value for sending the data amount, when the data amount (which may include the sum of the data amounts of the text data and the multimedia data, or may only calculate the amount of the multimedia data) determined by the server based on the page identifier is greater than or equal to the preset threshold value, the server sends part of the multimedia data corresponding to the page identifier to the terminal, and subsequently sends the remaining part of the multimedia data, and if the data amount is less than the preset threshold value, sends all the multimedia data corresponding to the page identifier. If the server sends part of the multimedia data to the terminal, the remaining part of the multimedia data is needed to be acquired later. When the first response data packet includes the metadata of the multimedia data, it indicates that the first multimedia data sent by the server to the terminal is a part of the multimedia data corresponding to the page identifier, and not all multimedia data, and therefore, the remaining part of the multimedia data needs to be acquired based on the metadata of the multimedia data.
It should be noted that, the server determines to send all multimedia data or part of multimedia data to the terminal based on the sent data volume is only an optional manner, and may also determine whether to send all multimedia data to the terminal according to any other manner, such as loading performance of the terminal, speed of network transmission, and the like, which is not limited in this disclosure.
When the server sends part of multimedia data to the terminal, the metadata of the multimedia data, the text data and the part of multimedia data can be simultaneously sent to the terminal, the server can send the metadata of the remaining part of multimedia data which is not sent to the terminal, and the terminal obtains the remaining part of multimedia data based on the metadata of the remaining part of multimedia data; the metadata of the multimedia data may also be second metadata of the entire multimedia data, and the terminal may determine the metadata of the remaining part of the multimedia data that has not been transmitted by the server based on the second metadata.
The specific implementation mode that the terminal acquires the remaining multimedia data from the server is as follows:
in one possible implementation, when the metadata of the multimedia data includes first metadata of second multimedia data, acquiring the second multimedia data based on the first metadata includes:
sending a multimedia data acquisition request to a server, wherein the multimedia data acquisition request comprises first metadata;
and receiving second multimedia data sent by the server based on the first metadata.
In practical applications, specific ways for acquiring the remaining data may include two ways: one mode is that the server waits for the residual multimedia data sent according to the page data acquisition request sent by the terminal, and the residual multimedia data are rendered and displayed after being cached locally; the other mode is that a multimedia data acquisition request is sent to the server again, the request comprises the first metadata of the residual multimedia data, the server acquires the residual multimedia data according to the received first metadata of the residual multimedia data and sends the residual multimedia data to the terminal, and the terminal carries out rendering and display.
In the embodiment of the present disclosure, no matter the terminal waits for the server to send the remaining part of the multimedia data according to the previously sent page data acquisition request, or sends the multimedia data acquisition request to the server again to obtain the remaining part of the multimedia data, the difference from the prior art is that, since the terminal has already obtained part of the multimedia data, the obtained part of the multimedia data can be analyzed and displayed to the user according to the analysis position information, and the user does not need to wait too long, and the user browsing is not affected.
When the server sends all the metadata of the multimedia data to the terminal, the terminal can analyze and display the multimedia data based on all the metadata of the multimedia data, and the specific implementation mode is as follows:
in one possible implementation manner, when the metadata of the multimedia data is second metadata of all the multimedia data, the method further includes:
parsing second metadata from the first response data packet based on the parsed location information;
the parsed first multimedia data is determined based on the second metadata, and a multimedia data acquisition request is transmitted to the server based on metadata of a remaining portion of the multimedia data excluding the parsed first multimedia data.
In practical application, the terminal receives a first response data packet sent by the server, analyzes the first response data packet based on the analyzed position information, and stores the text data, the first multimedia data and the second metadata obtained by analysis into a specified storage space, wherein the specified storage space can comprise a local storage or an internal storage, and can also be cached into any area which can be read quickly in a subsequent process, and then rendering and displaying are carried out. When the multimedia data is displayed, the terminal can determine the parsed first multimedia data based on the second metadata, and for the remaining multimedia data without the designated storage space, the terminal can send a data acquisition request to the server again based on the metadata of the remaining multimedia data in the second metadata, acquire the remaining multimedia data and display the remaining multimedia data to the user. In the embodiment of the disclosure, the server does not need to determine the metadata of the remaining multimedia data, and directly sends the metadata of all the multimedia data to the terminal, and the terminal can acquire the remaining multimedia data from the server again at any time based on the received metadata of all the multimedia data, so that the multimedia data can be acquired more flexibly.
The page data processing method provided by the embodiment of the disclosure sends a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode; when the indication information indicates that the text data and the multimedia data are synchronously acquired, receiving a first response data packet returned by the server based on the page identification and the indication information; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data; analyzing the first response data packet to obtain analysis position information; and analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data. According to the technical scheme, the terminal sends the data acquisition request to the server once, so that the text data and the multimedia data can be obtained, the text data and the multimedia data are analyzed and displayed according to the analysis position information in the response data packet sent by the server, delay caused by the fact that the text data and the multimedia data are respectively acquired through two data acquisition requests in the initial page rendering process is avoided, and the fluency of user experience is improved.
Fig. 2 is a flowchart of a page data processing method provided in an embodiment of the present disclosure, and as shown in fig. 2, the method may include:
step S201, receiving a page data acquisition request sent by a terminal, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode;
the execution subject of the embodiment of the present disclosure is a server, and the server may be an application server corresponding to the APP, or may be a Web server. When a terminal receives a trigger action of refreshing a page by a user or the terminal updates page data, sending a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indication information, and the page identifier is unique identification information of the page which is distinguished from other pages; the indication information is used to indicate a data acquisition mode in which the terminal requests data from the server, for example, a private protocol may be established between the terminal and the server, the private protocol may specify the data acquisition mode, and whether both communication parties support the data acquisition mode specified by the private protocol can be determined by verifying the indication information, and the specific data acquisition mode may be set according to specific needs. The server can determine to return corresponding data to the terminal based on the indication information in the page data acquisition request sent by the terminal. The indication information may specifically be a field, a parameter or any other form of information.
The page data includes data displayed in the page, such as text data and multimedia data, and the multimedia data may include data in the page, such as pictures, videos, audios, and the like.
The page may include a page that is displayed to the user by the terminal device, for example, a page of an application APP, a page of a web page, and the like; the page identification is the unique identification information of the page corresponding to the data acquisition request. For example, when a user a logs in an APP of a news browsing class and clicks a tag of "domestic news" of the APP, the terminal requests page data of the "domestic news" from the server, and the request includes a page identifier of the "domestic news" page.
Step S202, when the indication information indicates that the text data and the multimedia data are synchronously acquired, determining a first response data packet based on the page identifier and the indication information, wherein the first response data packet comprises the first page data and the analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
specifically, after receiving the page data acquisition request, the server extracts and verifies the indication information from the page data acquisition request, determines the data acquisition mode of the terminal, and sends a response data packet containing the first page data and the analysis position information of the first page data to the terminal when the indication information indicates that the text data and the multimedia data are synchronously acquired.
The first page data is acquired by the server based on the page identifier. The specific obtaining mode may include that the server queries the corresponding first page data in the database based on the page identifier, or requests the corresponding first page data from other servers based on the page identifier.
The parsing position information of the first page data in the response packet may specifically include parsing start position information and parsing end position information, that is, a start position and an end position of the data in the response packet.
In addition, when the indication information indicates that the metadata of the text data and the multimedia data is acquired, the method further includes:
receiving a second response data packet returned by the server based on the page identification and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of the entire multimedia data.
In practical application, when the indication information indicates to acquire the text data and the metadata of the multimedia data, the server returns a second response data packet containing the text data and the metadata of all the multimedia data to the terminal, and if the terminal needs to acquire the multimedia data, the terminal needs to send a data acquisition request to the server again through the metadata of all the multimedia data, and receives the multimedia data sent by the server according to the metadata of all the multimedia data.
The metadata of the multimedia data may include network links of pictures, videos, and audios, and information such as picture resolution, video definition, and audio duration.
Step S203, the first response data packet is sent to the terminal, so that the terminal analyzes the first response data packet to obtain the analysis position information, and the first page data is obtained from the response data packet by analysis based on the analysis position information and is displayed.
The server sends the first response data packet to the terminal, the terminal analyzes the first response data packet to obtain analysis position information, and the text data is analyzed and displayed based on the analysis starting position information and the analysis ending position information of the text data in the response data packet; and analyzing and displaying the first multimedia data based on the analysis starting position information and the analysis ending position information of the first multimedia data received from the server in the first response data packet.
The terminal analyzes and displays the text data and the multimedia data respectively according to the analysis position information, the text data can be analyzed and rendered firstly, then the multimedia data is analyzed and rendered, and then the multimedia data is displayed.
In one possible implementation, when the indication information indicates to acquire the text data and the metadata of the multimedia data, the method further includes:
sending a second response data packet to the terminal based on the page identifier and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of the entire multimedia data.
In one possible implementation, when the first response packet includes metadata of the multimedia data, the method further includes:
and determining second multimedia data based on the metadata of the multimedia data, wherein the second multimedia data is the remaining multimedia data corresponding to the page identifier except the first multimedia data.
In one possible implementation, when the metadata of the multimedia data includes first metadata of second multimedia data, the method further includes:
receiving a multimedia data acquisition request sent by a terminal, wherein the multimedia data acquisition request comprises first metadata;
and determining second multimedia data based on the first metadata and sending the second multimedia data to the terminal.
In the page data processing method provided by the embodiment of the disclosure, a server receives a page data acquisition request sent by a terminal, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode; when the indication information indicates that the text data and the multimedia data are synchronously acquired, determining a first response data packet based on the page identification and the indication information, wherein the first response data packet comprises the first page data and the analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data; and sending the first response data packet to the terminal so that the terminal analyzes the first response data packet to obtain analysis position information, and analyzing the first response data packet based on the analysis position information to obtain and display first page data. According to the technical scheme, the terminal sends the data acquisition request to the server once, so that the text data and the multimedia data can be obtained, the text data and the multimedia data are analyzed and displayed according to the analysis position information in the response data packet sent by the server, delay caused by the fact that the text data and the multimedia data are respectively acquired through two data acquisition requests in the initial page rendering process is avoided, and the fluency of user experience is improved.
The prior art solution and the technical solution of the present disclosure are explained in comparison below.
In the prior art, when refreshing page data, in order to increase the speed of viewing new refreshed data by a user, a typical flow commonly used in the industry is divided into the following two stages:
the first stage is as follows: a network request is sent to the server requesting the text data and multimedia metadata of the brush. After the data requested by the network is returned, rendering the card, filling the text content, and displaying the missing multimedia information by using an occupation bitmap, wherein the occupation bitmap is a blank display map without a display image as shown in fig. 3;
and a second stage: after the first stage is finished, the real multimedia data is requested from the server according to the multimedia metadata, and the real multimedia data is rendered on the card and displayed to the user instead of the occupation bitmap, as shown in fig. 4, and the image is replaced with the occupation bitmap.
The terminal firstly requests the server for the text information and the metadata of the multimedia information, the text information is loaded and displayed to the user, the missing multimedia information is displayed in a mode of occupying a bitmap, the multimedia information is requested to the server according to the metadata, and the occupying bitmap is replaced and displayed to the user, so that the user can see the real multimedia information after waiting for a period of time after seeing the text content, and the smoothness of experience is influenced.
In an optional example of the technical solution of the present disclosure, the terminal sends a page data acquisition request of an APP page to the server, where the page data acquisition request includes indication information and a page identifier of the APP page, and the indication information may be a field load true, and the field may be included in a Header of the data acquisition request.
When receiving a page data acquisition request sent by a terminal, a server checks whether a preload field is true. If the page identifier is the text data, the multimedia data and the text data are synchronously acquired, the corresponding response data packet is determined according to the page identifier, the response data packet comprises the text data, the metadata of the multimedia data and the multimedia data, and the analysis position information of the text data and the multimedia data in the response data packet, and the response data packet is returned to the terminal.
The parsing position information of the text data, the multimedia data in the response packet, and the metadata of the multimedia data may be specifically that a data structure Preload is added to the Header, where the data structure Preload includes a parsing start-stop position of the text data, a parsing start-stop position of the multimedia data, and a parsing start-stop position of the multimedia data.
As an example, the specific content of the data structure Preload is shown in fig. 5, as shown in the figure, in this example, the data structure adopts a json (json Object Notation) data exchange format, where a parsing start position (e.g. start shown in the figure) of text data corresponding to the json in the figure is 0, a size 1000 shown in the figure represents a data amount, and then the end position is 1000, that is, 0 and 1000 in the response packet are respectively a start position and an end position of the text data; images correspond to two parts of multimedia data, i.e. the metadata of two pictures is shown in the figure: the metadata of the first part of multimedia data (uri as shown in the figure) is http: if the resolution start position (start shown in the figure) is 1000 and the size 2000 shown in the figure is data size, the end position is 3000, that is, the start position and the end position of the first picture in the response packet are 1000 and 3000 respectively; the metadata of the second part of multimedia data (uri as shown in the figure) is http: i/cdn/image/234, the parsing start position (start as shown in the figure) is 3000, the size 2000 as shown in the figure is the data size, and the ending position is 5000, that is, the starting position and the ending position of the second picture in the response packet are 3000 and 5000 respectively.
And after receiving a response data packet returned by the server, the terminal checks whether a Preload data structure exists in the Header, and if so, reads the text data according to the analysis position information of the text data in the Header and renders the text. And meanwhile, continuously reading the rest data, reading the multimedia data according to the analysis position information of the multimedia data in the Preload data structure, firstly checking whether the required multimedia data are stored locally, and directly rendering and displaying the multimedia resources if the required multimedia data are stored locally. If the multimedia data is not local, the multimedia data which is not local is requested from the server, the multimedia data which is continuously returned by the server according to the previous page data acquisition request can be waited, and the terminal can display the multimedia data which is firstly returned.
The indication information for indicating the data acquisition mode is not limited to the Header, and may be notified in the form of a request parameter or in any other mode.
The server does not limit the returning sequence of the text data and the multimedia data, and the text data and the multimedia data are put in the same request.
The data structure of the Preload is not limited to be implemented, and may be any data format capable of representing a start-stop position of text data, a start-stop position of multimedia data, and metadata. Meanwhile, the Preload data structure is not necessarily placed in the Header, but can be placed in any area that can be read by the terminal.
The cache of the multimedia data is not limited to be locally stored, but may be in a memory or any area that can be quickly read later.
When it is found that there is no multimedia data downloaded in the buffer, it is not necessary to initiate another request, but it may directly wait for the request in the Preload to return multimedia data.
Compared with the prior art, in the technical scheme of the disclosure, time consumption caused by network delay is saved by performing data transceiving between a terminal and a server, fig. 6 is a schematic diagram of a process of performing data transceiving between the terminal and the server in the prior art, as shown in fig. 6, the terminal sends a data acquisition request to the server, the time consumption of sending the request is 700 milliseconds (ms), the server receives the request, the time consumption of processing the request is 500 ms, the time consumption of receiving text data and metadata of multimedia data returned by the server by the terminal is 700 ms, the time consumption of decoding the request returned by the server by the terminal is 100 ms, the time consumption of sending the request for acquiring the multimedia data to the server by the terminal according to the metadata of the multimedia data obtained by decoding is 400 ms, the time consumption of receiving the multimedia data returned by the server by the terminal is 400 ms, and the.
Fig. 7 is a schematic diagram of a process of data transceiving between a terminal and a server in the technical solution of the present disclosure, where the terminal sends a data acquisition request to the server, and it takes 700 milliseconds to send the request, the server receives the request and processes the request, and it takes 500 milliseconds to receive the request, and 700 milliseconds to receive text data, multimedia data and respective corresponding parsing position information returned by the server, and the terminal decodes the received data, and it takes 100 milliseconds and 2000 milliseconds in total.
Compared with the prior art, the technical scheme of the disclosure has the advantages that the page data is requested to the server every time, the time of 800 milliseconds is reduced, the waiting time of the user is saved, and the fluency of the user for browsing the page data is improved.
Based on the same principle as the method shown in fig. 1, an embodiment of the present disclosure also provides a page data processing apparatus 30, and as shown in fig. 8, the page data processing apparatus 30 may include:
a sending module 31, configured to send a page data obtaining request to a server, where the page data obtaining request includes a page identifier and indication information, and the indication information is used to indicate a data obtaining manner;
a receiving module 32, configured to receive a first response data packet returned by the server based on the page identifier and the first obtaining manner when the indication information indicates that the text data and the multimedia data are obtained synchronously; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
the analysis module 33 is configured to analyze the first response data packet to obtain analysis position information;
and the display module 34 is used for analyzing the response data packet to obtain the first page data based on the analysis position information and displaying the first page data.
In a possible implementation manner, when the indication information indicates to acquire the text data and the metadata of the multimedia data, the page data processing apparatus 30 further includes a packet receiving module configured to:
receiving a second response data packet returned by the server based on the page identification and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of the entire multimedia data.
In a possible implementation manner, when the first response packet includes metadata of multimedia data, the page data processing apparatus 30 further includes a multimedia data obtaining module, configured to:
and acquiring second multimedia data based on the metadata of the multimedia data, wherein the second multimedia data is the remaining multimedia data corresponding to the page identifier except the first multimedia data.
In a possible implementation manner, when the metadata of the multimedia data includes the first metadata of the second multimedia data, the multimedia data obtaining module is configured to, when obtaining the second multimedia data based on the metadata of the multimedia data:
sending a multimedia data acquisition request to a server, wherein the multimedia data acquisition request comprises first metadata;
and receiving second multimedia data sent by the server based on the first metadata.
In a possible implementation manner, when the metadata of the multimedia data is second metadata of all multimedia data, the multimedia data obtaining module is further configured to:
parsing second metadata from the first response data packet based on the parsed location information;
the parsed first multimedia data is determined based on the second metadata, and a multimedia data acquisition request is transmitted to the server based on metadata of a remaining portion of the multimedia data excluding the parsed first multimedia data.
The page data processing apparatus of the embodiments of the present disclosure may execute the page data processing method provided by the embodiments of the present disclosure, and the implementation principle is similar, the actions executed by each module in the page data processing apparatus of each embodiment of the present disclosure correspond to the steps in the page data processing method of each embodiment of the present disclosure, and for the detailed functional description of each module of the page data processing apparatus, reference may be specifically made to the description in the corresponding page data processing method shown in the foregoing, and details are not repeated here.
Based on the same principle as the method shown in fig. 2, an embodiment of the present disclosure also provides a page data processing apparatus 40, and as shown in fig. 9, the page data processing apparatus 40 may include:
a receiving module 41, configured to receive a page data obtaining request sent by a terminal, where the page data obtaining request includes a page identifier and indication information, and the indication information is used to indicate a data obtaining manner;
a determining module 42, configured to determine, when the indication information indicates that the text data and the multimedia data are synchronously acquired, a first response data packet based on the page identifier and the indication information, where the first response data packet includes the first page data and the parsing position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
and a sending module 43, configured to send the first response packet to the terminal, so that the terminal analyzes the first response packet to obtain analysis position information, and analyzes the first response packet based on the analysis position information to obtain and display the first page data.
In a possible implementation manner, when the indication information indicates to acquire the text data and the metadata of the multimedia data, the page data processing apparatus 40 further includes a packet sending module configured to:
sending a second response data packet to the terminal based on the page identifier and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of the entire multimedia data.
In a possible implementation manner, when the first response packet includes metadata of multimedia data, the page data processing apparatus 40 further includes a multimedia data determining module configured to:
and determining second multimedia data based on the metadata of the multimedia data, wherein the second multimedia data is the remaining multimedia data corresponding to the page identifier except the first multimedia data.
In a possible implementation manner, when the metadata of the multimedia data includes the first metadata of the second multimedia data, the page data processing apparatus 40 further includes a multimedia data sending module for:
receiving a multimedia data acquisition request sent by a terminal, wherein the multimedia data acquisition request comprises first metadata;
and determining second multimedia data based on the first metadata and sending the second multimedia data to the terminal.
The page data processing apparatus of the embodiments of the present disclosure may execute the page data processing method provided by the embodiments of the present disclosure, and the implementation principle is similar, the actions executed by each module in the page data processing apparatus of each embodiment of the present disclosure correspond to the steps in the page data processing method of each embodiment of the present disclosure, and for the detailed functional description of each module of the page data processing apparatus, reference may be specifically made to the description in the corresponding page data processing method shown in the foregoing, and details are not repeated here.
Referring now to FIG. 10, a block diagram of an electronic device 600 suitable for use in implementing embodiments of the present disclosure is shown. The execution subject of the technical solution of the present disclosure may include, but is not limited to, a mobile terminal such as a mobile phone, a notebook computer, a digital broadcast receiver, a PDA (personal digital assistant), a PAD (tablet computer), a PMP (portable multimedia player), a vehicle-mounted terminal (e.g., a car navigation terminal), etc., and a stationary terminal such as a digital TV, a desktop computer, etc. The electronic device shown in fig. 10 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
The electronic device includes: a memory and a processor, wherein the processor may be referred to as a processing device 601 described below, and the memory may include at least one of a Read Only Memory (ROM)602, a Random Access Memory (RAM)603, and a storage device 608, which are described below:
as shown in fig. 10, electronic device 600 may include a processing means (e.g., central processing unit, graphics processor, etc.) 601 that may perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)602 or a program loaded from a storage means 608 into a Random Access Memory (RAM) 603. In the RAM 603, various programs and data necessary for the operation of the electronic apparatus 600 are also stored. The processing device 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
Generally, the following devices may be connected to the I/O interface 605: input devices 606 including, for example, a touch screen, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; output devices 607 including, for example, a Liquid Crystal Display (LCD), a speaker, a vibrator, and the like; storage 608 including, for example, tape, hard disk, etc.; and a communication device 609. The communication means 609 may allow the electronic device 600 to communicate with other devices wirelessly or by wire to exchange data. While fig. 10 illustrates an electronic device 600 having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program carried on a non-transitory computer readable medium, the computer program containing program code for performing the method illustrated by the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication means 609, or may be installed from the storage means 608, or may be installed from the ROM 602. The computer program, when executed by the processing device 601, performs the above-described functions defined in the methods of the embodiments of the present disclosure.
It should be noted that the computer readable medium in the present disclosure can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In contrast, in the present disclosure, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
In some embodiments, the clients, servers may communicate using any currently known or future developed network protocol, such as HTTP (HyperText transfer protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communications network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the Internet (e.g., the Internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed network.
The computer readable medium may be embodied in the electronic device; or may exist separately without being assembled into the electronic device.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to: sending a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode; when the indication information indicates that the text data and the multimedia data are synchronously acquired, receiving a first response data packet returned by the server based on the page identification and the indication information; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data; analyzing the first response data packet to obtain analysis position information; and analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data. Or
Receiving a page data acquisition request sent by a terminal, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode; when the indication information indicates that the text data and the multimedia data are synchronously acquired, determining a first response data packet based on the page identification and the indication information, wherein the first response data packet comprises the first page data and the analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data; and sending the first response data packet to the terminal so that the terminal analyzes the first response data packet to obtain analysis position information, and analyzing the first response data packet based on the analysis position information to obtain and display first page data.
Computer program code for carrying out operations for the present disclosure may be written in any combination of one or more programming languages, including but not limited to an object oriented programming language such as Java, Smalltalk, C + +, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules or units described in the embodiments of the present disclosure may be implemented by software or hardware. Wherein the designation of a module or unit does not in some cases constitute a limitation of the unit itself.
The functions described herein above may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), systems on a chip (SOCs), Complex Programmable Logic Devices (CPLDs), and the like.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
According to one or more embodiments of the present disclosure, there is provided a page data processing method, including:
sending a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
when the indication information indicates that text data and multimedia data are synchronously acquired, receiving a first response data packet returned by the server based on the page identifier and the indication information; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
analyzing the first response data packet to obtain the analysis position information;
and analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data.
In one possible implementation, when the indication information indicates to acquire metadata of the text data and the multimedia data, the method further includes:
receiving a second response data packet returned by the server based on the page identifier and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of all multimedia data.
In one possible implementation, when the first response packet includes metadata of multimedia data, the method further includes:
and acquiring second multimedia data based on the metadata of the multimedia data, wherein the second multimedia data is the remaining multimedia data corresponding to the page identifier except for the first multimedia data.
In one possible implementation manner, when the metadata of the multimedia data includes the first metadata of the second multimedia data, the obtaining the second multimedia data based on the metadata of the multimedia data includes:
sending a multimedia data acquisition request to a server, wherein the multimedia data acquisition request comprises the first metadata;
and receiving the second multimedia data sent by the server based on the first metadata.
In one possible implementation manner, when the metadata of the multimedia data is second metadata of all multimedia data, the method further includes:
parsing the second metadata from the first response packet based on the parsed location information;
and determining the parsed first multimedia data based on the second metadata, and sending a multimedia data acquisition request to the server based on metadata of the remaining multimedia data except the parsed first multimedia data.
According to one or more embodiments of the present disclosure, there is provided a page data processing method, including:
receiving a page data acquisition request sent by a terminal, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode;
when the indication information indicates that text data and multimedia data are synchronously acquired, determining a first response data packet based on the page identifier and the indication information, wherein the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
and sending the first response data packet to the terminal so that the terminal analyzes the first response data packet to obtain the analysis position information, and analyzing the first response data packet based on the analysis position information to obtain and display the first page data.
According to one or more embodiments of the present disclosure, there is provided a page data processing apparatus including:
the system comprises a sending module, a receiving module and a sending module, wherein the sending module is used for sending a page data acquisition request to a server, the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
the receiving module is used for receiving a first response data packet returned by the server based on the page identifier and the indication information when the indication information indicates that the text data and the multimedia data are synchronously acquired; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
the analysis module is used for analyzing the first response data packet to obtain the analysis position information;
and the display module is used for analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data.
In a possible implementation manner, when the indication information indicates to acquire metadata of text data and multimedia data, the page data processing apparatus further includes a packet receiving module configured to:
receiving a second response data packet returned by the server based on the page identifier and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of all multimedia data.
In a possible implementation manner, when the first response packet includes metadata of multimedia data, the page data processing apparatus further includes a multimedia data obtaining module, configured to:
and acquiring second multimedia data based on the metadata of the multimedia data, wherein the second multimedia data is the remaining multimedia data corresponding to the page identifier except for the first multimedia data.
In a possible implementation manner, when the metadata of the multimedia data includes the first metadata of the second multimedia data, the multimedia data obtaining module is configured to, when obtaining the second multimedia data based on the metadata of the multimedia data:
sending a multimedia data acquisition request to a server, wherein the multimedia data acquisition request comprises the first metadata;
and receiving the second multimedia data sent by the server based on the first metadata.
In a possible implementation manner, when the metadata of the multimedia data is second metadata of all multimedia data, the multimedia data obtaining module is further configured to:
parsing the second metadata from the first response packet based on the parsed location information;
and determining the parsed first multimedia data based on the second metadata, and sending a multimedia data acquisition request to the server based on metadata of the remaining multimedia data except the parsed first multimedia data.
According to one or more embodiments of the present disclosure, there is provided a page data processing apparatus including:
the system comprises a receiving module, a sending module and a receiving module, wherein the receiving module is used for receiving a page data acquisition request sent by a terminal, the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode;
a determining module, configured to determine, when the data acquisition manner indicated by the indication information is a first acquisition manner, a response data packet based on the page identifier and the first acquisition manner, where the response data packet includes page data and analysis position information of the page data in the response data packet; the page data includes text data and first multimedia data;
and the sending module is used for sending the response data packet to the terminal so as to enable the terminal to analyze the response data packet to obtain the analysis position information, and analyzing the response data packet based on the analysis position information to obtain the page data and display the page data.
In accordance with one or more embodiments of the present disclosure, there is provided an electronic device including:
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: and executing the page data processing method in the embodiment of the application.
According to one or more embodiments of the present disclosure, a computer-readable medium is provided for storing computer instructions, which when executed on a computer, enable the computer to perform the page data processing method according to the embodiments of the present disclosure.
The foregoing description is only exemplary of the preferred embodiments of the disclosure and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the disclosure herein is not limited to the particular combination of features described above, but also encompasses other embodiments in which any combination of the features described above or their equivalents does not depart from the spirit of the disclosure. For example, the above features and (but not limited to) the features disclosed in this disclosure having similar functions are replaced with each other to form the technical solution.
Further, while operations are depicted in a particular order, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limitations on the scope of the disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.

Claims (10)

1. A page data processing method is characterized by comprising the following steps:
sending a page data acquisition request to a server, wherein the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
when the indication information indicates that text data and multimedia data are synchronously acquired, receiving a first response data packet returned by the server based on the page identifier and the indication information; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
analyzing the first response data packet to obtain the analysis position information;
and analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data.
2. The page data processing method according to claim 1, wherein when said indication information indicates that metadata of text data and multimedia data is acquired, said method further comprises:
receiving a second response data packet returned by the server based on the page identifier and the indication information, wherein the second response data packet comprises second page data; the second page data includes text data and metadata of all multimedia data.
3. The method of claim 1, wherein when the first response packet includes metadata of multimedia data, the method further comprises:
and acquiring second multimedia data based on the metadata of the multimedia data, wherein the second multimedia data is the remaining multimedia data corresponding to the page identifier except for the first multimedia data.
4. The page data processing method according to claim 3, wherein when the metadata of the multimedia data includes the first metadata of the second multimedia data, said acquiring the second multimedia data based on the metadata of the multimedia data includes:
sending a multimedia data acquisition request to a server, wherein the multimedia data acquisition request comprises the first metadata;
and receiving the second multimedia data sent by the server based on the first metadata.
5. The method of claim 3, wherein when the metadata of the multimedia data is second metadata of the entire multimedia data, the method further comprises:
parsing the second metadata from the first response packet based on the parsed location information;
and determining the parsed first multimedia data based on the second metadata, and sending a multimedia data acquisition request to the server based on metadata of the remaining multimedia data except the parsed first multimedia data.
6. A page data processing method is characterized by comprising the following steps:
receiving a page data acquisition request sent by a terminal, wherein the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode;
when the indication information indicates that text data and multimedia data are synchronously acquired, determining a first response data packet based on the page identifier and the indication information, wherein the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
and sending the first response data packet to the terminal so that the terminal analyzes the first response data packet to obtain the analysis position information, and analyzing the first response data packet based on the analysis position information to obtain and display the first page data.
7. A page data processing apparatus, characterized in that the apparatus comprises:
the system comprises a sending module, a receiving module and a sending module, wherein the sending module is used for sending a page data acquisition request to a server, the page data acquisition request comprises a page identifier and indicating information, and the indicating information is used for indicating a data acquisition mode;
the receiving module is used for receiving a first response data packet returned by the server based on the page identifier and the indication information when the indication information indicates that the text data and the multimedia data are synchronously acquired; the first response data packet comprises first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
the analysis module is used for analyzing the first response data packet to obtain the analysis position information;
and the display module is used for analyzing the first page data from the first response data packet based on the analysis position information and displaying the first page data.
8. A page data processing apparatus, characterized in that the apparatus comprises:
the system comprises a receiving module, a sending module and a receiving module, wherein the receiving module is used for receiving a page data acquisition request sent by a terminal, the page data acquisition request comprises a page identifier and indication information, and the indication information is used for indicating a data acquisition mode;
a determining module, configured to determine, when the indication information indicates that text data and multimedia data are synchronously acquired, a first response data packet based on the page identifier and the indication information, where the first response data packet includes first page data and analysis position information of the first page data in the first response data packet; the first page data includes text data and first multimedia data;
and the sending module is used for sending the first response data packet to the terminal so as to enable the terminal to analyze the first response data packet to obtain the analysis position information, and the first page data is analyzed from the first response data packet based on the analysis position information and displayed.
9. An electronic device, comprising:
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: executing the page data processing method according to any one of claims 1 to 6.
10. A computer-readable medium for storing computer instructions which, when executed on a computer, cause the computer to perform the page data processing method of any one of claims 1 to 6.
CN202010344959.2A 2020-04-27 2020-04-27 Page data processing method, device, electronic equipment and readable medium Active CN111581556B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010344959.2A CN111581556B (en) 2020-04-27 2020-04-27 Page data processing method, device, electronic equipment and readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010344959.2A CN111581556B (en) 2020-04-27 2020-04-27 Page data processing method, device, electronic equipment and readable medium

Publications (2)

Publication Number Publication Date
CN111581556A true CN111581556A (en) 2020-08-25
CN111581556B CN111581556B (en) 2023-04-25

Family

ID=72127149

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010344959.2A Active CN111581556B (en) 2020-04-27 2020-04-27 Page data processing method, device, electronic equipment and readable medium

Country Status (1)

Country Link
CN (1) CN111581556B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115776587A (en) * 2021-09-06 2023-03-10 中移物联网有限公司 Information synchronization method, device and related equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150200994A1 (en) * 2012-05-29 2015-07-16 Google Inc. Preloading resources of a web page
CN108287839A (en) * 2017-01-09 2018-07-17 阿里巴巴集团控股有限公司 A kind of page loading method and equipment
US20190124174A1 (en) * 2016-01-22 2019-04-25 Alibaba Group Holding Limited Resource cache management method and system and apparatus
CN109684580A (en) * 2017-10-18 2019-04-26 中移(苏州)软件技术有限公司 A kind of methods of exhibiting and electronic equipment of dynamic page
CN110851757A (en) * 2019-10-12 2020-02-28 平安普惠企业管理有限公司 Page resource loading method and terminal
US20200082022A1 (en) * 2018-09-06 2020-03-12 Google Llc Display responsive communication system and method
CN111061974A (en) * 2019-11-26 2020-04-24 贝壳技术有限公司 Client page loading method and device and page loading method and system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150200994A1 (en) * 2012-05-29 2015-07-16 Google Inc. Preloading resources of a web page
US20190124174A1 (en) * 2016-01-22 2019-04-25 Alibaba Group Holding Limited Resource cache management method and system and apparatus
CN108287839A (en) * 2017-01-09 2018-07-17 阿里巴巴集团控股有限公司 A kind of page loading method and equipment
CN109684580A (en) * 2017-10-18 2019-04-26 中移(苏州)软件技术有限公司 A kind of methods of exhibiting and electronic equipment of dynamic page
US20200082022A1 (en) * 2018-09-06 2020-03-12 Google Llc Display responsive communication system and method
CN110851757A (en) * 2019-10-12 2020-02-28 平安普惠企业管理有限公司 Page resource loading method and terminal
CN111061974A (en) * 2019-11-26 2020-04-24 贝壳技术有限公司 Client page loading method and device and page loading method and system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115776587A (en) * 2021-09-06 2023-03-10 中移物联网有限公司 Information synchronization method, device and related equipment
CN115776587B (en) * 2021-09-06 2024-05-24 中移物联网有限公司 Information synchronization method and device and related equipment

Also Published As

Publication number Publication date
CN111581556B (en) 2023-04-25

Similar Documents

Publication Publication Date Title
CN111399956B (en) Content display method and device applied to display equipment and electronic equipment
CN109976620B (en) Method, device, equipment and storage medium for determining list item display attribute information
CN112272226B (en) Picture loading method and device and readable storage medium
CN110516159B (en) Information recommendation method and device, electronic equipment and storage medium
CN110619096B (en) Method and apparatus for synchronizing data
CN110781437A (en) Method and device for acquiring webpage image loading duration and electronic equipment
CN110852946A (en) Picture display method and device and electronic equipment
CN111694629A (en) Information display method and device and electronic equipment
CN110765386A (en) Webpage image monitoring method and device, electronic equipment and readable storage medium
CN112053286B (en) Image processing method, device, electronic equipment and readable medium
CN111581556B (en) Page data processing method, device, electronic equipment and readable medium
CN110619101B (en) Method and apparatus for processing information
CN112084441A (en) Information retrieval method and device and electronic equipment
CN111352872A (en) Execution engine, data processing method, apparatus, electronic device, and medium
CN111783010A (en) Webpage blank page monitoring method, device, terminal and storage medium
WO2022218028A1 (en) Page loading method and apparatus, and device and storage medium
CN111259287B (en) Page content display method and device, electronic equipment and storage medium
CN112636971B (en) Service degradation method and device, electronic equipment and storage medium
CN112732457B (en) Image transmission method, image transmission device, electronic equipment and computer readable medium
CN111259290A (en) Information display method and device, electronic equipment and computer readable medium
CN112203158A (en) Image display method, device, system, equipment and medium
CN110795670A (en) Webpage image monitoring method and device, electronic equipment and readable storage medium
CN112417276A (en) Paging data acquisition method and device, electronic equipment and computer readable storage medium
CN111405342B (en) Rich text message display method, device, system, medium and electronic equipment
CN112948108B (en) Request processing method and device and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant after: Douyin Vision Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant before: Tiktok vision (Beijing) Co.,Ltd.

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant after: Tiktok vision (Beijing) Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant before: BEIJING BYTEDANCE NETWORK TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant