CN101359337B - Method for interactively editing GIS topological data set - Google Patents

Method for interactively editing GIS topological data set Download PDF

Info

Publication number
CN101359337B
CN101359337B CN2008101430514A CN200810143051A CN101359337B CN 101359337 B CN101359337 B CN 101359337B CN 2008101430514 A CN2008101430514 A CN 2008101430514A CN 200810143051 A CN200810143051 A CN 200810143051A CN 101359337 B CN101359337 B CN 101359337B
Authority
CN
China
Prior art keywords
node
line segment
editorial services
topology objects
segmental arc
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.)
Expired - Fee Related
Application number
CN2008101430514A
Other languages
Chinese (zh)
Other versions
CN101359337A (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.)
Individual
Original Assignee
Individual
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 Individual filed Critical Individual
Priority to CN2008101430514A priority Critical patent/CN101359337B/en
Publication of CN101359337A publication Critical patent/CN101359337A/en
Application granted granted Critical
Publication of CN101359337B publication Critical patent/CN101359337B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

Disclosed is a method for realizing the interactively editing of the GIS topological dataset; the method appends the topological object to the GIS topological dataset to create the topological dataset through the form that the coordinate points are inputted interactively to generate line segments; the method also modifies the topological dataset through moving the arc segments or nodes interactively and realizes the cancellation and recovery operations through adding the transaction mechanism; the cancellation and recovery operations are used for canceling the previous editing operation or recovering the previous cancelled editing operation when the editing result is inconsistent with the expectation or the editing result needs to be rolled back to the previous data state during the editing and processing process of the topological data so that the purposes of improving the safety, interactivity and the work efficiency in editing the GIS topological dataset are realized.

Description

The method that is used for interactively editing GIS topological data set
Affiliated technical field
The present invention relates to GIS vector data editing technique, particularly a kind of method that is used for interactively editing GIS topological data set.
Background technology
GIS-Geographic Information System (Geographic Information System; GIS) vector data model comprises two types, i.e. Spaghetti data model and topology data model (statement Peng etc.: GIS-Geographic Information System introduction, Science Press; 2000, P31-43).In the Spaghetti model, spatial point representes that with a volume coordinate line is made up of a string coordinate (being called node), and face is the closed polygon that is formed of a wire.The basic object type of topological model comprises node, segmental arc and zone, and segmental arc is formed by connecting series of points (claiming node again), and it starts from start node, stops node finally; Node is the point that segmental arc intersects or stops; A zone is by an outer shroud and zero or a plurality of interior closed scope of forming of encircling, and a ring is formed by connecting one or more segmental arc.In the Spaghetti model, geometric object (point, line, surface etc.) is directly corresponding with coordinate data, does not store topological relation each other.In topological structure, except the storing coordinate data, also write down topology information, like the related segmental arc of node, the initial sum of segmental arc stop node, about the zone, the segmental arc of compositing area etc.
Topology data model has lot of advantages, as: need not come the interpretation topological relation, bring convenience for space querying, analyzing and processing through coordinate Calculation; Polygonal data boundary can significantly compress the data volume of graph data with the segmental arc network storage; In the process that generates topological structure, find out the mistake of data input easily; Can conveniently handle " island " nested in the polygon and carry out polygon and merge processing etc.In view of above reason, many GIS softwares are all supported the application based on topology data model, like ARC/INFO, MapGIS, GeoStar etc.
Though present GIS software is supported the application based on topology data model; But do not support that directly topological data set is carried out interactive editing to be handled, comprise that interactively creates or move topology objects and indispensable cancelling (Undo) in editing process, recover (Redo) operation.At present, for the vector data of non-topological structure, good interactive create or a segment distance is moved, the length of this segment distance and the equal in length of said vector with said topology objects along the direction of said vector in (4.2) arranged;
Change method, but, must utilize said non-topological data set to carry out topology constructing again and realize through creating non-topological data set earlier for the establishment of topological data set; For the modification of topological data set, also must be through revising and the corresponding non-topological data set of said topological data set, the total data of more said non-topological data being concentrated is carried out topology reconstruction and is realized.Though these classic methods can guarantee the correctness and the integrality of data topology relation; But because it is not realized through directly topological data set being operated; Its operating process is complicated, and operating result neither be directly visible, is not easy in editing process, find in real time and correct topological mistake; Reduce security, interactivity and the work efficiency of topological data set editing and processing, limited the application of topology data model.
Summary of the invention
The traditional GIS topological data is created in order to overcome, the deficiency of amending method; The invention provides a kind of be used to realize establishment of GIS topological data set and the interactive editing method of revising; This method not only can be concentrated to the GIS topological data with the mode of interactively input coordinate dot generation line segment and append topology objects and create topological data set; Also can realize moving segmental arc or node is revised topological data set through interactively, in addition, the present invention is also through adding affair mechanism; Realized cancelling, recovered handling operation; Be used for when find in topological data editing and processing process edited result and expection be not inconsistent or need playback before data mode the time, the editing operation of cancelling previous editing operation or recovering before to have cancelled is to reach the purpose of the security, interaction and the work efficiency that improve GIS topological data set editor.
In order to achieve the above object, the technical scheme of the present invention's employing comprises:
1, a kind of method of interactively editing GIS topological data set, said topological data are concentrated and are comprised zero or a plurality of topology objects, and the type of said topology objects comprises node, segmental arc and zone; Said method realizes that on computers said topological data set is loaded and is presented on the said computing machine; The method of said interactively editing GIS topological data set may further comprise the steps:
(1.1) set up spatial index for said topological data set;
(1.2) create a task manager;
(1.3) select an edit mode, and adopt the said topological data set of said edit mode editor;
(1.4) input is ceased and desisted order to stop to edit said topological data set; Perhaps, return step (1.3) and continue the said topological data set of editor.
2, preferred, like 1 described method, wherein said edit mode comprises creation operation, and the step of said creation operation comprises:
(2.1) create a line segment;
(2.2) input one coordinate moves on to this coordinate with the starting point and the terminal point of said line segment;
(2.3) the EOI order is to finish current creation operation; Perhaps, import a coordinate, and the terminal point of said line segment is moved on to this coordinate;
(2.4), then return step (2.3) and continue if the starting point of said line segment and terminal point overlap;
(2.5) beginning one editorial services;
(2.6) upgrade said topological data set with said line segment, and generate said editorial services;
(2.7) said editorial services are added said task manager;
(2.8) starting point of said line segment is moved on to the terminal point of said line segment;
(2.9) returning step (2.3) continues.
3, preferred, like 2 described methods, wherein said step with line segment renewal topological data set comprises:
(3.1) definition one ode table;
(3.2) interrupt said GIS topological data with said line segment and concentrate the segmental arc with this line segment intersection, and the node at all intersection point places is added said ode table;
(3.3), sort from small to large by distance to said line segment starting point to the node in the said ode table;
(3.4) the said ode table of uniqueization;
(3.5) check said ode table, if said ode table is not empty, then further processed steps comprises:
(3.5.1) whether first node of the said ode table of inspection overlaps with the starting point of said line segment, if do not overlap, then creates a node at the start position of said line segment, and this node is inserted the heading of said ode table;
(3.5.2) whether last node of the said ode table of inspection overlaps with the terminal point of said line segment, if do not overlap, then creates a node in the final position of said line segment, and this node is inserted the table tail of said ode table;
(3.6) otherwise, if said ode table is empty, then creates a node respectively, and they inserted said ode table in the starting point and the final position of said line segment;
(3.7) right for each the front and back node in the said ode table, the node that connects is wherein created a segmental arc, and the left and right regions of the said segmental arc of reconstruct.
4, preferred, like 1 described method, wherein said edit mode also comprises mobile topology objects, and the step of said mobile topology objects comprises:
(4.1) direction and the distance of input one vector to represent to move;
(4.2) direction with the said vector in said topology objects edge moves a segment distance, the length of this segment distance and the equal in length of said vector;
(4.3) carry out topology inspection, if the left and right regions of the related segmental arc of said topology objects with mobile before different or topological mistake occurred, then said topology objects are returned to raw bits [0035](4.2) said topology objects are moved a segment distance along said vector, the length of this segment distance equates with said vector length;
(4.3) carry out topology inspection, if the left and right regions of the related segmental arc of said topology objects with mobile before different or topological mistake occurred, then said topology objects are returned to the original position, and termination;
(4.4) beginning one editorial services;
(4.5) will be saved in said editorial services about the data of description that the renewal of said topology objects is operated;
(4.6) said editorial services are added said task manager.
5, preferred; Like 2 described methods; The method of wherein said generation editorial services is: after said editorial services begin, arrive before the end; There are topology objects to be updated if said topological data is concentrated, then will be saved in said editorial services about the data of description that the renewal of said topology objects is operated.
6, preferred, like 4 or 5 described methods, the wherein said method that will be saved in editorial services about the data of description that the renewal of topology objects is operated comprises:
(6.1) create a update event, said update event comprises an object type sign, an object ID, a renewal action type sign and a structure that is used to preserve service data;
(6.2) fill said update event according to type, ID and the renewal action type of said topology objects;
(6.3) said update event is joined in the said editorial services.
7, preferred, like 1 described method, wherein said edit mode also comprises cancels operation, and the said method of operating of cancelling comprises:
(7.1) from wherein said task manager, obtain previous editorial services;
(7.2) if said editorial services exist, then further processed steps comprises:
(7.2.1) the current insertion position with said task manager moves forward one;
(7.2.2) the said editorial services of rollback.
8, preferred, like 1 described method, wherein said edit mode also comprises recovery operation, and the method for said recovery operation comprises:
(8.1) from wherein said task manager, obtain back editorial services;
(8.2) if said editorial services exist, then further processed steps comprises:
(8.2.1) move one behind the current insertion position with said task manager;
(8.2.2) the said editorial services of rollback.
9, preferred, like 7 or 8 described methods, the step of wherein said rollback editorial services comprises:
(9.1) create a counter, and its initial value is made as the incident number of said editorial services;
(9.2) update event on the value relevant position of taking-up and said counter from said editorial services;
(9.3) if said update event exists, then further processed steps comprises:
(9.3.1) object type according to said update event identifies and object ID, concentrates from topological data and searches corresponding topology objects;
If (9.3.2) said topology objects do not exist, then create said topology objects, its type is consistent with the object type sign and the object ID of said update event with ID;
The renewal action type that (9.3.3) identifies by said update event; Utilize the service data of said update event record; Oppositely upgrade said topology objects, and refill said update event according to type, ID and the said reverse renewal action type of said topology objects;
(9.3.4) value with said counter subtracts 1;
(9.3.5) returning step (9.2) continues;
(9.4) with the list of thing sorting by reversals of said editorial services.
Compared with prior art, the present invention has the following advantages:
At first; The invention provides a kind of interactively and create the method for GIS topological data set; This method is concentrated to the GIS topological data with the mode of interactively input coordinate dot generation line segment and is appended topology objects and create topological data set; Overcome the defective that directly to create topological data set in the classic method through interactively input coordinate point, improved the observability of operating result, also improved the work efficiency that the GIS topological data set is created.
Secondly; The present invention also provides a kind of and has moved the method that segmental arc or node are revised the GIS topological data set through interactively; This method not only can realize the segmental arc that the GIS topological data is concentrated or the move operation of node object, simultaneously also through adding checking mechanism, before receiving the move operation result; Whether the said move operation of inspection has caused the topological relation between the topology objects to change or topological mistake earlier, has guaranteed the security of move operation.
In addition; The present invention is also through introducing transaction processing facility; Realized cancelling, recovery operation; Be used for when the data mode before topological data editing and processing process discovery edited result is not inconsistent with expection or needs playback, cancelling the editing operation that previous editing operation or recovery had before been cancelled, improved security, interactivity and the work efficiency of GIS topological data set editing process.
At last; The present invention is when realize creating the cancelling of GIS topological data set operation, restoration methods; The update processing of said GIS topological data set being carried out with the input line segment is that unit generates editorial services; And as the unit response user cancel, recover order, further improved security, the interactivity of editing process.
Description of drawings
Fig. 1 shows a GIS topological data set graphic example of embodiments of the invention;
Fig. 2 shows GIS topological data set storage organization shown in Figure 1;
Fig. 3 shows according to the uml model that is used to realize the GIS topological data set in the embodiments of the invention;
Fig. 4 shows the uml model that is used to realize the editorial services manager in the embodiments of the invention;
Fig. 5 shows the method flow of interactively editing GIS topological data set according to an embodiment of the invention;
Fig. 6 shows and is used for the method flow diagram that interactively is created the GIS topological data set according to an embodiment of the invention;
Fig. 7 shows the method flow diagram that upgrades the GIS topological data set according to an embodiment of the invention with line segment;
Fig. 8 shows the front and back node that utilizes according to an embodiment of the invention in the ode table to creating the process flow of new segmental arc;
Fig. 9 shows the process flow that is used for moving topology objects according to an embodiment of the invention;
Figure 10 shows the process flow that generates editorial services according to an embodiment of the invention;
Figure 11 shows the process flow of cancelling operation according to an embodiment of the invention;
Figure 12 shows the process flow of recovery operation according to an embodiment of the invention;
Figure 13 shows the process flow of rollback editorial services according to an embodiment of the invention.
Embodiment:
Be to a preferred embodiment of the invention below, the detailed description of carrying out in conjunction with accompanying drawing.
This preferred embodiment is realized on computers; GIS topological data set wherein need at first be created or be loaded on the computing machine; And on display, show; Said GIS topological data is concentrated and to be made up of zero or a plurality of topology objects, and topology objects type wherein comprises three types in node, segmental arc and zone, and node is that segmental arc intersects or the point of termination; Segmental arc starts from start node, stops node finally, and it is formed by connecting zero or a plurality of point, and these points that connect into segmental arc are called node; A zone is by an outer shroud and zero or a plurality of interior closed scope of forming of encircling, and a ring is formed by connecting one or more segmental arc.
Fig. 1 shows a GIS topological data set graphic example 100 of embodiments of the invention.This GIS topological data set comprises 5 nodes, and they are N01, N02, N03, N04 and N05; Article 6, segmental arc, i.e. A01, A02, A03, A04, A05 and A06; 3 zone: R01, R02 and R03; V01~V11 is for forming the node of segmental arc among the figure.
Personnel for the ease of association area further understand the topological data set of GIS described in the present invention, and Fig. 2 shows GIS topological data set storage organization 200 shown in Figure 1.Comprise ode table 201, region list 202 and segmental arc table 203.Node of each line display in the ode table 201, ID is the unique identification of this node in this table; The value of segmental arc attribute is the ID of the segmental arc related with this node, and a node can have one or many related segmental arcs, wherein representes clearing end on the occasion of expression initiating terminal, negative value; The coordinate of this node of value representation of coordinate attributes, first is the x coordinate, second is the y coordinate.Segmental arc of each line display in the segmental arc table, ID is the unique identification of this segmental arc in the table; Start node, termination node property value are the node sign corresponding with ode table 1D attribute; Zone, a left side, right area attribute value are and the corresponding area identification of region list ID attribute that null value wherein representes that corresponding zone does not exist; Node attribute values is the node sequence of this segmental arc, and null value wherein representes that corresponding segmental arc does not have node.Zone of each line display in the region list, the ID in the table is this regional unique identification; The segmental arc property value representes to surround this regional segmental arc tabulation, and this segmental arc tabulation can be divided into many groups, ring of each group expression; Form by one or more segmental arc ID; Wherein the negative sign before the segmental arc ID is represented this segmental arc oppositely, and first in these rings is outer shroud, and other is interior ring; Outer shroud is a counter-clockwise direction, and interior ring is a CW.
Be the details of convenient explanation core content of the present invention, below about mainly having adopted OO thought and type C++ grammer in the description of embodiments of the invention.Under the prerequisite that does not influence this paper core content, for making things convenient for code reading, the data structure that adopts in the following code is without optimization, and high-efficient algorithm can be used other data structure more efficiently in realizing.
Personnel for the ease of association area more clearly understand the topological data set of GIS described in the present invention, and Fig. 3 shows according to the uml model 300 that is used to realize the GIS topological data set in the embodiments of the invention.This specification of a model the data structure of GIS topological data set according to an embodiment of the invention.Topology objects classes such as node CNode class 305, segmental arc CEdge class 306 and zone C area class 307 in this model are all inherited from same base class---CTopoObject class 303; Said CTopoObject class 303 has two attributes; That is: object ID and maximum outsourcing rectangle (mbr); Wherein object ID is used for each topology objects of unique identification, the spatial dimension that four values in maximum outsourcing rectangle MBR type 313 employing upper and lower, left and right are come the approximate description topology objects; CEdgeItem class 301 is used to describe the direction or the node type of segmental arc; Its DIRECTION type 312 data member direction describe the direction of its member's segmental arc edge, and its value positive representes that segmental arc forward or start node, inverse represent that segmental arc is reverse or stop node; Node class CNode class 305 has also been inherited the attribute of coordinate points CPoint class 304: x coordinate and y coordinate; Be used to preserve the position of node; In addition; Node class CNode class 305 also comprises one or more CEdgeItem class 301 instances, and being used to preserve with this node is start node or the information that stops the segmental arc of node, and CEdgeItem class 301 instances of each node sort by itself and the link line segment of said node and the angle of x axle forward from small to large; Segmental arc class CEdge class 306 has from, to, right and four data members of left; Be respectively the start node that points to segmental arc, the pointer that stops node, right zone and zone, a left side; In addition; Segmental arc class CEdge class 306 also comprises zero or a plurality of CPoint class 304 instances, is used to store the sequence node in this segmental arc path; Lopps CRing class 302 comprises one or more CEdgeItem class 301 instances, and the segmental arc of these CEdgeItem class 301 instances is linked in sequence and forms the ring of a closure; CArea class 307 comprises one or more lopps CRing class 302 instances, and first in these lopps instances is outer shroud, and other is interior ring, and outer shroud is a counter-clockwise direction, and interior ring is a CW.
GIS topological data set class CTopoSet class 311 comprises set of node CNodeSet class 308, segmental arc collection CEdgeSet class 309 and set of regions CAreaSet class 310 instances; Be used for management node, segmental arc or section object respectively; Topology objects pointer is wherein complied with its referent ID series arrangement from small to large, so that can adopt the binary chop algorithm to obtain pointer to object fast according to object ID when needed.Set of node CNodeSet class 308, segmental arc collection CEdgeSet class 309 and set of regions CAreaSet class 310 all comprise spatial index CSpatialIndex class 314 instances.CSpatialIndex class 314 be one be used for to node, segmental arc or section object carry out spatial index the class; It can be according to the space distribution of the maximum outsourcing rectangle of node, segmental arc or section object; Press the pointer that certain way reorganizes topology objects; So that get rid of a large amount of topology objects beyond the particular space scope during topology objects rapidly in retrieval, significantly improve intersect with the particular space scope or the particular space scope in the retrieval rate and the efficient of topology objects.In the present invention, utilize line segment to interrupt segmental arc, inspection topological relation etc., all relate in a large number based on the retrieval of spatial dimension topology objects, about disposal route will be introduced in part subsequently.Concrete realization about spatial index; The technology of existing comparative maturity; The embodiment of the invention adopted R-tree space index technology (Antonin Guttman:R-Trees:A Dynamic IndexStructurefor Spatial Searching, Proceedings1984A CM SIGMOD InternationalConference on Management of Data, P47-57); Adopt other Spatial Data Index Technology, also can realize technique effect of the present invention like quaternary tree, graticule mesh division etc.
Understand the table of editorial services described in the present invention for the ease of those skilled in the relevant art, Fig. 4 shows the uml model 400 that is used to realize the editorial services manager in the embodiments of the invention.Wherein, CArray401 is the array class template, and its member function push is used for an array element is inserted the end of array; Insert is used for an array element is inserted its parameter of array index appointed positions; Remove is used for from the element of its parameter of array deletion index appointment; Item is used for taking out from array the pointer of its parameter index designed element, when parameter index less than 0 or return a null pointer during more than or equal to the sum of the element in the array, the expression designed element does not exist.Editorial services table class CEditTranctionList402 and editorial services class CTranction403 are that the binding of CArray template class 401 realizes; Wherein CTranction class 403 comprises one or more CEditEvent class 404 instances; Be used to be kept at affairs and begin to the topology objects data update event that takes place between tailend, these event class instances are by the priority ordering that takes place.CEditTranctionList class 402 comprises one or more CTranction class 403 instances, is used to preserve editorial services; Data update event class CEditEvent404 is used for writing down topology objects once to be upgraded for information about; Its data member comprises object type sign Ob_Type, object identity ID, updating type and service data storage organization EVENTDATA 408 member Data; Wherein, Object type sign Ob_Type is an Object_Type type 406, and its value and implication are seen table 1; Updating type is that Op_Type is an Operate_Type type 405, and its value and implication are seen table 2; The content of service data storage organization member Data and object type and renewal class
Table 1
The object type sign Ob_Node Ob_Edge Ob_Area
Object type Node Segmental arc The zone
Type is relevant, sees table 2.
Table 2
The updating type sign Updating type The applicable object type Reverse updating type The content of Data
Op_New Newly-built All Op_Delete Empty
Op_Delete Deletion All Op_New Node, segmental arc, about whole ID of affiliated partners such as zone, ring
Op_Move Move Segmental arc, node Op_Move The direction, the distance that move
Op_Ch_Area The zone Segmental arc Op__Ch_Area The ID of former left and right regions
Op_Ch_Edge Segmental arc Node Op__Ch_Edge The ID table of former segmental arc table
Op_Ch_Node Node Segmental arc Op_Ch_Node The ID of former node
?Op_Ch_All All All ?Op_Ch_All Node, segmental arc, about whole ID of affiliated partners such as zone, ring
CTranctionMgr class 402 is that present embodiment is used to realize responding the data structure of cancelling with the recovery operation order; It comprises the CEditTranctionList class 407 member TranctionList and the member variable current who is used to indicate current insertion position that are used to store editorial services, and function member such as GetPrevTranction, GetNextTranction, Insert.Wherein, member function GetPrevTranction is used for taking out from TranctionList member the previous editorial services of current insertion position, promptly visits the member function item of TranctionList; Access parameter index is made as current-1, if said previous editorial services exist, then returns the pointer of these editorial services; And with one of current insertion position reach, be about to current and reduce 1, otherwise; Return null pointer, represent that said previous editorial services do not exist; GetNextTranction is used for taking out the editorial services on the current insertion position from TranctionList, promptly visits the member function item of TranctionList, and access parameter index is made as current; If said editorial services exist, then return the pointer of these editorial services, and with moving one behind the current insertion position; Be about to current and increase by 1; Otherwise, return null pointer, represent that said editorial services do not exist; Member function Insert is used for the editorial services t that its parameter is specified and is inserted into TranctionList, and the insertion position has current to specify, after insertion is finished dealing with, with the value increase by 1 of current; The initial value of member variable current is 0.
Fig. 5 shows the method flow 500 of interactively editing GIS topological data set according to an embodiment of the invention.The CTopoSet class 311 shown in Fig. 3 is adopted in the realization of the topological data set of GIS described in the present embodiment; CTopoSet class 311 comprises set of node NodeSet316, segmental arc collection EdgeSet317 and three members of set of regions AreaSet318, is used for management node, segmental arc or section object respectively.
Need carry out preliminary work (step 501) earlier before this method begins, comprise establishment or load said GIS topological data set, and on display, show said GIS topological data set.
In step 502, for said GIS topological data set is set up spatial index 314, so that retrieval perhaps is included in the topology objects in the particular space scope with the topology objects that the particular space scope intersects fast.
In step 503; Create a task manager 407; The data structure of this task manager is the CTranctionMgr class 407 shown in Fig. 4; Said task manager is used for managing the editorial services of said GIS topological data set editing process, and when being used for the data mode before discovery edited result and expection are not inconsistent or need playback, the response user cancels or recovery operation.
In step 504, select the said GIS topological data set of an edit mode editor.The system of selection of said edit mode can be adopted the keyboard mapping, also can be through menu or tool button order, and perhaps other similar approach realizes.For example:, then carry out creation operation if the user supresses keyboard A key; If the user supresses keyboard M key, then carry out move operation; If the user supresses keyboard D key, then carry out deletion action; If the user supresses keyboard F5 key, then carry out and cancel operation; If the user supresses keyboard F6 key, then carry out recovery operation etc.
In step 505, if stop editor's (step 506) said GIS topological data set, then input stops edit commands; Otherwise, return step 504 and continue editor.
Fig. 6 shows and is used for the method flow diagram 600 that interactively is created the GIS topological data set according to an embodiment of the invention.The mode of this method through interactively input coordinate dot generation line segment concentrated to the GIS topological data and appended topology objects, and is that unit generates editorial services with the update processing that the input line segment carries out said GIS topological data set.In this method,, create a line segment L earlier in step 601.Then, in step 602, import a coordinate, starting point and the terminal point of said line segment L moved on to this coordinate.In step 603, at first check the user command input, if the user has imported the end operational order, then finish current creation operation (step 604), return master routine; Otherwise, import a coordinate, the terminal point of said line segment L is moved on to this coordinate (step 605).In step 606, check the starting point of said line segment L and the coordinate of terminal point, if the coordinate of the starting point of said line segment L and terminal point is identical, then return step 603.Otherwise, handle according to the following steps: definition editorial services 403 (step 607) earlier; Execution in step 608 then, upgrade said GIS topological data set with said line segment L, and generate said editorial services (Figure 10); After said GIS topological data set upgrades completion, said editorial services are added task manager (step 609); Then, the starting point of said line segment L is moved on to the terminal point (step 610) of said line segment, return step 603 and continue.
Fig. 7 shows the method flow diagram 700 that upgrades the GIS topological data set according to an embodiment of the invention with line segment.
Wherein, in step 701, define an ode table earlier.
Then, in step 702, interrupt said GIS topology with said line segment and concentrate the segmental arc with said line segment intersection; And the node at all intersection point places added said ode table; Concrete grammar is: earlier concentrate the segmental arc that retrieves with said line segment intersection through spatial index from said GIS topology, calculate the intersection point of itself and said line segment one by one, for these intersection points; Divide two kinds of situation to handle: (1) directly joins said ode table with it for the intersection point on node; (2) for the intersection point on node not, then create a node, and will intersect segmental arc at this intersection point place with line segment L with this node and interrupt, simultaneously this new node is joined said ode table at this position of intersecting point.
In step 703,, sort from small to large by distance to said line segment starting point to the node in the said ode table.
In step 704, the said ode table of uniqueization for the node that repeats to occur in the said ode table, only keeps one.
In step 705, whether the said ode table of inspection is empty earlier, if said ode table is empty, then creates a node respectively in the starting point and the final position of said line segment, and they are inserted said ode table (step 707); Otherwise whether first node that continues the said ode table of inspection overlaps (step 706) with the starting point of said line segment, if do not overlap, then creates a node at the start position of said line segment, and this node is inserted the heading (step 708) of said ode table; Whether last node that continues the said ode table of inspection overlaps (step 709) with the terminal point of said line segment, if do not overlap, then creates a node in the final position of said line segment, and this node is inserted the table tail (step 710) of said ode table.
At last, in step 711, right for each the front and back node in the said ode table, the node that connects is wherein created a segmental arc (Fig. 8), and the left and right regions of the said segmental arc of reconstruct.When the left and right regions of the said segmental arc of reconstruct, be initial segmental arc with said segmental arc earlier, search for its left and right ring, judging whether they exist,, be the region R a that comprises said segmental arc then with its left and right regions assignment if do not exist; Otherwise, destroy and to comprise said region R a, using said left side ring to rebuild as outer shroud again should the zone, simultaneously said right ring is new region Rb of outer shroud establishment, again with its left and right regions respectively assignment be region R a, Rb; About being initial segmental arc, search for the method for its left and right ring, existing ripe algorithm (Qi Hua: set up the optimization and the improvement of polygon topological relation algorithm steps automatically, mapping journal, the 26th the 3rd phase of volume, 1997.08) with said segmental arc.
Fig. 8 shows the process flow 800 of front and back node to creating new segmental arc of utilizing according to an embodiment of the invention in the ode table.This disposal route starts from step 801, and the node sum of said ode table is saved in variable S, and initialization current node numbering I is 0; Then, from said ode table, take out I node N i, an I+1 node N I+1(step 802); Link node N then i, N I+1Create a new segmental arc (step 803), again current node being numbered I increases by 1, promptly establishes I=I+1 (step 804), returns step 802 again, and so circulation is returned master routine (step 805) up to as I during more than or equal to S.
Fig. 9 shows the process flow 900 that is used for moving topology objects according to an embodiment of the invention.This method need be carried out topology inspection before the mobile topology objects earlier, guaranteeing not change the topological relation between the topology objects after said topology objects move, and the correctness that guarantees the concentrated topological relation of topological data.In this disposal route, two coordinates of input are to create two vectorial P earlier 1And P 2(step 901 and step 902) generates motion vector M, wherein M=P 2-P 1(step 903) is with direction and the distance of representing to move; Then, in step 904, with direction translation one distance, d along motion vector M of said topology objects, the length of this segment distance equals the length of said motion vector, i.e. d=|M|; Then; Carry out topology inspection (step 905), in checking process, if find said topology objects related segmental arc left and right regions with mobile before different or topological mistake occurred; Then said topology objects are returned to original position (step 906), forward step 910 then to and return master routine; Otherwise, proceed following processing: at first, create editorial services 403 (step 907); Then, in step 908, will be saved in said editorial services 1011 about the data of description that the renewal of said topology objects is operated; At last, said editorial services are added task manager (step 909).Topological mistake described here comprises that there is self intersection or crossing with other segmental arc in the segmental arc related with said topology objects.
Figure 10 shows the process flow 1000 that generates editorial services according to an embodiment of the invention.This processing was carried out before finishing 1003 after affairs begin 1001, before topology objects need upgrade 1008, will be saved in said editorial services 1011 about the data of description to the renewal operation of said topology objects earlier; Its method is: send upgating object message 1007 to incident generation module 1002 earlier; The incident generation module is created a update event 404 (step 1004) after receiving message, then fill said update event (step 1005) according to object type, object ID and the renewal action type of said topology objects; The content that said update event is filled sees Fig. 4, table 1 and table 2 for details; After said update event is filled completion, again this update event is joined in the said editorial services (step 1006), afterwards; Return update event and accomplish message 1010, update processing 1009 is proceeded.
Figure 11 shows the process flow 1100 of cancelling operation according to an embodiment of the invention.This method is used for cancelling the previous editorial services of the current insertion position of task manager.Wherein, in step 1101, from said task manager, obtain earlier the previous editorial services of current insertion position.Then, in step 1102, judge whether said editorial services exist.If said editorial services do not exist, then forward step 1105 to, directly return master routine; Otherwise,, then continue step 1103,1104 if said editorial services exist.In step 1103, with one of the current insertion position reach of said task manager.In step 1104, the said editorial services of rollback.The method that relates in this method sees Fig. 4 and associated description for details.
Figure 12 shows the process flow 1200 of recovery operation according to an embodiment of the invention.This method is used for recovering back editorial services of task manager, the editorial services on the promptly current insertion position.Wherein, in step 1201, from said task manager, obtain the editorial services on the current insertion position.Then, in step 1202, judge whether said editorial services exist.If said editorial services do not exist, then forward step 1205 to, directly return master routine; Otherwise,, then continue step 1203,1204 if said editorial services exist.In step 1203, move one behind the current insertion position with said task manager.In step 1204, the said editorial services of rollback.The method that relates in this method sees Fig. 4 and associated description for details.
Figure 13 shows the process flow 1300 of rollback editorial services according to an embodiment of the invention.Wherein,, create a counter, and its initial value is made as the incident number of said editorial services in step 1301.Then, in step 1302, the update event from said editorial services on the value relevant position of taking-up and said counter.Then, in step 1303, whether the said update event of inspection exists earlier, if do not exist, then directly goes to step 1309; Otherwise; Object type according to said update event identifies and object ID earlier; Concentrate from topological data and to search corresponding topology objects (step 1304), check then whether said topology objects exist (step 1305), if saidly do not exist; Then create said topology objects, and its type and object type sign and the object ID consistent (step 1306) of ID with said update event are set.In step 1307; Renewal action type by said update event sign; Utilize the service data of said update event record, oppositely upgrade said topology objects, and refill said update event according to type, ID and the said reverse updating type of said topology objects.Each upgrades the reverse renewal of action type and operates the reverse updating type of seeing table 2.
Then, in step 1308,, return step 1302 then and continue the value minimizing 1 of said first counter.In step 1309, elder generation is reverse with the ordering of the list of thing of said editorial services, returns master routine then.The method that relates in this method sees Fig. 4 and associated description for details.
Above to detailed introduction of the present invention in, used concrete example principle of the present invention and embodiment set forth, the explanation of above embodiment just is used for helping to understand method of the present invention and core concept thereof.Simultaneously, for one of ordinary skill in the art, according to thought of the present invention, the part that on embodiment and range of application, all can change, in sum, this description should not be construed as limitation of the present invention.

Claims (9)

1. the method for an interactively editing GIS topological data set, said topological data are concentrated and are comprised zero or a plurality of topology objects, and the type of said topology objects comprises node, segmental arc and zone; Said node is the point that segmental arc intersects or stops; Said segmental arc starts from start node, stops node finally; Be formed by connecting zero or a plurality of point, said zone is by an outer shroud and zero or a plurality of interior closed scope of forming of encircling, and said outer shroud is a counter-clockwise direction; Ring is CW in said, and a ring is formed by connecting one or more segmental arc; Said method realizes that on computers said topological data set is loaded and is presented on the said computing machine; The method of said interactively editing GIS topological data set is characterized in that, it may further comprise the steps:
(1.1) set up spatial index for said topological data set;
(1.2) create a task manager;
(1.3) select an edit mode, and adopt the said topological data set of said edit mode editor;
(1.4) input is ceased and desisted order to stop to edit said topological data set; Perhaps, return step (1.3) and continue the said topological data set of editor.
2. the method for claim 1 is characterized in that, wherein said edit mode comprises creation operation, and the step of said creation operation comprises:
(2.1) create a line segment;
(2.2) input one coordinate moves on to this coordinate with the starting point and the terminal point of said line segment;
(2.3) the EOI order is to finish current creation operation; Perhaps, import a coordinate, and the terminal point of said line segment is moved on to this coordinate;
(2.4), then return step (2.3) and continue if the starting point of said line segment and terminal point overlap;
(2.5) beginning one editorial services;
(2.6) upgrade said topological data set with said line segment, and generate said editorial services;
(2.7) said editorial services are added said task manager;
(2.8) starting point of said line segment is moved on to the terminal point of said line segment;
(2.9) returning step (2.3) continues.
3. method as claimed in claim 2 is characterized in that, wherein said step with line segment renewal topological data set comprises:
(3.1) definition one ode table;
(3.2) interrupt said GIS topological data with said line segment and concentrate the segmental arc with this line segment intersection, and the node at all intersection point places is added said ode table;
(3.3), sort from small to large by distance to said line segment starting point to the node in the said ode table;
(3.4) the said ode table of uniqueization;
(3.5) check said ode table, if said ode table is not empty, then further processed steps comprises:
(3.5.1) whether first node of the said ode table of inspection overlaps with the starting point of said line segment, if do not overlap, then creates a node at the start position of said line segment, and this node is inserted the heading of said ode table;
(3.5.2) whether last node of the said ode table of inspection overlaps with the terminal point of said line segment, if do not overlap, then creates a node in the final position of said line segment, and this node is inserted the table tail of said ode table;
(3.6) otherwise, if said ode table is empty, then creates a node respectively, and they inserted said ode table in the starting point and the final position of said line segment;
(3.7) right for each the front and back node in the said ode table, the node that connects is wherein created a segmental arc, and the left and right regions of the said segmental arc of reconstruct.
4. the method for claim 1 is characterized in that, wherein said edit mode also comprises mobile topology objects, and the step of said mobile topology objects comprises:
(4.1) direction and the distance of input one vector to represent to move;
(4.2) direction with the said vector in said topology objects edge moves a segment distance, the length of this segment distance and the equal in length of said vector;
(4.3) carry out topology inspection, if the left and right regions of the related segmental arc of said topology objects with mobile before different or topological mistake occurred, then said topology objects are returned to the original position, and termination;
(4.4) beginning one editorial services;
(4.5) will be saved in said editorial services about the data of description that the renewal of said topology objects is operated;
(4.6) said editorial services are added said task manager.
5. method as claimed in claim 2; It is characterized in that; The method of wherein said generation editorial services is: after said editorial services begin, arrive before the end; There are topology objects to be updated if said topological data is concentrated, then will be saved in said editorial services about the data of description that the renewal of said topology objects is operated.
6. like claim 4 or 5 described methods, it is characterized in that the wherein said method that will be saved in editorial services about the data of description that the renewal of topology objects is operated comprises:
(6.1) create a update event, said update event comprises an object type sign, an object ID, a renewal action type sign and a structure that is used to preserve service data;
(6.2) fill said update event according to type, ID and the renewal action type of said topology objects;
(6.3) said update event is joined in the said editorial services.
7. the method for claim 1 is characterized in that, wherein said edit mode also comprises cancels operation, and the said method of operating of cancelling comprises:
(7.1) from wherein said task manager, obtain previous editorial services;
(7.2) if said editorial services exist, then further processed steps comprises:
(7.2.1) the current insertion position with said task manager moves forward one;
(7.2.2) the said editorial services of rollback.
8. the method for claim 1 is characterized in that, wherein said edit mode also comprises recovery operation, and the method for said recovery operation comprises:
(8.1) from wherein said task manager, obtain editorial services on the current insertion position;
(8.2) if said editorial services exist, then further processed steps comprises:
(8.2.1) move one behind the current insertion position with said task manager;
(8.2.2) the said editorial services of rollback.
9. like claim 7 or 8 described methods, it is characterized in that the step of wherein said rollback editorial services comprises:
(9.1) create a counter, and its initial value is made as the incident number of said editorial services;
(9.2) update event on the value relevant position of taking-up and said counter from said editorial services;
(9.3) if said update event exists, then further processed steps comprises:
(9.3.1) object type according to said update event identifies and object ID, concentrates from topological data and searches corresponding topology objects;
If (9.3.2) said topology objects do not exist, then create said topology objects, its type is consistent with the object type sign and the object ID of said update event with ID;
The renewal action type that (9.3.3) identifies by said update event; Utilize the service data of said update event record; Reverse upgrade said topology objects, and according to type, the ID of said topology objects with oppositely upgrade action type and refill said update event;
(9.3.4) value with said counter subtracts 1;
(9.3.5) returning step (9.2) continues;
(9.4), that the ordering of the list of thing of said editorial services is reverse if said update event does not exist.
CN2008101430514A 2008-10-06 2008-10-06 Method for interactively editing GIS topological data set Expired - Fee Related CN101359337B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2008101430514A CN101359337B (en) 2008-10-06 2008-10-06 Method for interactively editing GIS topological data set

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2008101430514A CN101359337B (en) 2008-10-06 2008-10-06 Method for interactively editing GIS topological data set

Publications (2)

Publication Number Publication Date
CN101359337A CN101359337A (en) 2009-02-04
CN101359337B true CN101359337B (en) 2012-10-31

Family

ID=40331787

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2008101430514A Expired - Fee Related CN101359337B (en) 2008-10-06 2008-10-06 Method for interactively editing GIS topological data set

Country Status (1)

Country Link
CN (1) CN101359337B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102819581B (en) * 2012-07-26 2014-07-02 中南大学 Method for generating polygonal chain with concentrated topology of geographic information system
US20160065405A1 (en) * 2014-08-27 2016-03-03 Aviacomm Inc. Policy-based intelligent ad-hoc network architecture for grouping nodes based on common activities
EP3234805A4 (en) 2014-12-19 2017-10-25 Microsoft Technology Licensing, LLC Graph processing in database
CN110110019B (en) * 2018-01-31 2021-10-29 北京四维图新科技股份有限公司 Road network topology data updating method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6542813B1 (en) * 1999-03-23 2003-04-01 Sony International (Europe) Gmbh System and method for automatic managing geolocation information and associated references for geographic information systems
CN1480892A (en) * 2002-10-10 2004-03-10 中国地质调查局发展研究中心 Method for filling digit on map utilized in regional geological survey

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6542813B1 (en) * 1999-03-23 2003-04-01 Sony International (Europe) Gmbh System and method for automatic managing geolocation information and associated references for geographic information systems
CN1480892A (en) * 2002-10-10 2004-03-10 中国地质调查局发展研究中心 Method for filling digit on map utilized in regional geological survey

Also Published As

Publication number Publication date
CN101359337A (en) 2009-02-04

Similar Documents

Publication Publication Date Title
CN104123374B (en) The method and device of aggregate query in distributed data base
CN104391730B (en) A kind of software source codes language translation system and method
CN107402995A (en) A kind of distributed newSQL Database Systems and method
CN102426582B (en) Data manipulation management devices and data manipulation management method
CN103559323B (en) Database implementation method
CN109977162A (en) A kind of urban and rural planning data transfer device, system and computer readable storage medium
US7707230B1 (en) Methods and structure for use of an auxiliary database for importation of data into a target database
CN104317928A (en) Service ETL (extraction-transformation-loading) method and service ETL system both based on distributed database
CN111506950B (en) BIM structure transformation increment information generation and storage system and method
CN102651007A (en) Method and device for managing database indexes
CN110019287B (en) Method and device for executing Structured Query Language (SQL) instruction
CN101727322A (en) Method and device for optimizing bill of material management interface
CN101359337B (en) Method for interactively editing GIS topological data set
CN100517222C (en) Model conversion frame supporting separation of conversion engine and mapping rule and the method
CN106919606A (en) A kind of method and system that SQL query condition is realized based on tree construction
CN104077121A (en) State machine information realizing and managing device
CN107784030A (en) A kind of method and device for handling Connection inquiring
US20230147594A1 (en) Method for integratedly updating map data, device and storage medium
CN109274742A (en) A kind of internet of things data acquisition and supervisor control
CN102693174B (en) Object broker database constraint-oriented backup method
CN107562763A (en) The display methods and device of data variation
CN110597821B (en) Method and device for changing database table structure
CN110889013B (en) Data association method, device, server and storage medium based on XML
CN112364021A (en) Service data processing method, device and storage medium
CN108170989B (en) Engineering construction model derivation method based on BIM technology

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20121031

Termination date: 20151006

EXPY Termination of patent right or utility model