CN110765377B - Data loading method and device - Google Patents

Data loading method and device Download PDF

Info

Publication number
CN110765377B
CN110765377B CN201810840965.XA CN201810840965A CN110765377B CN 110765377 B CN110765377 B CN 110765377B CN 201810840965 A CN201810840965 A CN 201810840965A CN 110765377 B CN110765377 B CN 110765377B
Authority
CN
China
Prior art keywords
data block
point information
loaded
display page
record point
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810840965.XA
Other languages
Chinese (zh)
Other versions
CN110765377A (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.)
All China Marketing Research Co ltd
Original Assignee
All China Marketing Research 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 All China Marketing Research Co ltd filed Critical All China Marketing Research Co ltd
Priority to CN201810840965.XA priority Critical patent/CN110765377B/en
Publication of CN110765377A publication Critical patent/CN110765377A/en
Application granted granted Critical
Publication of CN110765377B publication Critical patent/CN110765377B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention provides a data loading method, which comprises the following steps: monitoring that the display page moves to a preset position, and determining the information of the recording point of the data block to be loaded in the movement direction of the display page; inquiring the record point information of the data block to be loaded from the cache; and if the record point information of the data block to be loaded is queried, loading the data block corresponding to the record point information from a cache.

Description

Data loading method and device
Technical Field
The invention relates to the technical field of data processing, in particular to a data loading method and device.
Background
At present, when loading data, the browser limits the number of columns of the data table, that is, the number of columns is fixed, the number of columns is dynamically changed, and when loading data, the more the number of columns of the data table to be loaded, the more the loaded page drops, and the phenomenon of clamping and stopping occurs. The data is processed and stored by the background (such as a server or a host), when the data is displayed or operated, the data needs to be loaded to the front-end equipment (such as a display device or a client), but the existing front-end equipment does not record the loaded data, so that even if a user browses or operates the loaded data by the front-end equipment, the front-end equipment still requests related data from the background again, if the front-end equipment already has partial data, the reloaded data also can cover the original data again, the data display of the front-end equipment needs to depend on the server, the display speed is slow, and a larger stress is caused to the background.
Disclosure of Invention
Therefore, the present invention is directed to a method and apparatus for loading data, which are used for solving the problem of slow loading data in the prior art.
In a first aspect, an embodiment of the present application provides a data loading method, where the method includes:
monitoring that the display page moves to a preset position, and determining the information of the recording point of the data block to be loaded in the movement direction of the display page;
inquiring the record point information of the data block to be loaded from the cache;
and if the record point information of the data block to be loaded is queried, loading the data block corresponding to the record point information from a cache.
Optionally, the determining the record point information of the data block to be loaded in the motion direction of the current display page includes:
acquiring the movement direction of a display page;
determining the recording point information of the next data block in the movement direction of the display page as the recording point information of the data block to be loaded; or alternatively, the process may be performed,
and acquiring the record point information of at least two data blocks adjacent to the data block displayed on the display page, and determining the record point information of the data block to be loaded according to the movement direction of the display page.
Optionally, the method further comprises:
and if the record point information of the data block to be loaded is not queried, acquiring and loading the data block to be loaded from the background based on the record point information of the data block to be loaded.
Optionally, the recording point information is coordinate information of at least one boundary point of the data block.
Optionally, the method further comprises:
if the change of the record point information in any data block on the display page is monitored, updating the record point information corresponding to the data block in the cache based on the changed record point information.
Optionally, if it is detected that the record point information in any data block on the display page changes, updating record point information corresponding to the data block in the cache based on the changed record point information includes:
if the changed data block has more than two boundary points, updating the record point information corresponding to the data block in the cache by utilizing the coordinate information of the more than two boundary points;
if the changed data block only has one boundary point, updating the record point information corresponding to the data block and the record point information corresponding to the next data block along the movement direction of the display page in the cache by utilizing the coordinate information of the boundary point;
and if the changed data block does not have the boundary point, deleting the record point information corresponding to the data block in the cache.
Optionally, the movement direction includes upward, downward, leftward and rightward.
In a second aspect, an embodiment of the present application provides a data loading apparatus, including:
the determining module is used for monitoring that the display page moves to a preset position and determining the record point information of the data block to be loaded in the moving direction of the display page;
the query module is used for querying the record point information of the data block to be loaded from the cache;
and the loading module is used for loading the data block corresponding to the record point information from the cache if the record point information of the data block to be loaded is queried.
Optionally, the determining module is specifically configured to:
acquiring the movement direction of a display page;
determining the recording point information of the next data block in the movement direction of the display page as the recording point information of the data block to be loaded; or alternatively, the process may be performed,
and acquiring the record point information of at least two data blocks adjacent to the data block displayed on the display page, and determining the record point information of the data block to be loaded according to the movement direction of the display page.
In a third aspect, embodiments of the present application provide a computer device including a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the above method when executing the computer program.
According to the data loading method provided by the embodiment of the invention, after the display page is monitored to move to the preset position, the record point information of the data block to be loaded in the moving direction of the display page is determined, and after the determined record point information exists in the cache, the data block corresponding to the record point information is loaded from the cache. Therefore, by storing the loaded data blocks and the recording points of the corresponding data blocks in the cache, when a user requests the loaded data blocks again, the data can be directly obtained from the cache through the recording point information of the data blocks to be loaded instead of obtaining the data from the background, so that the throughput and the pressure of the background are reduced, the display speed of the front end is improved, and the blocking of the display page is reduced.
In order to make the above objects, features and advantages of the present invention more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the embodiments will be briefly described below, it being understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and other related drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a data loading method according to an embodiment of the present invention;
FIG. 2 is a second schematic diagram of a data block according to an embodiment of the present invention;
FIG. 3 is a second schematic diagram of a data block according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of a data loading device according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a computer device 500 according to an embodiment of the invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. The components of the embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the invention, as presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be made by a person skilled in the art without making any inventive effort, are intended to be within the scope of the present invention.
The embodiment of the application provides a data loading method, as shown in fig. 1, which is applied to a data processing system, wherein the data processing system comprises terminal equipment, such as: computers, notebook computers, tablet computers, mobile phones, portable devices, vehicle-mounted devices, etc., also include network systems such as: an audiovisual service system, a large screen system, a client/server system (C/S), a browser/server system, a cloud computing system, and so forth. The type and architecture of the data processing system is not limited herein. The method comprises the following steps:
s101, monitoring that the display page moves to a preset position, and determining recording point information of a data block to be loaded in the moving direction of the display page. Here, the display page may be, but is not limited to, a web page display page, a form display page, a WeChat display page, or the like; techniques for monitoring the position of movement of a display page are described in detail in the prior art and will not be described in any greater detail herein.
The preset position is generally preset, and may be a preset distance from the current display content to the next data block in the moving direction of the display page, where the moving direction of the display page includes up, down, left, right, and so on, for example, if the current display content in the display page in the mobile terminal is a 100×100 data block (the unit may be a pixel), the moving direction of the display page is down, and the preset position may be a position that is a certain distance from the boundary of the data block in the moving direction, for example, 30 pixels, that is, a position that is a distance from the lower boundary point of the data block is 30 pixels, and the situation that the moving direction is leftward, rightward, and upward is the same as the above example, and will not be described herein too much. The size of the data block can be set according to the need, for example, according to the size of the display screen or the data content and type, and the size of the data block is preferably larger than the size of the display screen.
The recording point information may include coordinate information of at least one boundary point of the data block, the coordinate information may be a number of the boundary point, a two-dimensional coordinate of the boundary point in the data block, and the like, preferably, the coordinate information is a number of the boundary point, and the number of the boundary point may be a number of a minimum data unit data cell in the data block, and may be a row number and/or a column number.
For example, referring to fig. 2, a data block is illustrated, where the size of the data block is 100 rows×100 columns, the data block includes a, b, c, d four boundary points, a point a corresponding to a first column of the first row is an upper left point, or called a start point, a point d corresponding to a 100 th column of the 100 th row is a lower right point, or called an end point, a point b corresponding to a 100 th column of the 1 st row and a point c corresponding to a 1 st column of the 100 th row are an upper right point and a lower left point, respectively, coordinate information of the boundary point a (i.e., a number of data cells, the same applies hereinafter) is (1, 1), coordinate information of the boundary point b is (1, 100), coordinate information of the boundary point c is (100, 1), and coordinate information of the boundary point d is (100 ).
After the computer equipment monitors that the display page reaches the preset position, determining the record point information of the data block to be loaded in the movement direction of the display page according to any one of the following modes:
mode one: acquiring the movement direction of a display page;
determining the recording point information of the next data block in the movement direction of the display page as the recording point information of the data block to be loaded;
in a specific implementation, the moving direction of a scroll bar in a display page is acquired, the recording point information of the next data block adjacent to the current data block is acquired along the moving direction of the scroll bar, and the acquired recording point information is used as the recording point information of the data block to be loaded.
For example, referring to fig. 3, the data blocks are all standard data blocks (data blocks which are not deleted and added are called standard data blocks), the data in the data blocks are 100 rows×100 columns, the recording point information generally includes coordinate information of a start point and coordinate information of an end point, taking 4 data blocks as an example for explanation, the current data block is C1, the data block on the right of the data block C1 is C2, the data block below the data block C1 is C3, the data block on the right of the data block C3 is C4, the recording point information of the C1 includes (1, 1) and (100 ), the recording point information of the data block C2 is (1, 101) and (100, 200), the recording point information of the data block C3 is (101 ) and (200 ), and after determining that the movement direction of the display page is downward, the recording point information of the data block to be loaded is (101, 1) and (200 ), that is the data block to be loaded is C3.
Mode two:
and acquiring the record point information of at least two data blocks adjacent to the data block displayed on the display page, and determining the record point information of the data block to be loaded according to the movement direction of the display page.
In a specific implementation, coordinate information of boundary points of at least two adjacent data blocks in a current data block in a display page is obtained, and the coordinate information of the boundary points in the moving direction is further determined as record point information of the data block to be loaded according to the acquired moving direction of the display page.
In an example of the first continuation, referring to fig. 3, the current data block is C1, the data blocks adjacent to C1 are C2 and C3, the recording point information of C2 and C3 is acquired, after determining that the moving direction of the display page is downward, the recording point information of the data block to be loaded is C3, and the recording point information of C3 is (101, 1) and (200 ).
S102, inquiring the record point information of the data block to be loaded from the cache;
here, the correspondence between the identifier of the loaded data block and the coordinate information of the boundary point is stored in the buffer memory in advance, and each data block may store the coordinate information of at least one boundary point, preferably, the coordinate information of the start point and the coordinate information of the end point corresponding to each data block are stored in the buffer memory. For example, the record point information of the loaded data block is identified as C1 and C2, the record point information of C1 is the start point (1, 1) and the end point (100 ), the record point information of C3 is the start point (101, 1) and the end point (200 ), and the record point information of C1 and the corresponding record point information is the start point (1, 1) and the end point (100 ), and the record point information of C3 and the corresponding record point information is the start point (101, 1) and the end point (200 ) are stored in the cache.
In a specific implementation, after the record point information of the data block to be loaded is obtained, inquiring the boundary point information matched with the record point information of the data block to be loaded from a corresponding relation table between the identification of the cached data block and the coordinate information of the boundary point.
And S103, if the record point information of the data block to be loaded is queried, loading the data block corresponding to the record point information from a cache.
And if the record point information of the data block to be loaded is not queried, acquiring and loading the data block to be loaded from the background based on the record point information of the data block to be loaded.
In the implementation, if the boundary point information matched with the record point information of the data block to be loaded is queried, the fact that the data block corresponding to the record point information is loaded is described, and the corresponding data block can be directly obtained from the cache according to the record point information of the data block to be loaded; if the coordinate information of the boundary point matched with the record point information of the data block to be loaded is not queried, the data block to be loaded is not loaded, the data block to be loaded needs to be acquired from a background (a host or a server) according to the record point information of the data block to be loaded, and after the corresponding data block to be loaded is loaded, the identification of the data block to be loaded and the corresponding record point information are stored in a cache. Therefore, when the user loads the data block stored in the cache again next time, the data can be directly obtained from the cache, the pressure of the front end is reduced, the display speed of the display content is improved, the dependence of the front end on the background is reduced, and meanwhile, the processing pressure of the background is also reduced.
When the corresponding relation table in the cache is queried, the starting point of the data block to be loaded can be used as a query point, the ending point of the data block to be loaded can be used as a query point, and the starting point and the ending point of the data block to be loaded can be used as the query point at the same time.
Taking the starting point of the data block to be loaded as a query point as an example, acquiring the recording point information of the data block to be loaded as (101, 1) and (200 ), acquiring the coordinate information of the starting point of the data block to be loaded as (101, 1), if the recording point information of C1 and C3 is stored in the corresponding relation table of the cache, that is, the recording point information of C1 is the starting point (1, 1) and the recording point information of the ending point (100 ) and C3 is the starting point (101, 1) and the ending point (200 ), querying the corresponding relation table in the cache for the coordinate information of the starting point of C3 when the recording point information matched with the starting point (101, 1) of the data block to be loaded is queried, and acquiring the data block corresponding to the recording point information of C3 from the cache and loading; if only the record point information of C1 is stored in the corresponding relation table of the cache, that is, the record point information of C1 is the start point (1, 1) and the end point (100 ), when the record point information matched with the start point (101, 1) of the data block to be loaded is queried from the corresponding relation table in the cache, the coordinate information matched with the (101, 1) is not queried, at this time, the data block corresponding to the information can be acquired from the background based on the start point (101, 1) of the data block to be loaded and the acquired end point (200 ), and after the data block corresponding to the start point (101, 1) of the data block to be loaded is loaded, the (101, 1) is stored in the cache as the record point information. If the data block to be loaded is a standard data block, the end point of the data block to be loaded can be obtained through calculation.
In the data loading process, the computer equipment detects the change condition of the record point information in the data blocks in the display page, and if the record point information in any data block on the display page is detected to change, the record point information corresponding to the data block in the cache is updated based on the changed record point information; if the fact that the record point information which does not exist on the display page is monitored to change, the stored record point information corresponding to the data block is not updated.
When the change of the record point information in any data block on the display page is monitored, the record point information corresponding to the data block in the cache is updated based on the changed record point information, and the method comprises the following steps:
if the changed data block has more than two boundary points, updating the record point information corresponding to the data block in the cache by utilizing the coordinate information of the more than two boundary points;
if the changed data block only has one boundary point, updating the record point information corresponding to the data block and the record point information corresponding to the next data block along the movement direction of the display page in the cache by utilizing the coordinate information of the boundary point;
and if the changed data block does not have the boundary point, deleting the record point information corresponding to the data block in the cache.
In a specific implementation, a user can add or delete data in a data block through a display page, so the data block is not always a standard data block, when the coordinate information of boundary points in the data block changes, and two or more boundary points are arranged in the changed data block, namely, middle data or boundary points in the data block are deleted or added, but two or more boundary points still exist, at this time, according to the coordinate information of the changed boundary points in the data block, corresponding record point information in a cache is updated, and when the coordinate information of several boundary points in the data block changes, corresponding record point information in the cache is changed; if the coordinate information of the boundary point in the data block changes and only one boundary point exists in the changed data block, if only one row or one column of data is left in the current data block, deleting the record point information corresponding to the data block in the cache by utilizing the coordinate information of the boundary point, and updating the record point information corresponding to the next data block along the movement direction of the display page; if the changed data block does not have a boundary point, that is, the data block is deleted, the record point information corresponding to the data block in the cache is deleted.
Taking 100 rows by 100 columns as examples of data in the loaded data block, the coordinate information of the starting point is (1, 1), the coordinate information of the ending point is (100 ), if a row or a column is deleted in the middle part of the data block, and the deleted row or column does not influence the coordinate information of the boundary point of the current data block, then the coordinate information of the boundary point is unchanged, and the record point information corresponding to the data block in the cache is unchanged.
If the boundary line or column in the data block is deleted, for example, the first line is deleted, but the data block still has two boundary points, the coordinate information of the starting point of the data block will become (2, 1), and the coordinate information of the recording point information of the data block corresponding to the starting point of the data block in the cache will be updated to (2, 1); the 100 th row is deleted, but the data block still has two boundary points, the coordinate information of the end point of the data block will become (99, 100), the coordinate information of the record point information of the data block corresponding to the start point of the data block in the cache will be updated to (99, 100), the situation that the column is deleted is the same as the situation that the row is changed, and the redundant description will not be repeated.
For the case of adding data to the boundary of a data block, in the prior art, when adding row or column data to the data block, the number of the newly added row or column will change according to the last row or column adjacent to the newly added row or column, for example, the number of the current data grid is (2, 1), and when adding one row of data under the current data grid, the number of the data grid under the newly added previous data grid is (3, 1), so long as the data in the data block changes, the number of the boundary point in the data block will change, and the processing pressure of the front end is increased. In this application, when data such as a row or a column is added to a data block, the number of the newly added row or column is sequentially increased over time, and is not dependent on the number of the current row, for example, the data block is a standard data block (100 rows×100 columns), the number of the current data grid is (2, 1), one row of data is added below the current data, the number of the data grid below the newly added previous data grid is (101, 1), after the corresponding data of (101, 1) is added, one row is added after the corresponding data of (10, 1), the number of the newly added data is (102, 1), and as long as the added data is not a boundary point of the data block, no change occurs in coordinate information of the boundary point in the data block.
If a row or column is added to the boundary point in the standard data block, for example, the moving direction is downward, a row is added before the first row of the data block C1, and the row is added for the first time, the coordinate information of the starting point of the data block will become (101, 1), the record point information corresponding to the data block in the cache is updated to (101, 1), and when a row of data is added between the current data block C1 and the next data block C2 in the moving direction, and the row is added for the second time, the coordinate information of the starting point in the record point information of the data block C2 is updated to (102, 1). The case where columns are added is the same as the case where rows are added, and no description will be given.
If a large number of rows and columns are deleted in the data block, and if only one row of data or one column of data remains in the final data block, for example, the current data block is C1 and the coordinate information of the remaining boundary point is (50, 1), the coordinate information of the start point in the record point information of the next data block C3 in the moving direction of the display page is updated to (50, 1).
If the data block is deleted directly, the recording point information of the next data block in the moving direction of the display page is not changed.
An embodiment of the present application provides a data loading device, as shown in fig. 4, including:
the determining module 41 is configured to monitor that the display page moves to a preset position, and determine recording point information of a data block to be loaded in a moving direction of the display page;
a query module 42, configured to query the record point information of the data block to be loaded from the cache;
and the loading module 43 is configured to load the data block corresponding to the record point information from the cache if the record point information of the data block to be loaded is queried.
Optionally, the determining module 41 is specifically configured to:
acquiring the movement direction of a display page;
determining the recording point information of the next data block in the movement direction of the display page as the recording point information of the data block to be loaded; or alternatively, the process may be performed,
and acquiring the record point information of at least two data blocks adjacent to the data block displayed on the display page, and determining the record point information of the data block to be loaded according to the movement direction of the display page.
Optionally, the loading module 43 is further configured to:
and if the record point information of the data block to be loaded is not queried, acquiring and loading the data block to be loaded from the background based on the record point information of the data block to be loaded.
Optionally, the recording point information is coordinate information of at least one boundary point of the data block.
Optionally, the apparatus further comprises: a monitoring module 44, the monitoring module 44 being configured to:
if the change of the record point information in any data block on the display page is monitored, updating the record point information corresponding to the data block in the cache based on the changed record point information.
Optionally, the monitoring module 44 is specifically configured to:
if the changed data block has more than two boundary points, updating the record point information corresponding to the data block in the cache by utilizing the coordinate information of the more than two boundary points;
if the changed data block only has one boundary point, updating the record point information corresponding to the data block and the record point information corresponding to the next data block along the movement direction of the display page in the cache by utilizing the coordinate information of the boundary point;
and if the changed data block does not have the boundary point, deleting the record point information corresponding to the data block in the cache.
Optionally, the movement direction includes upward, downward, leftward and rightward.
Corresponding to the data loading method in fig. 1, the embodiment of the present application further provides a computer device 500, as shown in fig. 5, where the device includes a memory 501, a processor 502, and a computer program stored in the memory 501 and capable of running on the processor 502, where the processor 702 implements the data loading method when executing the computer program.
Specifically, the above memory 501 and the processor 502 may be general-purpose memories and processors, which are not limited herein, and when the processor 502 runs a computer program stored in the memory 501, the above data loading method may be executed, so as to solve the problem of slow display data in the prior art, after detecting that the display page moves to a preset position, determine the recording point information of the data block to be loaded in the moving direction of the display page, and after determining that the determined recording point information exists in the buffer, load the data block corresponding to the recording point information from the buffer. Therefore, by storing the loaded data blocks and the recording points of the corresponding data blocks in the cache, when a user requests the loaded data blocks again, the data can be directly obtained from the cache through the recording point information of the data blocks to be loaded instead of obtaining the data from the background, so that the throughput and the pressure of the background are reduced, the display speed of the front end is improved, and the blocking of pages is reduced.
Corresponding to the data loading method in fig. 1, the embodiment of the present application further provides a computer readable storage medium, on which a computer program is stored, which when being executed by a processor, performs the steps of the data loading method described above.
Specifically, the storage medium can be a general storage medium, such as a mobile disk, a hard disk, and the like, and when a computer program on the storage medium is run, the above-mentioned data loading method can be executed, so that the problem of slow display data in the prior art is solved, after the display page is monitored to move to a preset position, recording point information of a data block to be loaded in the moving direction of the display page is determined, and after the determined recording point information exists in a cache, the data block corresponding to the recording point information is loaded from the cache. Therefore, by storing the loaded data blocks and the recording points of the corresponding data blocks in the cache, when a user requests the loaded data blocks again, the data can be directly obtained from the cache through the recording point information of the data blocks to be loaded instead of obtaining the data from the background, so that the throughput and the pressure of the background are reduced, the display speed of the front end is improved, and the blocking of pages is reduced.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus and method may be implemented in other manners. The above-described apparatus embodiments are merely illustrative, for example, the division of the units is merely a logical function division, and there may be other manners of division in actual implementation, and for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some communication interface, device or unit indirect coupling or communication connection, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments provided in the present invention may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
It should be noted that: like reference numerals and letters in the following figures denote like items, and thus once an item is defined in one figure, no further definition or explanation of it is required in the following figures, and furthermore, the terms "first," "second," "third," etc. are used merely to distinguish one description from another and are not to be construed as indicating or implying relative importance.
Finally, it should be noted that: the above examples are only specific embodiments of the present invention, and are not intended to limit the scope of the present invention, but it should be understood by those skilled in the art that the present invention is not limited thereto, and that the present invention is described in detail with reference to the foregoing examples: any person skilled in the art may modify or easily conceive of the technical solution described in the foregoing embodiments, or perform equivalent substitution of some of the technical features, while remaining within the technical scope of the present disclosure; such modifications, changes or substitutions do not depart from the spirit and scope of the corresponding technical solutions. Are intended to be encompassed within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (8)

1. A method of loading data, the method comprising:
monitoring that the display page moves to a preset position, and determining the information of the recording point of the data block to be loaded in the movement direction of the display page;
inquiring the record point information of the data block to be loaded from the cache;
if the record point information of the data block to be loaded is queried, loading the data block corresponding to the record point information from a cache;
the determining the record point information of the data block to be loaded in the motion direction of the current display page comprises the following steps:
acquiring the movement direction of a display page;
determining the recording point information of the next data block in the movement direction of the display page as the recording point information of the data block to be loaded; or alternatively, the process may be performed,
and acquiring the record point information of at least two data blocks adjacent to the data block displayed on the display page, and determining the record point information of the data block to be loaded according to the movement direction of the display page.
2. The method of claim 1, wherein the method further comprises:
and if the record point information of the data block to be loaded is not queried, acquiring and loading the data block to be loaded from the background based on the record point information of the data block to be loaded.
3. A method according to any one of claims 1-2, wherein the recorded point information is coordinate information of at least one boundary point of the data block.
4. A method as recited in claim 3, further comprising:
if the change of the record point information in any data block on the display page is monitored, updating the record point information corresponding to the data block in the cache based on the changed record point information.
5. The method of claim 4, wherein if it is detected that the record point information in any data block on the display page changes, updating record point information corresponding to the data block in the cache based on the changed record point information comprises:
if the changed data block has more than two boundary points, updating the record point information corresponding to the data block in the cache by utilizing the coordinate information of the more than two boundary points;
if the changed data block only has one boundary point, updating the record point information corresponding to the data block and the record point information corresponding to the next data block along the movement direction of the display page in the cache by utilizing the coordinate information of the boundary point;
and if the changed data block does not have the boundary point, deleting the record point information corresponding to the data block in the cache.
6. The method of claim 1, wherein the direction of motion comprises up, down, left, and right.
7. A data loading device, the device comprising:
the determining module is used for monitoring that the display page moves to a preset position and determining the record point information of the data block to be loaded in the moving direction of the display page;
the query module is used for querying the record point information of the data block to be loaded from the cache;
the loading module is used for loading the data block corresponding to the record point information from the cache if the record point information of the data block to be loaded is queried;
the determining module is specifically configured to:
acquiring the movement direction of a display page;
determining the recording point information of the next data block in the movement direction of the display page as the recording point information of the data block to be loaded; or alternatively, the process may be performed,
and acquiring the record point information of at least two data blocks adjacent to the data block displayed on the display page, and determining the record point information of the data block to be loaded according to the movement direction of the display page.
8. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any of the preceding claims 1 to 6 when the computer program is executed.
CN201810840965.XA 2018-07-27 2018-07-27 Data loading method and device Active CN110765377B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810840965.XA CN110765377B (en) 2018-07-27 2018-07-27 Data loading method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810840965.XA CN110765377B (en) 2018-07-27 2018-07-27 Data loading method and device

Publications (2)

Publication Number Publication Date
CN110765377A CN110765377A (en) 2020-02-07
CN110765377B true CN110765377B (en) 2023-05-23

Family

ID=69328003

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810840965.XA Active CN110765377B (en) 2018-07-27 2018-07-27 Data loading method and device

Country Status (1)

Country Link
CN (1) CN110765377B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104615348A (en) * 2015-01-12 2015-05-13 联想(北京)有限公司 Information processing method and electronic equipment
CN104735518A (en) * 2015-03-31 2015-06-24 北京奇艺世纪科技有限公司 Information display method and device
CN105989012A (en) * 2015-01-28 2016-10-05 深圳市腾讯计算机系统有限公司 Page display method, device, mobile terminal and system
WO2017107834A1 (en) * 2015-12-21 2017-06-29 北京奇虎科技有限公司 Page switching method and apparatus, computer program, and readable medium
CN107145528A (en) * 2017-04-14 2017-09-08 北京趣拿软件科技有限公司 Update method, the apparatus and system of cache file
CN107168963A (en) * 2016-03-07 2017-09-15 阿里巴巴集团控股有限公司 The page loading of client and caching method, system and the client of the page

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104615348A (en) * 2015-01-12 2015-05-13 联想(北京)有限公司 Information processing method and electronic equipment
CN105989012A (en) * 2015-01-28 2016-10-05 深圳市腾讯计算机系统有限公司 Page display method, device, mobile terminal and system
CN104735518A (en) * 2015-03-31 2015-06-24 北京奇艺世纪科技有限公司 Information display method and device
WO2017107834A1 (en) * 2015-12-21 2017-06-29 北京奇虎科技有限公司 Page switching method and apparatus, computer program, and readable medium
CN107168963A (en) * 2016-03-07 2017-09-15 阿里巴巴集团控股有限公司 The page loading of client and caching method, system and the client of the page
CN107145528A (en) * 2017-04-14 2017-09-08 北京趣拿软件科技有限公司 Update method, the apparatus and system of cache file

Also Published As

Publication number Publication date
CN110765377A (en) 2020-02-07

Similar Documents

Publication Publication Date Title
CN109032457B (en) Page display method, device, terminal and storage medium
US10606806B2 (en) Method and apparatus for storing time series data
CN106528587B (en) Page display method and device in composite webpage system
CN107247748B (en) Page loading method and device
CN105549936B (en) Data table display method and device
US20180300250A1 (en) Method and apparatus for storing data
EP3408752B1 (en) Object management and visualization using a computing device
CN112580315A (en) Webpage table display method and device, terminal equipment and medium
CN103455547B (en) A kind of method and device for webpage loading
CN108733716A (en) Picture preloads method, apparatus, electronic equipment and readable storage medium storing program for executing
CN112487871B (en) Handwriting data processing method and device and electronic equipment
CN106339183B (en) Data retrieval method and server
CN111949354B (en) Page content updating method and device
CN113204401A (en) Browser rendering method, terminal and storage medium
CN110765377B (en) Data loading method and device
CN104408056B (en) Data processing method and device
CN109213972B (en) Method, device, equipment and computer storage medium for determining document similarity
CN114036431A (en) Page cache skipping method and device, electronic equipment and storage medium
CN113988007A (en) Text display method and device, electronic equipment and storage medium
CN109032476B (en) Method for displaying big data set in graphical user interface
CN107741992B (en) Network storage method and device for conference records, intelligent tablet and storage medium
CN112131840A (en) Page processing method, device, storage medium and processor
CN108182202B (en) Content update notification method, content update notification device, electronic equipment and storage medium
CN111881281A (en) Log processing method, device, equipment and medium
CN110263212B (en) Method and device for sharing search results

Legal Events

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