Two-dimensional and three-dimensional data synchronization method and system based on digital thread object and state machine

CN122597655APending Publication Date: 2026-08-18CHINA RAILWAY FIRST SURVEY & DESIGN INST GRP +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610773473.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-01
Publication Date
2026-08-18

AI Technical Summary

Technical Problem

[0006]本发明提供一种基于数字线程对象与状态机的二三维数据同步方法及系统,以解决现有二三维同步技术中存在的链接脆弱性和数据权责模糊性的问题

Benefits of technology

[0039] 1. Fundamental Link Resilience: By introducing digital thread objects with independent lifecycles, this invention elevates the fragile "entity mapping" to a persistent "logical object anchoring," fundamentally solving the link breakage problem caused by operations such as deletion and redrawing, and ensuring the continuity and reliability of the synchronization channel throughout the entire design cycle.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122597655A_ABST
    Figure CN122597655A_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on digital thread object and state machine two three-dimensional data synchronization method and system, response to the two-dimensional graphic entity creation operation of user, for the two-dimensional graphic entity instantiation one digital thread object, and generate the unique identifier of the digital thread object;Establish the associated mapping and link relationship between the digital thread object and corresponding two-dimensional graphic entity ID and three-dimensional model entity ID;For each digital thread object, create state machine, and the design life cycle of the digital thread object is modeled and controlled by state machine;Based on the digital thread object and state machine, utilize synchronization engine to execute two-dimensional and three-dimensional bidirectional data synchronization.The application is by constructing an abstract logic entity independent of host software, with life cycle state, realize the high toughness of data link, the accurate management of data rights and responsibilities and the order of design change, bidirectional dynamic synchronization.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data synchronization technology for two-dimensional and three-dimensional heterogeneous platforms, specifically to a two-dimensional and three-dimensional data synchronization method and system based on digital thread objects and state machines. Background Technology

[0002] In the design practice of complex systems engineering such as railway communication, aerospace, and energy and chemical engineering, the paradigm of 2D and 3D data collaboration is undergoing a profound evolution from "data exchange" to "process collaboration." Current mainstream technical solutions mainly rely on establishing a direct mapping relationship between 2D graphic entity IDs and 3D model component IDs in external databases. However, this direct mapping architecture, built upon identifiers within the host software, exposes two fundamental and insurmountable architectural flaws when facing complex, variable, and long-cycle real-world design processes:

[0003] 1) Inherent fragility of links: The lifecycle of Handle values ​​in CAD software or GUIDs in BIM software is bound to the graphic / model entity itself. In design iterations, "delete and redraw" is far more common than "modify in place." Once the original entity is deleted, its ID becomes permanently invalid, causing the mapping relationship in the database to "die" instantly, resulting in an irreversible break in the data link. Subsequent synchronization systems cannot determine whether the newly drawn entity is a completely new design or a continuation of the original logical object, leading to data loss or synchronization logic confusion.

[0004] 2) Ambiguity of Data Ownership and Responsibility: Existing synchronization mechanisms are typically peer-to-peer models without clear hierarchy, lacking an understanding of the dynamic flow of "data sovereignty" throughout the design process. For example, in the conceptual design phase, 2D logic diagrams have absolute authority over equipment selection; however, in the detailed design phase, the dimensional adjustments made to the 3D model due to spatial collision checks should have higher priority. The lack of built-in support for such workflow logic makes automated synchronization highly susceptible to malicious data overwriting, forcing teams to revert to an inefficient collaborative model relying on manual coordination and "gentlemen's agreements."

[0005] Therefore, there is an urgent need in this field for a new synchronization mechanism that can transcend the lifecycle of the host software entity and model and govern the design process, in order to achieve true industrial-grade robustness and intelligence. Summary of the Invention

[0006] This invention provides a two-dimensional and three-dimensional data synchronization method and system based on digital thread objects and state machines to solve the problems of link fragility and data ambiguity in existing two-dimensional and three-dimensional synchronization technologies.

[0007] According to a first aspect, one embodiment provides a two-dimensional / three-dimensional data synchronization method based on digital thread objects and state machines, the method comprising:

[0008] In response to the user's two-dimensional graphic entity creation operation, a digital thread object is instantiated for the two-dimensional graphic entity, and a unique identifier for the digital thread object is generated;

[0009] Establish the association mapping and link relationship between the digital thread object and the corresponding two-dimensional graphic entity ID and three-dimensional model entity ID;

[0010] A state machine is created for each digital thread object, and the design lifecycle of the digital thread object is modeled and managed through the state machine;

[0011] Based on the digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions.

[0012] Furthermore, in response to the user's two-dimensional graphic entity creation operation, a digital thread object is instantiated for the two-dimensional graphic entity, specifically including:

[0013] The digital thread object is defined as a structured data container, whose internal schema includes: core logical attributes, derived / physical attributes, current state identifier of the state machine, and a set of multi-platform pointers pointing to its specific representation in various two-dimensional or three-dimensional host software.

[0014] Furthermore, establishing the association mapping and link relationship between the digital thread object and the corresponding two-dimensional graphic entity ID and three-dimensional model entity ID specifically includes:

[0015] In a two-dimensional environment, the Handle value of the newly created two-dimensional graphic entity is written to the autocad_handle pointer field of the corresponding digital thread object;

[0016] In a 3D environment, after generating a 3D model based on the core logical attributes of the digital thread object, the GUID / ElementId of the 3D model entity is written into the revit_element_id pointer field of the digital thread object.

[0017] Furthermore, a state machine is created for each digital thread object to model and manage the design lifecycle of the digital thread object, specifically including:

[0018] The state machine contains a series of predefined states representing the stages of the digital thread object in the design process; and predefined state transition rules, where each key operation in the design will trigger the state transition of the digital thread object.

[0019] Furthermore, based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including:

[0020] Capture change events of 2D graphics or 3D model entities through event listeners or user triggers;

[0021] The synchronization engine first queries the current state of the digital thread object associated with the entity, and then determines the legality of the change operation based on the state transition rules.

[0022] If the change is valid, the synchronization engine will perform the following operations: a) Update the corresponding properties in the digital thread object; b) Call other related 2D or 3D platform APIs to perform corresponding graphics / model synchronization updates based on the pointers in the digital thread object; c) Trigger the state transition of the digital thread object based on the execution result.

[0023] Furthermore, based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including:

[0024] When the associated 2D graphic entity is deleted, only the state of the corresponding digital thread object is migrated to the orphaned state, while its internal data is retained, forming an orphaned digital thread object.

[0025] When a user creates a new entity, a pre-configured heuristic matching algorithm is used to match and recommend isolated numeric thread objects that can be re-associated. Once the user confirms, the association link can be restored simply by updating the pointer field in the numeric thread object.

[0026] Furthermore, the matching degree calculation of the heuristic matching algorithm is based on one or more of the following weighted combinations: a) whether the spatial distance between the new entity and the original entity corresponding to the isolated digital thread object is less than a preset threshold; b) whether the layer, line type or block definition name of the new entity is consistent with the original entity type recorded by the isolated digital thread object; c) whether the initial attributes manually entered by the new entity match the core logical attribute part of the isolated digital thread object.

[0027] Furthermore, based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including:

[0028] After collision detection and spatial optimization are completed for all device entities in the 3D environment, and the precise 3D coordinates of all device entities are determined, the digital thread objects of the corresponding device entities are transferred to the coordinated state by selecting them in batches. At this time, the synchronization engine is triggered, reads the optimized precise 3D coordinates of the entities in the 3D environment and feeds them back to the 2D environment to complete the coordinate update of the 2D graphic entities, thus achieving reverse synchronization.

[0029] Furthermore, based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including:

[0030] When an illegal operation or a conflict occurs due to simultaneous changes on both ends, the state of the corresponding numeric thread object will be migrated to the conflict state, the corresponding numeric thread object will be highlighted, a version comparison tool will be provided, and the user will be forced to arbitrate. After arbitration, the normal state will be restored.

[0031] Furthermore, the method also includes:

[0032] For the batch creation command of two-dimensional graphic entities in a two-dimensional environment, by capturing the execution event of the batch creation command, after the command is executed, all newly generated entities are traversed, and a digital thread object is instantiated for each entity in a batch and independently. At the same time, the metadata of the digital thread object is recorded to show that its source is the same batch operation, so as to facilitate subsequent group management.

[0033] According to a second aspect, one embodiment provides a data synchronization system for a two-dimensional or three-dimensional heterogeneous platform based on digital thread objects and state machines, the system comprising:

[0034] A central database for storing digital thread objects; client plugins deployed in 2D CAD software and 3D BIM software; and a background synchronization engine responsible for executing state machine logic and data synchronization transactions.

[0035] According to a third aspect, one embodiment provides an electronic device, the device comprising: a processor and a memory;

[0036] The memory is used to store one or more program instructions;

[0037] The processor is configured to run one or more program instructions to perform the steps of a two-dimensional data synchronization method based on digital thread objects and state machines as described in any of the preceding claims.

[0038] This invention provides a two-dimensional and three-dimensional data synchronization method and system based on digital thread objects and state machines, which has the following beneficial effects:

[0039] 1. Fundamental Link Resilience: By introducing digital thread objects with independent lifecycles, this invention elevates the fragile "entity mapping" to a persistent "logical object anchoring," fundamentally solving the link breakage problem caused by operations such as deletion and redrawing, and ensuring the continuity and reliability of the synchronization channel throughout the entire design cycle.

[0040] 2. Deterministic Process Governance: The state machine-based synchronization engine explicitly and systematically solidifies implicit, human-defined design workflows into the system. It precisely defines the modification permissions for data at different stages, achieving a paradigm shift from "disordered synchronization" to "ordered governance," fundamentally avoiding confusion regarding data rights and responsibilities and malicious overwriting.

[0041] 3. Intelligent Conflict Prevention: The mechanism of this invention is not only a "detector" of conflicts, but also a "preventer." Through state management, a large number of illegal operations that do not conform to the current design stage are intercepted in advance, significantly reducing the probability of collaborative errors.

[0042] 4. High architectural scalability: As a neutral abstract entity, the pointer set of the digital thread object can be easily extended to anchor to more types of platforms (such as simulation software and project management systems), providing a solid and scalable data foundation for building digital twins that cover the entire lifecycle of design, construction, and operation and maintenance. Attached Figure Description

[0043] Figure 1 A flowchart illustrating a two-dimensional and three-dimensional data synchronization method based on a digital thread object and a state machine, as provided in one embodiment of the present invention;

[0044] Figure 2 This is a schematic diagram of the digital thread object (DTO) data structure in a two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines, provided in an embodiment of the present invention.

[0045] Figure 3 A finite state machine (FSM) state transition diagram is provided in a two- or three-dimensional data synchronization method based on digital thread objects and state machines, as an embodiment of the present invention.

[0046] Figure 4 A schematic diagram of the link resilience maintenance mechanism in a two-dimensional data synchronization method based on digital thread objects and state machines, provided in an embodiment of the present invention;

[0047] Figure 5 This is a flowchart illustrating the data synchronization process in a two-dimensional / three-dimensional data synchronization method based on digital thread objects and state machines, as provided in one embodiment of the present invention. Detailed Implementation

[0048] The present invention will now be described in further detail with reference to specific embodiments and accompanying drawings. Similar elements in different embodiments are referred to by associated similar element reference numerals. In the following embodiments, many details are described to facilitate a better understanding of the invention. However, those skilled in the art will readily recognize that some features may be omitted in different situations, or may be replaced by other elements, materials, or methods. In some cases, certain operations related to the present invention are not shown or described in the specification. This is to avoid obscuring the core parts of the invention with excessive description. For those skilled in the art, detailed description of these related operations is not necessary; they can fully understand the related operations based on the description in the specification and general technical knowledge in the art.

[0049] Furthermore, the features, operations, or characteristics described in the specification can be combined in any suitable manner to form various embodiments. At the same time, the steps or actions in the method description can be rearranged or adjusted in a manner obvious to those skilled in the art. Therefore, the various orders in the specification and drawings are only for the clear description of a particular embodiment and do not imply a necessary order, unless otherwise stated that a particular order must be followed.

[0050] The first embodiment of this invention provides a two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines. By introducing a "Digital Thread Object (DTO)" as a proxy for an abstract logical entity and integrating it with a "Finite State Machine (FSM)" for process governance, a new paradigm for dynamic data synchronization with high resilience, high reliability, and controllable processes at the architectural level is constructed. The following is a combination of... Figure 1 Please provide a detailed explanation.

[0051] S100, in response to the user's two-dimensional graphic entity creation operation, instantiate a digital thread object for the two-dimensional graphic entity and generate a unique identifier for the digital thread object.

[0052] Instantiation and lifecycle management of Digital Thread Objects (DTOs): This step aims to establish an abstract entity that serves as a "single source of logical fact," independent of any design software. Specifically, it includes:

[0053] S110, Instantiation: When a user creates a logically meaningful object for the first time in a 2D CAD environment using a specific command or from a predefined professional library, the system does not record its graphic information. Instead, it instantiates a Digital Thread Object (DTO) in a central data repository. This DTO is assigned a globally unique and permanent identifier (UUID) whose lifecycle spans the entire project.

[0054] S120, DTO schema definition: A DTO is a structured data container, such as... Figure 2 As shown, its internal schema includes at least: core logical attributes (such as device model, number of cable cores, etc., determined by the initial definition), derived / physical attributes (such as spatial coordinates, calculated length, etc., filled by subsequent processes), the current state identifier of the state machine, and a set of multi-platform pointers pointing to its specific manifestation in each host software (e.g., pointers.autocad_handle, pointers.revit_element_id).

[0055] In this embodiment, for batch creation commands (such as array, offset, and mirror) in a 2D CAD environment, the system plugin will capture the execution event of the command. After the command is executed, the system will traverse all newly generated entities and instantiate a Digital Thread Object (DTO) for each entity in a batch and independently. At the same time, the system can record in the metadata of the DTO that its source is the same batch operation, so as to facilitate subsequent group management.

[0056] S200, establish the association mapping and link relationship between the digital thread object and the corresponding two-dimensional graphic entity ID and three-dimensional model entity ID.

[0057] Dynamic anchoring of DTOs to multi-platform entities: This step aims to establish a resilient anchoring between DTOs and their "avatars" in various software.

[0058] S210, in a 2D CAD environment, writes the persistent identifier (Handle value) of the newly created graphic entity into the autocad_handle pointer field of the corresponding DTO.

[0059] S220: In a 3D BIM environment, after generating a 3D model based on the core logical attributes of the DTO, the unique ID (GUID / ElementId) of the 3D entity is written into the revit_element_id pointer field of the DTO. This process completes the closed loop of the link.

[0060] S300 creates a state machine for each digital thread object, and models and manages the design lifecycle of the digital thread object through the state machine.

[0061] Process governance based on finite state machine (FSM): This step integrates a state machine for each DTO to model and manage its design lifecycle.

[0062] S310, State Definition: The state machine contains a series of predefined states that represent the stage of the DTO in the design process, such as: LOGICALLY_DEFINED, PHYSICALLY_REPRESENTED, COORDINATED, LOCKED, CONFLICTED, ORPHANED, etc.

[0063] S320, State Transition Logic: The system predefines strict state transition rules. For example, the generation of the 3D model can only be triggered when the DTO state is LOGICALLY_DEFINED, and the state transitions to PHYSICALLY_REPRESENTED upon successful generation. Modification operations on a DTO in the LOCKED state will be rejected by the system.

[0064] S400. Based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions.

[0065] S410 is an event-driven, state-aware synchronization engine, executed as follows:

[0066] This step is the core execution logic for data synchronization, and its behavior is strictly constrained by the current state of the DTO.

[0067] S411, Change Event Capture and Parsing: The system captures change events of anchored entities on any platform through event listeners or user triggers.

[0068] S412, Authority and Responsibility Verification: The synchronization engine first queries the current state of the DTO to which the entity is anchored. Based on the state machine rules, it determines the legality of the current change operation. For example, if the DTO state is COORDINATED, it stipulates that only the 3D side has the right to modify its spatial location attributes.

[0069] S413, State-Driven Transaction Execution: If the change is valid, the engine executes a database transaction: a) Updates the corresponding attribute in the DTO; b) Calls another platform API to execute the corresponding model / graphic update based on the pointer in the DTO; c) Triggers the state transition of the DTO based on the execution result (e.g., never updated to SYNCHRONIZED).

[0070] S420, the link resilience maintenance and conflict management mechanism, is as follows:

[0071] This step ensures the link's persistence under abnormal operation.

[0072] S421, Orphaned State Handling: When an anchored 2D entity is deleted, the system migrates the state of the corresponding DTO to ORPHANED and retains all its data. When a user creates a new entity, the system recommends orphaned DTOs for "re-anchoring" using a configurable heuristic matching algorithm. The matching degree calculation of this algorithm is based on at least one or more of the following weighted combinations: a) Whether the spatial distance between the new entity and the original entity of the orphaned DTO is less than a preset threshold; b) Whether the layer, linetype, or block definition name of the new entity is consistent with the original entity type recorded in the orphaned DTO; c) Whether the initial attributes manually entered by the new entity match the core logical attribute part of the orphaned DTO. After user confirmation, the link can be restored simply by updating the pointer in the DTO.

[0073] S422, Conflict State Management: When an illegal operation or simultaneous changes on both ends cause a conflict, the DTO state transitions to CONFLICTED, and synchronization is suspended. The system highlights the DTO on the collaboration platform and provides a version comparison tool, mandating arbitration by the user. Only after arbitration can the normal state be restored.

[0074] Application examples:

[0075] The following example, "Design of GSM-R Communication System for a High-Speed ​​Railway Station," will be used to provide a detailed and specific description of the present invention.

[0076] Step 1: DTO Instantiation and Initial Link Establishment

[0077] Reference Figure 1 In the early stages of the project, the data structure was logically designed by the communications engineers in the AutoCAD environment.

[0078] 1. Creating a logical object: In the station communication equipment room floor plan, the engineer drags a block representing a "Baseband Processing Unit (BBU) cabinet" from the library. The system plugin captures this operation, immediately instantiates a DTO in the central database, and assigns it the UUID: DTO-BBU-01.

[0079] 2. DTO Initialization: The internal data of this DTO is initialized. Core logic attributes are populated with the default information carried by this block (e.g., model: 'BBU5900', power consumption: '800W'). The current state of the state machine is set to LOGICALLY_DEFINED.

[0080] 3. Two-dimensional side anchoring: The Handle value of this block in the CAD file, such as "9E2D", is read and written to the autocad_handle pointer field of DTO-BBU-01. At this point, a logical object is created and anchored in the two-dimensional world.

[0081] 4. 3D Side Anchoring: In the Autodesk Revit environment, the BIM engineer launches the plugin of this invention. The plugin interface will display a list of all DTOs in the LOGICALLY_DEFINED state. The BIM engineer selects DTO-BBU-01 and specifies the computer room floor. The system reads the core attributes of the DTO, automatically loads the corresponding Revit family (BBU5900.rfa), and places it in the initial position. After the Revit family instance is created, its unique ElementId, such as 345678, is written back to the revit_element_id pointer field of DTO-BBU-01.

[0082] 5. State Transition: After the closed-loop link is established, the state of DTO-BBU-01 automatically transitions from LOGICALLY_DEFINED to PHYSICALLY_REPRESENTED, such as... Figure 3 As shown.

[0083] Step 2: State-driven forward synchronization (2D logic changes drive 3D model)

[0084] 1. Change Operation: Due to increased transmission capacity requirements, the communication engineer changed the "Backplane Type" attribute of the block associated with DTO-BBU-01 from "UBBPd" to "UBBPe" in AutoCAD.

[0085] 2. Synchronization Trigger: The engineer clicks the "Synchronize" button in the plugin to trigger the synchronization engine.

[0086] 3. Execute synchronously (refer to...) Figure 5 ):

[0087] The engine detected a change in the properties of the tile with Handle "9E2D";

[0088] The DTO-BBU-01 it is anchored to was found by querying "9E2D";

[0089] The engine detected that the current state of DTO-BBU-01 is PHYSICALLY_REPRESENTED. According to the state machine rules, in this state, the 2D side has the right to modify the core logic attributes, therefore the operation is legal.

[0090] The engine executes the transaction as follows: First, it updates the core logical attribute "Backboard Type" in the DTO to "UBBPe"; then, it finds the Revit family instance with ID 345678 through the revit_element_id pointer, calls the Revit API, and modifies its type parameter "Backboard Type" to "UBBPe" as well; finally, it updates the DTO status to SYNCHRONIZED.

[0091] Step 3: Link resilience maintenance mechanism (to cope with deletion and redraw)

[0092] 1. Deletion operation: In order to adjust the layout, the 2D engineer accidentally deleted the "9E2D" block and redraw a new BBU cabinet block (the new Handle is "A1B3") not far away.

[0093] 2. Isolation and Reanchoring (Refer to) Figure 4 ):

[0094] The synchronization engine detects that "9E2D" has been deleted and immediately migrates the state of DTO-BBU-01 to ORPHANED, but retains all its data and links to the Revit model;

[0095] When a new block "A1B3" is created, the plugin uses a heuristic algorithm (detecting that the new block type is the same as the type of the isolated DTO and the insertion point is close) to pop up a dialog box to the engineer: "A new BBU cabinet has been detected. Do you want to link it to the existing logical device 'DTO-BBU-01'?".

[0096] Once the engineer confirms, the system only needs to perform one database update: update the autocad_handle pointer of DTO-BBU-01 to "A1B3" and restore its state to PHYSICALLY_REPRESENTED. The entire lifecycle of the logical object is extended, avoiding the creation of data silos.

[0097] Step 4: State-based responsibility management and reverse synchronization (3D spatial optimization feedback 2D)

[0098] 1. Transfer of Responsibilities: In Revit, the BIM engineer performed detailed clash checks and spatial optimization on all equipment in the computer room, determining the final precise coordinates of all equipment. After completion, the BIM engineer selected these devices in batches and used a plugin to set their corresponding DTO status to COORDINATED.

[0099] 2. Reverse synchronization:

[0100] In the COORDINATED state, the derived / physical properties of DTO-BBU-01, specifically the spatial coordinates, are updated with the precise coordinates in Revit.

[0101] The synchronization engine is triggered, and it checks that the DTO status is COORDINATED. In this state, sovereignty over spatial coordinates lies with the 3D side;

[0102] The engine reads the updated coordinates, finds the "A1B3" block in the CAD through the autocad_handle pointer, calls the AutoCAD API, and moves its position to the two-dimensional coordinate point that precisely corresponds to the three-dimensional model.

[0103] 3. Conflict prevention:

[0104] At this point, if the 2D engineer attempts to move the "A1B3" tile again, the synchronization engine will find in the responsibility verification step that the 2D side has no right to modify the spatial position of the DTO in the COORDINATED state.

[0105] Synchronization will be rejected, and a prompt will appear to the 2D engineer: "The spatial location of this device has been coordinated and locked in the BIM model. If modifications are required, please initiate a design change process." This achieves process-based intelligent management.

[0106] Through the above embodiments, this invention demonstrates how to construct a robust and intelligent two-dimensional dynamic synchronization system capable of handling various complex situations in real-world design scenarios by utilizing the two core innovations of DTO and FSM.

[0107] Corresponding to the aforementioned method for 2D / 3D data synchronization based on digital thread objects and state machines, this invention also discloses a 2D / 3D heterogeneous platform data synchronization system based on digital thread objects and state machines, which specifically includes:

[0108] A central database used to store digital thread objects;

[0109] Client-side plugins deployed in 2D CAD software and 3D BIM software;

[0110] And a background synchronization engine responsible for executing state machine logic and data synchronization transactions.

[0111] It should be noted that for a detailed description of the two-dimensional and three-dimensional heterogeneous platform data synchronization system based on digital thread objects and state machines provided in the embodiments of the present invention, please refer to the relevant description of the two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines provided in the embodiments of the present invention, which will not be repeated here.

[0112] In addition, embodiments of the present invention also provide an electronic device, the device comprising: a processor and a memory; the memory being used to store one or more program instructions; the processor being used to execute one or more program instructions to perform the steps of a two-dimensional data synchronization method based on digital thread objects and state machines as described in any of the preceding embodiments.

[0113] It should be noted that for a detailed description of an electronic device provided in the embodiments of the present invention, please refer to the relevant description of a two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines provided in the embodiments of the present invention, which will not be repeated here.

[0114] Those skilled in the art will understand that all or part of the functions of the various methods in the above embodiments can be implemented by hardware or by computer programs. When all or part of the functions in the above embodiments are implemented by computer programs, the program can be stored in a computer-readable storage medium, which may include: read-only memory, random access memory, disk, optical disk, hard disk, etc., and the program is executed by a computer to achieve the above functions. For example, the program can be stored in the memory of a device, and when the program in the memory is executed by the processor, all or part of the above functions can be achieved. In addition, when all or part of the functions in the above embodiments are implemented by computer programs, the program can also be stored in a server, another computer, disk, optical disk, flash drive, or external hard drive, etc., and can be downloaded or copied to the memory of a local device, or the system of the local device can be updated. When the program in the memory is executed by the processor, all or part of the functions in the above embodiments can be achieved.

[0115] The above examples illustrate the present invention only to aid in understanding it and are not intended to limit the scope of the invention. Those skilled in the art can make various simple deductions, modifications, or substitutions based on the principles of this invention.

Claims

1. A two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines, characterized in that, The method includes: In response to the user's two-dimensional graphic entity creation operation, a digital thread object is instantiated for the two-dimensional graphic entity, and a unique identifier for the digital thread object is generated; Establish the association mapping and link relationship between the digital thread object and the corresponding two-dimensional graphic entity ID and three-dimensional model entity ID; A state machine is created for each digital thread object, and the design lifecycle of the digital thread object is modeled and managed through the state machine; Based on the digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions.

2. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 1, characterized in that, In response to a user's operation to create a two-dimensional graphic entity, a digital thread object is instantiated for the two-dimensional graphic entity, specifically including: The digital thread object is defined as a structured data container, whose internal schema includes: core logical attributes, derived / physical attributes, current state identifier of the state machine, and a set of multi-platform pointers pointing to its specific representation in various two-dimensional or three-dimensional host software.

3. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 1, characterized in that, Establishing the association mapping and link relationship between the digital thread object and the corresponding two-dimensional graphic entity ID and three-dimensional model entity ID, specifically including: In a two-dimensional environment, the Handle value of the newly created two-dimensional graphic entity is written to the autocad_handle pointer field of the corresponding digital thread object; In a 3D environment, after generating a 3D model based on the core logical attributes of the digital thread object, the GUID / ElementId of the 3D model entity is written into the revit_element_id pointer field of the digital thread object.

4. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 1, characterized in that, A state machine is created for each digital thread object to model and manage the design lifecycle of the digital thread object. Specifically, this includes: The state machine contains a series of predefined states representing the stages of the digital thread object in the design process; and predefined state transition rules, where each key operation in the design will trigger the state transition of the digital thread object.

5. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 4, characterized in that, Based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including: Capture change events of 2D graphics or 3D model entities through event listeners or user triggers; The synchronization engine first queries the current state of the digital thread object associated with the entity, and then determines the legality of the change operation based on the state transition rules. If the change is valid, the synchronization engine will perform the following operations: a) Update the corresponding properties in the digital thread object; b) Call other related 2D or 3D platform APIs to perform corresponding graphics / model synchronization updates based on the pointers in the digital thread object; c) Trigger the state transition of the digital thread object based on the execution result.

6. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 1, characterized in that, Based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including: When the associated 2D graphic entity is deleted, only the state of the corresponding digital thread object is migrated to the orphaned state, while its internal data is retained, forming an orphaned digital thread object. When a user creates a new entity, a pre-configured heuristic matching algorithm is used to match and recommend isolated numeric thread objects that can be re-associated. Once the user confirms, the association link can be restored simply by updating the pointer field in the numeric thread object.

7. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 6, characterized in that, The matching degree calculation of the heuristic matching algorithm is based on one or more of the following weighted combinations: a) whether the spatial distance between the new entity and the original entity corresponding to the isolated digital thread object is less than a preset threshold; b) whether the layer, line type or block definition name of the new entity is consistent with the original entity type recorded by the isolated digital thread object; c) Whether the initial attributes manually entered by the new entity match the core logical attribute portion of the orphaned numeric thread object.

8. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 4, characterized in that, Based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including: After collision detection and spatial optimization are completed for all device entities in the 3D environment, and the precise 3D coordinates of all device entities are determined, the digital thread objects of the corresponding device entities are transferred to the coordinated state by selecting them in batches. At this time, the synchronization engine is triggered, reads the optimized precise 3D coordinates of the entities in the 3D environment and feeds them back to the 2D environment to complete the coordinate update of the 2D graphic entities, thus achieving reverse synchronization.

9. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 4, characterized in that, Based on the aforementioned digital thread object and state machine, a synchronization engine is used to perform bidirectional data synchronization in two dimensions and three dimensions, specifically including: When an illegal operation or a conflict occurs due to simultaneous changes on both ends, the state of the corresponding numeric thread object will be migrated to the conflict state, the corresponding numeric thread object will be highlighted, a version comparison tool will be provided, and the user will be forced to arbitrate. After arbitration, the normal state will be restored.

10. The two-dimensional and three-dimensional data synchronization method based on digital thread objects and state machines according to claim 1, characterized in that, The method further includes: For the batch creation command of two-dimensional graphic entities in a two-dimensional environment, by capturing the execution event of the batch creation command, after the command is executed, all newly generated entities are traversed, and a digital thread object is instantiated for each entity in a batch and independently. At the same time, the metadata of the digital thread object is recorded to show that its source is the same batch operation, so as to facilitate subsequent group management.