CN105740407A - Tree structure generation method and system - Google Patents

Tree structure generation method and system Download PDF

Info

Publication number
CN105740407A
CN105740407A CN201610061637.0A CN201610061637A CN105740407A CN 105740407 A CN105740407 A CN 105740407A CN 201610061637 A CN201610061637 A CN 201610061637A CN 105740407 A CN105740407 A CN 105740407A
Authority
CN
China
Prior art keywords
data
node
tree structure
segmentation
next node
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.)
Pending
Application number
CN201610061637.0A
Other languages
Chinese (zh)
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.)
Shenzhen Jiachuang Video Technology Co ltd
Original Assignee
Shenzhen Jiachuang Video 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 Shenzhen Jiachuang Video Technology Co ltd filed Critical Shenzhen Jiachuang Video Technology Co ltd
Priority to CN201610061637.0A priority Critical patent/CN105740407A/en
Publication of CN105740407A publication Critical patent/CN105740407A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/901Indexing; Data structures therefor; Storage structures
    • G06F16/9027Trees

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention relates to a tree structure generation method and system. The method comprises the following steps: generating a preset root node on a page, and sending a sectional loading request when a trigger signal of the current node is detected on the page; sending data of a next layer of node of the current node by a server according to the sectional loading request; and after acquiring the data of the next layer of node, generating the data of the next layer of node by the page through a sectional loading manner. According to the method and system, the data of the next layer of node is dynamically loaded when the current node is clicked, and the data of the next layer of node is loaded through the sectional loading manner, so that the speed of the tree structure rendered by the page is greatly improved, the time of waiting for the page loading by the users is decreased and the user experience is enhanced.

Description

Tree structure generates method and system
Technical field
The present invention relates to field of data structures, particularly relate to tree structure and generate method and system.
Background technology
Tree is a kind of important nonlinear data structure, and intuitively, it is the structure that data element (being called node in tree) is organized by branch's relation, such like the tree in nature.Tree construction is widely present in objective world, and family tree and various community organization such as human society all can use tree represenation.Tree is also used widely in computer realm, as, in web page, available tree structure represents the hierarchical relationship of message.In big data quantity situation, the disposable loading tree structure speed of js is slow, causes user to need the pending datas such as cost plenty of time to load, and service efficiency is low, reduces Consumer's Experience sense.
Summary of the invention
The purpose of the embodiment of the present invention is in that to provide tree structure to generate method and system, it is intended to solve disposable loading tree structure causes in prior art speed slowly, the poor problem of waiting time length, Consumer's Experience sense.
Embodiments providing tree structure and generate method, described method comprises the steps:
Generate the root node preset at the page, when the triggering signal of present node being detected on the page, send segmentation load request;
Server, according to segmentation load request, sends the data of next node layer of described present node;
The page, after getting the data of next node layer, generates the data of next node layer described by segmentation load mode.
The embodiment of the present invention provides again tree structure and generates system, and described system includes:
Trigger request unit, for generating the root node preset at the page, when the triggering signal of present node being detected on the page, send segmentation load request;
Transmitting element, for server according to segmentation load request, sends the data of next node layer of described present node;
Loading unit, for the page after getting the data of next node layer, generates the data of next node layer described by segmentation load mode.
The tree structure that the embodiment of the present invention provides generates method and system, it has the beneficial effects that: dynamically load the data of next node layer when clicking present node, the mode simultaneously loaded by segmentation loads the data of next node layer, the speed making the tree structure that page rendering goes out is greatly promoted, decrease the time that user waits that the page loads, improve Consumer's Experience sense.
Accompanying drawing explanation
Fig. 1 generates a kind of flow chart of method for the tree structure that the embodiment of the present invention provides;
Fig. 2 generates the another kind of flow chart of method for the tree structure that the embodiment of the present invention provides;
Fig. 3 generates a kind of structural representation of system for the tree structure that the embodiment of the present invention provides;
Fig. 4 generates the another kind of structural representation of system for the tree structure that the embodiment of the present invention provides.
Detailed description of the invention
In order to make the purpose of the present invention, technical scheme and advantage clearly understand, below in conjunction with drawings and Examples, the present invention is further elaborated.Should be appreciated that specific embodiment described herein is only in order to explain the present invention, is not intended to limit the present invention.
Fig. 1 illustrates that the tree structure that the embodiment of the present invention provides generates a kind of flow chart of method, for the ease of describing, illustrate only the part relevant to the embodiment of the present invention, and the tree structure that the embodiment of the present invention provides generates method, and described method comprises the steps:
Step S11, generates the root node preset at the page, when the triggering signal of present node being detected on the page, sends segmentation load request.
In the present embodiment, segmentation load request includes the segmentation of present node and loads mark, and server, when receiving segmentation load request, loads, according to segmentation, the data that mark obtains next node layer of corresponding present node, carries out corresponding segmentation loading processing.
Step S12, server, according to segmentation load request, sends the data of next node layer of present node.
In the present embodiment, after server receives segmentation load request, obtain the data of next node layer of present node according to segmentation load request, the transmission of the data of this next node layer is carried out loading processing to the page.
Further, in order to accelerate page loading velocity, server sends the data of next node layer of described present node according to segmentation load request, including: according to segmentation load request, obtain the data of next node layer of present node;By the data section of being divided into of next node layer.Specifically, described by the data section of being divided into of next node layer, particularly as follows: according to loading the node number setting quantity, the data of next node layer are divided into the node section of correspondence.
Step S13, the page, after getting the data of next node layer, generates the data of next node layer by segmentation load mode.
In the present embodiment, generated the data of next node layer by segmentation load mode, including: in the load time interval set, load the node number setting quantity.
In embodiments of the present invention, when clicking page present node, just can send request to server, obtain the data of next node layer, the data of next node layer need to first set load time interval and load the node number setting quantity every time when segmentation loads, for instance interval: 300ms (millisecond), load node number: 200 every time, after setting, js (JavaScript) can load node according to above-mentioned attribute segments.
Fig. 2 illustrates that the tree structure that the embodiment of the present invention provides generates method another kind flow chart, for the ease of describing, illustrate only the part relevant to the embodiment of the present invention, and the tree structure that the embodiment of the present invention provides generates method, and described method comprises the steps:
Step S11, generates the root node preset at the page, when the triggering signal of present node being detected on the page, sends segmentation load request.
Step S12, server, according to segmentation load request, sends the data of next node layer of described present node.
Step S13, the page, after getting the data of next node layer, generates the data of next node layer described by segmentation load mode.
Step S14, buffer memory generates the data of next node layer described by segmentation load mode.
In the present embodiment, during in order to prevent each clicking trigger upper layer node to obtain the data of next node layer, all need to reload, cause and repeat to load, waste period of reservation of number, therefore, by the data generating next node layer described already by segmentation load mode are carried out buffer memory, it is prevented that second load.
Fig. 3 illustrates that the tree structure provided into the embodiment of the present invention generates a kind of structural representation of system, for the ease of describing, illustrate only the part relevant to the embodiment of the present invention, the embodiment of the present invention provides tree structure to generate system, and described system includes: trigger request unit 31, transmitting element 32 and loading unit 33.
Specifically, described triggering request unit 31, for generating the root node preset at the page, when the triggering signal of present node being detected on the page, send segmentation load request;Described transmitting element 32, for server according to segmentation load request, sends the data of next node layer of described present node;And described loading unit 33, for the page after getting the data of next node layer, generated the data of next node layer described by segmentation load mode.
In the present embodiment, this segmentation load request includes the segmentation of present node and loads mark, make server when receiving segmentation load request, load, according to segmentation, the data that mark obtains next node layer of corresponding present node, carry out corresponding segmentation loading processing.
Fig. 4 illustrates that the tree structure provided into the embodiment of the present invention generates the another kind of structural representation of system, for the ease of describing, illustrate only the part relevant to the embodiment of the present invention, the tree structure that the embodiment of the present invention provides generates system, and described system includes: trigger request unit 31, transmitting element 32, loading unit 33 and buffer unit 34.
Specifically, described triggering request unit 31, for generating the root node preset at the page, when the triggering signal of present node being detected on the page, send segmentation load request;Described transmitting element 32, for server according to segmentation load request, sends the data of next node layer of described present node;Described loading unit 33, for the page after getting the data of next node layer, generates the data of next node layer described by segmentation load mode;And buffer unit 34, generated the data of next node layer described by segmentation load mode for buffer memory.
Further, transmitting element 32 includes node acquiring unit 321 and node allocation unit 322, specifically: described node acquiring unit 321, for according to segmentation load request, obtaining the data of next node layer of present node;And described node allocation unit 322, for by the data section of being divided into of next node layer.
Further, in order to accelerate page loading velocity, according to segmentation load request, obtain the data of next node layer of present node;By the data section of being divided into of next node layer, particularly as follows: according to loading the node number setting quantity, the data of next node layer are divided into the node section of correspondence.
Further, during in order to prevent each clicking trigger upper layer node to obtain the data of next node layer, all need to reload, cause and repeat to load, waste period of reservation of number, therefore, by the data generating next node layer described already by segmentation load mode are carried out buffer memory, it is prevented that second load.
Above content is in conjunction with concrete preferred implementation further description made for the present invention, it is impossible to assert that specific embodiment of the invention is confined to these explanations.For general technical staff of the technical field of the invention; make some equivalent replacements or obvious modification without departing from the inventive concept of the premise; and performance or purposes are identical, the scope of patent protection that the present invention is determined all should be considered as belonging to by submitted claims.

Claims (10)

1. tree structure generates method, it is characterised in that described method comprises the steps:
Generate the root node preset at the page, when the triggering signal of present node being detected on the page, send segmentation load request;
Server, according to segmentation load request, sends the data of next node layer of described present node;
The page, after getting the data of next node layer, generates the data of next node layer described by segmentation load mode.
2. tree structure generates method as claimed in claim 1, it is characterised in that described segmentation load request includes the segmentation of present node and loads mark.
3. tree structure generates method as claimed in claim 1, it is characterised in that described server, according to segmentation load request, sends the data of next node layer of described present node, including:
According to segmentation load request, obtain the data of next node layer of present node;
By the data section of being divided into of next node layer.
4. tree structure generates method as claimed in claim 3, it is characterised in that described by the data section of being divided into of next node layer, particularly as follows:
According to loading the node number setting quantity, the data of next node layer are divided into the node section of correspondence.
5. tree structure generates method as claimed in claim 1, it is characterised in that the described data being generated next node layer described by segmentation load mode, including:
In the load time interval set, load the node number setting quantity.
6. tree structure generates method as claimed in claim 1, it is characterised in that described method also includes:
Buffer memory generates the data of next node layer described by segmentation load mode.
7. tree structure generates system, it is characterised in that described system includes:
Trigger request unit, for generating the root node preset at the page, when the triggering signal of present node being detected on the page, send segmentation load request;
Transmitting element, for server according to segmentation load request, sends the data of next node layer of described present node;
Loading unit, for the page after getting the data of next node layer, generates the data of next node layer described by segmentation load mode.
8. tree structure generates system as claimed in claim 7, it is characterised in that described segmentation load request includes the segmentation of present node and loads mark.
9. tree structure generates system as claimed in claim 7, it is characterised in that described transmitting element includes node acquiring unit and node allocation unit, specifically:
Described node acquiring unit, for according to segmentation load request, obtaining the data of next node layer of present node;And described node allocation unit, for by the data section of being divided into of next node layer.
10. tree structure generates system as claimed in claim 7, it is characterised in that described system also includes buffer unit, is generated the data of next node layer described by segmentation load mode for buffer memory.
CN201610061637.0A 2016-01-28 2016-01-28 Tree structure generation method and system Pending CN105740407A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610061637.0A CN105740407A (en) 2016-01-28 2016-01-28 Tree structure generation method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610061637.0A CN105740407A (en) 2016-01-28 2016-01-28 Tree structure generation method and system

Publications (1)

Publication Number Publication Date
CN105740407A true CN105740407A (en) 2016-07-06

Family

ID=56246973

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610061637.0A Pending CN105740407A (en) 2016-01-28 2016-01-28 Tree structure generation method and system

Country Status (1)

Country Link
CN (1) CN105740407A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107844354A (en) * 2017-10-25 2018-03-27 王宇 A kind of page and its construction method for gathering user or user's feedback information
CN109582380A (en) * 2017-09-26 2019-04-05 北京国双科技有限公司 A kind of Node Processing Method and device, storage medium, processor
CN110659324A (en) * 2019-10-08 2020-01-07 中国银行股份有限公司 Recursive data entry method and system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101408877A (en) * 2007-10-10 2009-04-15 英业达股份有限公司 System and method for loading tree node
CN102750328A (en) * 2012-05-29 2012-10-24 北京城市网邻信息技术有限公司 Construction and storage method for data structure
CN103546498A (en) * 2012-07-09 2014-01-29 百度在线网络技术(北京)有限公司 Method and equipment for providing access webpage for mobile terminal
CN104933078A (en) * 2014-03-20 2015-09-23 中标软件有限公司 Web application page rendering optimization

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101408877A (en) * 2007-10-10 2009-04-15 英业达股份有限公司 System and method for loading tree node
CN102750328A (en) * 2012-05-29 2012-10-24 北京城市网邻信息技术有限公司 Construction and storage method for data structure
CN103546498A (en) * 2012-07-09 2014-01-29 百度在线网络技术(北京)有限公司 Method and equipment for providing access webpage for mobile terminal
CN104933078A (en) * 2014-03-20 2015-09-23 中标软件有限公司 Web application page rendering optimization

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109582380A (en) * 2017-09-26 2019-04-05 北京国双科技有限公司 A kind of Node Processing Method and device, storage medium, processor
CN107844354A (en) * 2017-10-25 2018-03-27 王宇 A kind of page and its construction method for gathering user or user's feedback information
CN110659324A (en) * 2019-10-08 2020-01-07 中国银行股份有限公司 Recursive data entry method and system

Similar Documents

Publication Publication Date Title
US9906477B2 (en) Distributing retained messages information in a clustered publish/subscribe system
WO2018045750A1 (en) Method, system, server and user terminal for displaying comment data of user
US20130246897A1 (en) Aggregation and semantic modeling of tagged content
CN101408877B (en) System and method for loading tree node
CN103733568A (en) Stream processing using a client-server architecture
CN102752388A (en) Browser-based interactive system, browser-based interactive method, browser and cloud server
KR101503965B1 (en) A method, apparatus and software for transforming a natural language request for modifying a set of subscriptions for a publish/subscribe topic string
CN106375189A (en) Long and short link switching method and system
CN103179148A (en) Processing method and system for sharing enclosures in internet
CN105024913B (en) Method, device and system for carrying out instant messaging session
CN105740407A (en) Tree structure generation method and system
CN105718307B (en) Process management method and management of process device
CN104050287A (en) Method and system for replying messages during instant chat
CN106933965A (en) The method of static resource request
EP2618529B1 (en) System and method for microblog messages
CN108133000B (en) Metadata storage method and device and server
CN110784377A (en) Method for uniformly managing cloud monitoring data in multi-cloud environment
CN114301980A (en) Method, device and system for scheduling container cluster and computer readable medium
CN116303608A (en) Data processing method and device for application service
CN109471989A (en) A kind of page request processing method and relevant apparatus
KR102169930B1 (en) Semantic Information Management Method for a M2M/IoT platform
CN111400060B (en) Equipment linkage method, device, server and medium
CN104753972A (en) Network resource collection processing method and server
CN112311823B (en) Flow control method and device of auditing system and server
CN115705465A (en) Data analysis result presentation method, device, equipment and storage medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20160706