CN115328366B - Tens of millions of tree node searching and displaying method and system based on full path calculation - Google Patents

Tens of millions of tree node searching and displaying method and system based on full path calculation Download PDF

Info

Publication number
CN115328366B
CN115328366B CN202210962345.XA CN202210962345A CN115328366B CN 115328366 B CN115328366 B CN 115328366B CN 202210962345 A CN202210962345 A CN 202210962345A CN 115328366 B CN115328366 B CN 115328366B
Authority
CN
China
Prior art keywords
node
child nodes
data
record
path information
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
CN202210962345.XA
Other languages
Chinese (zh)
Other versions
CN115328366A (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 Smart Starlight Information Technology Co ltd
Original Assignee
Beijing Smart Starlight Information 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 Smart Starlight Information Technology Co ltd filed Critical Beijing Smart Starlight Information Technology Co ltd
Priority to CN202210962345.XA priority Critical patent/CN115328366B/en
Publication of CN115328366A publication Critical patent/CN115328366A/en
Application granted granted Critical
Publication of CN115328366B publication Critical patent/CN115328366B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/31Indexing; Data structures therefor; Storage structures
    • G06F16/316Indexing structures
    • G06F16/322Trees
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • Software Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention provides a tens of millions of tree node searching and displaying method and system based on full path calculation. The tens of millions of tree node searching and displaying method comprises the following steps: filtering the checked record data, deleting the covered checked record, and obtaining the data with the covered checked record deleted; carrying out data variable initialization processing on the data of which the covered check records are deleted; and performing cyclic processing on the node list checking state. The tens of millions of tree node search display system comprises: the filtering module is used for filtering the check record data and deleting the covered check record to obtain the data with the covered check record deleted; the initialization processing module is used for carrying out data variable initialization processing on the data of which the covered check records are deleted; and the circulation processing module is used for performing circulation processing on the node list checking state.

Description

Tens of millions of tree node searching and displaying method and system based on full path calculation
Technical Field
The invention provides a tens of millions of tree node searching and displaying method and system based on full path calculation, and belongs to the technical field of big data text processing.
Background
The presentation and operation of tree structures is a common scenario in a variety of applications. But for massive tree nodes, such as: the depth of the tree reaches 20 levels, the breadth of the child nodes reaches 100 ten thousand, and the number of the rendering of the mass nodes is practically limited by the browser performance of a specific user terminal due to the limited number of the Dom nodes which can be rendered by the PC end browser at one time.
The common technical means is that the front end uses the open source library z-tree, elementui-tree or asynchronous lazy loading and other modes to solve the problem of loading large data volume; if the user needs to search, select/cancel, select, fold, etc. the nodes of the tree, the automatic linkage problem of a large number of parent-child nodes needs to be executed, and the back end has more abundant computing resources compared with the limited computing power of the front end of the browser. It is still very time consuming to traverse the state of updating tens of millions of nodes at a time.
Disclosure of Invention
The invention provides a method and a system for searching and displaying ten-million-level tree nodes based on full-path calculation, which are used for solving the problems that in the prior art, a large number of father-child nodes cannot be automatically linked and the update time of the states of the ten-million-level nodes is relatively long, and the adopted technical scheme is as follows:
the tens of millions of tree node searching and displaying method based on full path calculation comprises the following steps:
filtering the checked record data, deleting the covered checked record, and obtaining the data with the covered checked record deleted;
carrying out data variable initialization processing on the data of which the covered check records are deleted;
and performing cyclic processing on the node list checking state.
Further, the filtering the check record data, deleting the covered check record includes:
receiving the checking record data, and acquiring node full-path information of the label through the checking record data;
the node full-path information of the label is sent to a loop module for skip processing;
and after receiving the node full-path information of the label, the loop module determines whether to clear the selected record or not in a double-cycle data processing mode.
Further, after the loop module receives the node full path information of the label, determining whether to clear the selected record in a dual cycle data processing mode includes:
the sub-loop judges whether the current node of the parent loop is deleted in the node full path information in the latest operation record, and if the current node of the parent loop is deleted in the node full path information in the latest operation record, the selected record corresponding to the checked record data is cleared;
if the node full path information of the current node of the parent level circulation in the latest operation record is not deleted, judging whether all child nodes of each node are deselected; if all the child nodes of each node are deselected, clearing the selected record corresponding to the selected record data;
and if all the child nodes of each node are not deselected, feeding the data back to the loop module to obtain the data of which the covered and checked records are deleted.
Further, performing data variable initialization processing on the data of which the covered check records are deleted, including:
selecting node ID and node full path information, dividing the selected node full path information into single node ID, and carrying out sub node selection aiming at each node in the node full path information;
the method comprises the steps of deselecting node IDs and full path information of selected nodes, dividing the full path information of the deselected nodes into single IDs, and conducting sub-node deselection aiming at each node in the full path information of the nodes.
Further, the performing the loop processing on the node list checking state includes:
judging whether all child nodes under a father node are not selected, if so, determining that the father node is in a full selection state;
judging whether all child nodes under the father node are deselected, if so, determining that the father node is in an unselected state;
judging whether a deselected child node exists in the child nodes under the father node, and if the deselected child node exists, determining that the father node is in a half-selected state;
judging whether all the next-stage N-layer child nodes corresponding to the child nodes are selected aiming at the unselected child nodes, and if the next-stage N-layer child nodes are in all selected states, determining that the child nodes corresponding to the next-stage N-layer child nodes are in all selected states;
if the next level N layer child node is not in all selected states, judging whether the next level N layer child node is all deselected; if all the next level N layer child nodes are deselected, determining that the child nodes are in an unselected state;
if all the sub-nodes of the next level N layer are not deselected, three-condition judgment is carried out, and if any one judgment condition is met in the three-condition judgment, the sub-node corresponding to the sub-node of the next level N layer is determined to be in a half-selected state;
wherein, the three conditions are judged as follows:
judging whether a parent node corresponding to the child node is in an unchecked state or not;
judging whether the number of the sub-nodes is larger than 0 or not;
and thirdly, judging whether the number of the sub-node hooks is smaller than the total number of the sub-nodes.
Further, the tens of millions of tree node search presentation system includes:
the filtering module is used for filtering the check record data and deleting the covered check record to obtain the data with the covered check record deleted;
the initialization processing module is used for carrying out data variable initialization processing on the data of which the covered check records are deleted;
and the circulation processing module is used for performing circulation processing on the node list checking state.
Further, the filter module includes:
the receiving module is used for receiving the check record data and acquiring node full-path information of the label through the check record data;
the jump processing module is used for sending the node full-path information of the label to the loop module for jump processing;
and the double-circulation data module is used for determining whether the selected record is to be cleared or not through a double-circulation data processing mode after the loop module receives the node full-path information of the label.
Further, the dual cycle data module includes:
the first circulation sub-module is used for judging whether the current node of the parent circulation is deleted in the node full path information in the latest operation record or not in a sub-circulation mode, and if the current node of the parent circulation is deleted in the node full path information in the latest operation record, the selected record corresponding to the checked record data is cleared;
the second circulation sub-module is used for judging whether all the sub-nodes of each node are deselected if the node full path information of the current node of the parent level circulation in the latest operation record is not deleted; if all the child nodes of each node are deselected, clearing the selected record corresponding to the selected record data;
and the feedback module is used for feeding back the data to the loop module if all the child nodes of each node are not deselected, and obtaining the data of which the covered and checked records are deleted.
Further, the initialization processing module includes:
the node selection processing module is used for selecting node IDs and node full-path information, dividing the selected node full-path information into single node IDs, and carrying out sub-node selection aiming at each node in the node full-path information;
and the node cancel processing module is used for canceling the selected node ID and the selected node full-path information, dividing the canceled node full-path information into single IDs, and canceling and picking the child node for each node in the node full-path information.
Further, the loop processing module includes:
the first judging module is used for judging whether the child nodes under the father node are all not selected, and if the child nodes are all selected, determining that the father node is in a full-selection state;
the second judging module is used for judging whether all the child nodes under the father node are deselected, and if the child nodes are all deselected, determining that the father node is in an unselected state;
a third judging module, configured to judge whether a deselected child node exists in child nodes under the parent node, and if the deselected child node exists, determine that the parent node is in a half-selected state;
a fourth judging module, configured to judge, for unselected child nodes, whether all the next-stage N-layer child nodes corresponding to the child nodes are selected, and if the next-stage N-layer child nodes are all selected, determine that the child nodes corresponding to the next-stage N-layer child nodes are all selected;
a fifth judging module, configured to judge whether the next-stage N-layer child node is all deselected if the next-stage N-layer child node is not all selected; if all the next level N layer child nodes are deselected, determining that the child nodes are in an unselected state;
a sixth judging module, configured to perform three-condition judgment if all the next-stage N-layer child nodes are not deselected, and determine that the child node corresponding to the next-stage N-layer child node is in a half-selected state if any one of the three-condition judgment conditions is satisfied;
wherein, the three conditions are judged as follows:
judging whether a parent node corresponding to the child node is in an unchecked state or not;
judging whether the number of the sub-nodes is larger than 0 or not;
and thirdly, judging whether the number of the sub-node hooks is smaller than the total number of the sub-nodes.
The invention has the beneficial effects that:
the method and the system for searching and displaying the tree nodes based on the full path computation adopt a mode of combining front end part display with back end part computation, so that operation of a user for inquiring, associatively choosing, acquiring a designated node and the like with ten-millions of tree-shaped subordinate structure nodes through a UI (user interface) reaches second-level response is possible.
Drawings
FIG. 1 is a schematic diagram of a method and system for tens of millions of tree node search display in accordance with the present invention;
FIG. 2 is a flow chart of a method for tens of millions of tree node search presentation according to the present invention;
FIG. 3 is a system block diagram of a tens of millions of tree node search display system according to the present invention;
fig. 4 is a schematic diagram of a front end interface of the tens of millions of tree node search display system according to the present invention.
Detailed Description
The preferred embodiments of the present invention will be described below with reference to the accompanying drawings, it being understood that the preferred embodiments described herein are for illustration and explanation of the present invention only, and are not intended to limit the present invention.
The embodiment of the invention provides a tens of millions of tree node searching and displaying method based on full path calculation, which comprises the following steps of:
s1, filtering the checked record data, deleting the covered checked record, and obtaining the data with the covered checked record deleted;
s2, carrying out data variable initialization processing on the data of which the covered check records are deleted;
s3, performing cyclic processing on the node list checking state.
The filtering and checking the record data in the step S1, deleting the covered checked record, includes:
s101, receiving the check record data, and acquiring node Full Path information (Full Path) of a label through the check record data; the node full path information is to record paths from the root node to the current node according to the sequence;
s102, sending the node full-path information of the label to a loop module for skip processing;
and S103, after the loop module receives the node full-path information of the label, determining whether to clear the selected record or not in a double-cycle data processing mode.
After receiving the node full path information of the label, the loop module in step S103 determines whether to clear the selected record in a dual cycle data processing manner, including:
s1031, the sub-loop judges whether the current node of the parent loop is deleted in the node full path information in the latest operation record, and if the current node of the parent loop is deleted in the node full path information in the latest operation record, the selected record corresponding to the checked record data is cleared;
s1032, if the node full path information of the current node of the parent level cycle in the latest operation record is not deleted, judging whether all the child nodes of each node are deselected; if all the child nodes of each node are deselected, clearing the selected record corresponding to the selected record data;
s1033, if all the child nodes of each node are not deselected, feeding the data back to the loop module, and obtaining the data of which the covered and checked records are deleted.
The step S2 of initializing the data variable for the data of which the covered and checked records are deleted includes:
s201, selecting node IDs and node full-path information, dividing the selected node full-path information into single node IDs, and carrying out sub-node selection aiming at each node in the node full-path information;
s202, deselecting node IDs and full path information of selected nodes, dividing the full path information of the deselected nodes into single IDs, and performing sub-node deselection for each node in the full path information of the nodes.
In the step S3, the performing a loop process on the node list checking state includes:
s301, judging whether all child nodes under a father node are not selected, and if all child nodes are selected, determining that the father node is in a full selection state;
s302, judging whether all child nodes under the father node are deselected, and if all child nodes are deselected, determining that the father node is in an unselected state;
s303, judging whether a deselected child node exists in the child nodes under the father node, and if so, determining that the father node is in a half-selected state;
s304, aiming at unselected child nodes, judging whether all the next-stage N-layer child nodes corresponding to the child nodes are selected, and if the next-stage N-layer child nodes are in all selected states, determining that the child nodes corresponding to the next-stage N-layer child nodes are in all selected states;
s305, if the next level N layer child node is not in all selected state, judging whether the next level N layer child node is all deselected; if all the next level N layer child nodes are deselected, determining that the child nodes are in an unselected state;
s306, if all the sub-nodes of the next level N layer are not deselected, performing three-condition judgment, and if any one of the three-condition judgment is met, determining that the sub-node corresponding to the sub-node of the next level N layer is in a half-selected state;
wherein, the three conditions are judged as follows:
judging whether a parent node corresponding to the child node is in an unchecked state or not;
judging whether the number of the sub-nodes is larger than 0 or not;
and thirdly, judging whether the number of the sub-node hooks is smaller than the total number of the sub-nodes.
The ten-million-level tree node searching and displaying method based on full path calculation, which is provided by the embodiment, adopts a mode of combining front end part display with back end part calculation, so that operation of reaching second-level response of a user on operation of ten-million-level (for example, tree depth <20 levels, breadth <100 ten thousand) tree-dependent structure nodes through a UI interface is possible. Moreover, by adopting tree-shaped display, each child node adopts lazy loading, and the linkage of father and child nodes in the hooking (full selection, single selection and reverse selection) process cannot be solved, namely:
(1) If the father node is checked, all the child nodes are automatically checked;
(2) If the parent node is not selected, all the child nodes are automatically selected;
(3) All child nodes are checked, and the father node automatically changes into a checked state;
(4) A part of child nodes are hooked, and the father node automatically changes into a half-selected state;
(5) All the child nodes are cancelled, and the father node automatically changes into an unchecked state;
(6) The rule is validated in recursion, for example, in (1), the child nodes from the lower 1 level to the N level of the child nodes are also automatically validated; otherwise, in the upper 1 level of the parent nodes in example (3), the parent nodes of the upper N level also automatically recursively take effect.
The embodiment of the invention provides a tens of millions of tree node searching and displaying system based on full path calculation, as shown in fig. 1 and 3, the system based on the tens of millions of tree node searching and displaying comprises:
the filtering module is used for filtering the check record data and deleting the covered check record to obtain the data with the covered check record deleted;
the initialization processing module is used for carrying out data variable initialization processing on the data of which the covered check records are deleted;
and the circulation processing module is used for performing circulation processing on the node list checking state.
Wherein, the filtration module includes:
the receiving module is used for receiving the check record data and acquiring node full-path information of the label through the check record data;
the jump processing module is used for sending the node full-path information of the label to the loop module for jump processing;
and the double-circulation data module is used for determining whether the selected record is to be cleared or not through a double-circulation data processing mode after the loop module receives the node full-path information of the label.
The dual cycle data module includes:
the first circulation sub-module is used for judging whether the current node of the parent circulation is deleted in the node full path information in the latest operation record or not in a sub-circulation mode, and if the current node of the parent circulation is deleted in the node full path information in the latest operation record, the selected record corresponding to the checked record data is cleared;
the second circulation sub-module is used for judging whether all the sub-nodes of each node are deselected if the node full path information of the current node of the parent level circulation in the latest operation record is not deleted; if all the child nodes of each node are deselected, clearing the selected record corresponding to the selected record data;
and the feedback module is used for feeding back the data to the loop module if all the child nodes of each node are not deselected, and obtaining the data of which the covered and checked records are deleted.
The initialization processing module comprises:
the node selection processing module is used for selecting node IDs and node full-path information, dividing the selected node full-path information into single node IDs, and carrying out sub-node selection aiming at each node in the node full-path information;
and the node cancel processing module is used for canceling the selected node ID and the selected node full-path information, dividing the canceled node full-path information into single IDs, and canceling and picking the child node for each node in the node full-path information.
The cyclic processing module includes:
the first judging module is used for judging whether the child nodes under the father node are all not selected, and if the child nodes are all selected, determining that the father node is in a full-selection state;
the second judging module is used for judging whether all the child nodes under the father node are deselected, and if the child nodes are all deselected, determining that the father node is in an unselected state;
a third judging module, configured to judge whether a deselected child node exists in child nodes under the parent node, and if the deselected child node exists, determine that the parent node is in a half-selected state;
a fourth judging module, configured to judge, for unselected child nodes, whether all the next-stage N-layer child nodes corresponding to the child nodes are selected, and if the next-stage N-layer child nodes are all selected, determine that the child nodes corresponding to the next-stage N-layer child nodes are all selected;
a fifth judging module, configured to judge whether the next-stage N-layer child node is all deselected if the next-stage N-layer child node is not all selected; if all the next level N layer child nodes are deselected, determining that the child nodes are in an unselected state;
a sixth judging module, configured to perform three-condition judgment if all the next-stage N-layer child nodes are not deselected, and determine that the child node corresponding to the next-stage N-layer child node is in a half-selected state if any one of the three-condition judgment conditions is satisfied;
wherein, the three conditions are judged as follows:
judging whether a parent node corresponding to the child node is in an unchecked state or not;
judging whether the number of the sub-nodes is larger than 0 or not;
and thirdly, judging whether the number of the sub-node hooks is smaller than the total number of the sub-nodes.
The specific working principle and implementation process of the technical scheme comprise the following steps: in this embodiment, as shown in fig. 4, the front end interface of the millions of tree node search display system includes a hook and a counter, where the hook states of the lower and upper levels are all calculated from the node full path information, and the full path data structure is as follows:
the total node number is stored in a relational database (for example, mySql, postgreSQL) to reach tens of millions, the depth is within 8 levels (the depth can be enlarged according to the service scene), the method is not limited in breadth (100 tens of thousands can be supported according to the service scene and brother child nodes), and searching, hooking and lower-level unfolding operations of any level are completed within 1-2 seconds.
The processing of the service end of the back end is as follows:
and checking the recorded data, and returning to the checked state of the part of nodes currently displayed by the client.
Step 1, filtering and checking recorded data, and specifically:
step 101, re-ordering the checked record data according to the reverse order;
102, judging each check record, pre-storing a check record data with node full path information of the nodes; deleting the current check record data from the pre-stored data according to whether the current node ID is contained or not;
step 103, synchronizing the parent node to check the state, clearing the checked parent node and canceling the check record data of all the child nodes.
Step 2, initializing variables, and storing data for calculation, specifically:
step 201, storing the selected node ID and the unselected node ID separately;
step 202, storing node full path information corresponding to the selected node and the unselected node separately;
step 203, dividing the node full path information corresponding to the selected node and the unselected node into independent node IDs and storing the independent node IDs separately;
and 204, calculating the number of sub-node hooks and the number of de-hooks of each node through the independent node IDs of the selected node and the de-selected node after node full-path information segmentation, and storing the sub-node hooks and the number of de-hooks separately.
Step 3, circulating processing node list (calculating full selection, half selection and unselected state)
The logic in a specific cycle is as follows:
a. judging whether all the child nodes are selected, if so, the nodes are fully selected;
b. judging whether all the child nodes are deselected, if so, the child nodes are unselected;
c. judging whether a sub node which is deselected exists under the node, and if so, judging that the sub node is half-selected;
d. when the node is not selected, judging whether all the N-level nodes in the inner node are selected, and recalculating the checking state;
e. if all the N-level nodes in the inner node are deselected, recalculating the hook state;
f. if its node is not hooked and its number of child nodes is >0 and its number of child nodes is selected < its total number of child nodes, its node is half-selected.
The technical scheme has the effects that: the ten-million-level tree node searching and displaying system based on full path calculation, provided by the embodiment, adopts a mode of combining front end part display with back end part calculation, so that operation of reaching second-level response of a user on operation of ten-million-level (for example, tree depth <20 levels, tree breadth <100 ten thousand) tree-dependent structure nodes through a UI interface is possible. Moreover, by adopting tree-shaped display, each child node adopts lazy loading, and the linkage of father and child nodes in the hooking (full selection, single selection and reverse selection) process cannot be solved, namely:
(1) If the father node is checked, all the child nodes are automatically checked;
(2) If the parent node is not selected, all the child nodes are automatically selected;
(3) All child nodes are checked, and the father node automatically changes into a checked state;
(4) A part of child nodes are hooked, and the father node automatically changes into a half-selected state;
(5) All the child nodes are cancelled, and the father node automatically changes into an unchecked state;
(6) The rule is validated in recursion, for example, in (1), the child nodes from the lower 1 level to the N level of the child nodes are also automatically validated; otherwise, in the upper 1 level of the parent nodes in example (3), the parent nodes of the upper N level also automatically recursively take effect.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present invention without departing from the spirit or scope of the invention. Thus, it is intended that the present invention also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.

Claims (7)

1. The tens of millions of tree node searching and displaying method based on full path calculation is characterized by comprising the following steps:
receiving the hook record data, wherein the hook record data comprises node full path information;
filtering the checked record data, deleting the covered checked record, and obtaining the data with the covered checked record deleted;
carrying out data variable initialization processing on the data of which the covered check records are deleted;
performing cyclic processing on the node list checking state;
the filtering and checking record data, deleting the covered checked record, includes:
receiving the checking record data, and acquiring node full-path information of the label through the checking record data;
the node full-path information of the label is sent to a loop module for skip processing;
after receiving node full-path information of the label, the loop module determines whether to clear the selected record or not in a double-cycle data processing mode;
after receiving the node full path information of the label, the loop module determines whether to clear the selected record in a double-cycle data processing mode, and the method comprises the following steps:
the sub-loop judges whether the current node of the parent loop is deleted in the node full path information in the latest operation record, and if the current node of the parent loop is deleted in the node full path information in the latest operation record, the selected record corresponding to the checked record data is cleared;
if the node full path information of the current node of the parent level circulation in the latest operation record is not deleted, judging whether all child nodes of each node are deselected; if all the child nodes of each node are deselected, clearing the selected record corresponding to the selected record data;
if all the child nodes of each node are not deselected, feeding the data back to a loop module to obtain the data of which the covered check records are deleted;
the loop processing for the node list checking state comprises the following steps:
judging whether all child nodes under a father node are not selected, if so, determining that the father node is in a full selection state;
judging whether all child nodes under the father node are deselected, if so, determining that the father node is in an unselected state;
judging whether a deselected child node exists in the child nodes under the father node, and if the deselected child node exists, determining that the father node is in a half-selected state;
judging whether all the next-stage N-layer child nodes corresponding to the child nodes are selected aiming at the unselected child nodes, and if the next-stage N-layer child nodes are in all selected states, determining that the child nodes corresponding to the next-stage N-layer child nodes are in all selected states;
if the next level N layer child node is not in all selected states, judging whether the next level N layer child node is all deselected; if all the next level N layer child nodes are deselected, determining that the child nodes are in an unselected state;
if all the sub-nodes of the next level N layer are not deselected, three-condition judgment is carried out, and if any one judgment condition is met in the three-condition judgment, the sub-node corresponding to the sub-node of the next level N layer is determined to be in a half-selected state;
wherein, the three conditions are judged as follows:
judging whether a parent node corresponding to the child node is in an unchecked state or not;
judging whether the number of the sub-nodes is larger than 0 or not;
and thirdly, judging whether the number of the sub-node hooks is smaller than the total number of the sub-nodes.
2. The ten-million-level tree node search presentation method of claim 1, wherein performing a data variable initialization process for the data from which the covered tick records are deleted, comprises:
selecting a node ID and a node full path, dividing the selected node full path into single node IDs, and carrying out sub-node hook selection on each node in the node full path information;
the method comprises the steps of deselecting node IDs and full path information of selected nodes, dividing the full path information of the deselected nodes into single IDs, and conducting sub-node deselection aiming at each node in the full path information of the nodes.
3. A ten-millions-level tree node search presentation system based on full path computation for implementing the presentation method as claimed in claim 1 or 2, wherein the ten-millions-level tree node search presentation system comprises:
the filtering module is used for filtering the check record data and deleting the covered check record to obtain the data with the covered check record deleted;
the initialization processing module is used for carrying out data variable initialization processing on the data of which the covered check records are deleted;
and the circulation processing module is used for performing circulation processing on the node list checking state.
4. A tens of millions of tree node search presentation system according to claim 3, wherein said filtering module comprises:
the receiving module is used for receiving the check record data and acquiring node full-path information of the label through the check record data;
the jump processing module is used for sending the node full-path information of the label to the loop module for jump processing;
and the double-circulation data module is used for determining whether the selected record is to be cleared or not through a double-circulation data processing mode after the loop module receives the node full-path information of the label.
5. The multi-level tree node search presentation system of claim 4, wherein the dual cycle data module comprises:
the first circulation sub-module is used for judging whether the current node of the parent circulation is deleted in the node full path information in the latest operation record or not in a sub-circulation mode, and if the current node of the parent circulation is deleted in the node full path information in the latest operation record, the selected record corresponding to the checked record data is cleared;
the second circulation sub-module is used for judging whether all the sub-nodes of each node are deselected if the node full path information of the current node of the parent level circulation in the latest operation record is not deleted; if all the child nodes of each node are deselected, clearing the selected record corresponding to the selected record data;
and the feedback module is used for feeding back the data to the loop module if all the child nodes of each node are not deselected, and obtaining the data of which the covered and checked records are deleted.
6. The multi-level tree node search presentation system of claim 3, wherein the initialization processing module comprises:
the node selection processing module is used for selecting node IDs and node full-path information, dividing the selected node full-path information into single node IDs, and carrying out sub-node selection aiming at each node in the node full-path information;
and the node cancel processing module is used for canceling the selected node ID and the selected node full-path information, dividing the canceled node full-path information into single IDs, and canceling and picking the child node for each node in the node full-path information.
7. The multi-level tree node search presentation system of claim 3, wherein the loop processing module comprises:
the first judging module is used for judging whether the child nodes under the father node are all not selected, and if the child nodes are all selected, determining that the father node is in a full-selection state;
the second judging module is used for judging whether all the child nodes under the father node are deselected, and if the child nodes are all deselected, determining that the father node is in an unselected state;
a third judging module, configured to judge whether a deselected child node exists in child nodes under the parent node, and if the deselected child node exists, determine that the parent node is in a half-selected state;
a fourth judging module, configured to judge, for unselected child nodes, whether all the next-stage N-layer child nodes corresponding to the child nodes are selected, and if the next-stage N-layer child nodes are all selected, determine that the child nodes corresponding to the next-stage N-layer child nodes are all selected;
a fifth judging module, configured to judge whether the next-stage N-layer child node is all deselected if the next-stage N-layer child node is not all selected; if all the next level N layer child nodes are deselected, determining that the child nodes are in an unselected state;
a sixth judging module, configured to perform three-condition judgment if all the next-stage N-layer child nodes are not deselected, and determine that the child node corresponding to the next-stage N-layer child node is in a half-selected state if any one of the three-condition judgment conditions is satisfied;
wherein, the three conditions are judged as follows:
judging whether a parent node corresponding to the child node is in an unchecked state or not;
judging whether the number of the sub-nodes is larger than 0 or not;
and thirdly, judging whether the number of the sub-node hooks is smaller than the total number of the sub-nodes.
CN202210962345.XA 2022-08-11 2022-08-11 Tens of millions of tree node searching and displaying method and system based on full path calculation Active CN115328366B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210962345.XA CN115328366B (en) 2022-08-11 2022-08-11 Tens of millions of tree node searching and displaying method and system based on full path calculation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210962345.XA CN115328366B (en) 2022-08-11 2022-08-11 Tens of millions of tree node searching and displaying method and system based on full path calculation

Publications (2)

Publication Number Publication Date
CN115328366A CN115328366A (en) 2022-11-11
CN115328366B true CN115328366B (en) 2023-09-19

Family

ID=83921149

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210962345.XA Active CN115328366B (en) 2022-08-11 2022-08-11 Tens of millions of tree node searching and displaying method and system based on full path calculation

Country Status (1)

Country Link
CN (1) CN115328366B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116628272B (en) * 2023-07-24 2023-10-20 海看网络科技(山东)股份有限公司 Tree structure node rapid selection method based on vue framework

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1545048A (en) * 2003-11-17 2004-11-10 中兴通讯股份有限公司 Method for implementing tree storage and access by two-dimensional table
US9383905B1 (en) * 2013-07-29 2016-07-05 Veritas Technologies Llc Navigating a large tree structure using summary snippets
CN106897408A (en) * 2017-02-16 2017-06-27 郑州云海信息技术有限公司 It is a kind of to realize the method that quick search tree structure data specifies node subordinate
WO2017124656A1 (en) * 2016-01-22 2017-07-27 中兴通讯股份有限公司 Tree-based selection method and resource management system
CN107431660A (en) * 2015-03-11 2017-12-01 Ntt通信公司 Retrieve device, search method, program and recording medium
CN107689922A (en) * 2017-08-31 2018-02-13 青岛大学 Steiner optimal trees computational methods and device based on particle swarm optimization
CN107783850A (en) * 2017-09-28 2018-03-09 北京天元创新科技有限公司 A kind of node tree chooses analytic method, device, server and the system of record
CN112099778A (en) * 2020-11-13 2020-12-18 北京智慧星光信息技术有限公司 Data acquisition method based on xpath, electronic equipment and storage medium
CN112860692A (en) * 2021-01-29 2021-05-28 城云科技(中国)有限公司 Database table structure conversion method and device and electronic equipment thereof
CN114880041A (en) * 2022-04-20 2022-08-09 北京旷视科技有限公司 Tree structure data processing method, electronic equipment and storage medium

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120120086A1 (en) * 2010-11-16 2012-05-17 Microsoft Corporation Interactive and Scalable Treemap as a Visualization Service
US20180039399A1 (en) * 2014-12-29 2018-02-08 Palantir Technologies Inc. Interactive user interface for dynamically updating data and data analysis and query processing
US11297468B2 (en) * 2018-11-08 2022-04-05 Juganu, Ltd. Efficient multicast group routing across tree-based wireless network

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1545048A (en) * 2003-11-17 2004-11-10 中兴通讯股份有限公司 Method for implementing tree storage and access by two-dimensional table
US9383905B1 (en) * 2013-07-29 2016-07-05 Veritas Technologies Llc Navigating a large tree structure using summary snippets
CN107431660A (en) * 2015-03-11 2017-12-01 Ntt通信公司 Retrieve device, search method, program and recording medium
WO2017124656A1 (en) * 2016-01-22 2017-07-27 中兴通讯股份有限公司 Tree-based selection method and resource management system
CN106897408A (en) * 2017-02-16 2017-06-27 郑州云海信息技术有限公司 It is a kind of to realize the method that quick search tree structure data specifies node subordinate
CN107689922A (en) * 2017-08-31 2018-02-13 青岛大学 Steiner optimal trees computational methods and device based on particle swarm optimization
CN107783850A (en) * 2017-09-28 2018-03-09 北京天元创新科技有限公司 A kind of node tree chooses analytic method, device, server and the system of record
CN112099778A (en) * 2020-11-13 2020-12-18 北京智慧星光信息技术有限公司 Data acquisition method based on xpath, electronic equipment and storage medium
CN112860692A (en) * 2021-01-29 2021-05-28 城云科技(中国)有限公司 Database table structure conversion method and device and electronic equipment thereof
CN114880041A (en) * 2022-04-20 2022-08-09 北京旷视科技有限公司 Tree structure data processing method, electronic equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
网络课程运行中可操作目录树的设计与实现;叶涛;;中国医学教育技术(第06期);600-603 *

Also Published As

Publication number Publication date
CN115328366A (en) 2022-11-11

Similar Documents

Publication Publication Date Title
US11703826B1 (en) Monitoring asset hierarchies based on asset group metrics
US20210342394A1 (en) Defining a graphical visualization along a time-based graph lane using key performance indicators derived from machine data
US11972203B1 (en) Using anchors to generate extraction rules
US10747816B1 (en) Control interface for asset tree monitoring
US8185563B2 (en) Data-visualization system and method
US9390082B1 (en) Generating multiple views of a multidimensional cube
US20060085391A1 (en) Automatic query suggestions
US11461350B1 (en) Control interface for dynamic elements of asset monitoring and reporting system
US20140101591A1 (en) Data visualization techniques
US11132373B1 (en) Decoupled update cycle and disparate search frequency dispatch for dynamic elements of an asset monitoring and reporting system
US9081830B1 (en) Updating a view of a multidimensional cube
US20150310066A1 (en) Processing queries using hybrid access paths
CN115328366B (en) Tens of millions of tree node searching and displaying method and system based on full path calculation
CN109918437A (en) Distributed data processing method, apparatus and data assets management system
US11210278B1 (en) Asset group interface driven by search-derived asset tree hierarchy
CN114219373A (en) Method, system, device and medium for generating digital process visual flow chart
CN116088966A (en) Method and system for loading high-performance tree control
CN111539186B (en) Big data tree component realization method and system applied to HTML5
CN116627418B (en) Multi-level form interface visual generation method and device based on recursion algorithm
US11645285B2 (en) Query engine for recursive searches in a self-describing data system
US20180060374A1 (en) Optimizing column based database table compression
CN101968747B (en) Cluster application management system and application management method thereof
CN108090183B (en) File name display method, device and equipment
US20220291924A1 (en) Calculation engine for performing calculations based on dependencies in a self-describing data system
CN113590914B (en) Information processing method, apparatus, electronic device and storage medium

Legal Events

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