A method and system for building, compiling and deploying CAA custom feature plug-ins

The rapid and automated compilation and deployment of OSM custom feature plug-ins using C/C++ language solves the tedious operation and high resource consumption issues of Dassault's CATfctEditorAssistant.exe tool, enables efficient CAA custom feature development, and improves the development experience and the degree of automation.

CN118819537BActive Publication Date: 2025-10-10CHANGJIANG SURVEY PLANNING DESIGN & RES CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410807320.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-21
Publication Date
2025-10-10
Estimated Expiration
2044-06-21

AI Technical Summary

Technical Problem

Dassault's CATfctEditorAssistant.exe dictionary compilation assistant tool is tedious to operate, slow to run, consumes large resources, and has a low degree of automation, resulting in low efficiency in CAA custom feature development.

Method used

Use C/C++ language to quickly and automatically compile and deploy OSM custom feature plug-ins, including syntax checking and formatting functions, directly call the underlying interface, avoid network connection and resource initialization, directly generate CATfct dictionary files and deploy them to the runtime environment.

Benefits of technology

The efficiency of CAA custom feature OSM compilation has been significantly improved from minutes to milliseconds, and memory resource usage has been reduced by 99%, improving the automation and intelligence of the development experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118819537B_ABST
    Figure CN118819537B_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of three-dimensional design development, and discloses a method for constructing, compiling and deploying a CAA custom feature plug-in. The plug-in programmed by C / C++ language can automatically perform syntax checking, formatting, feature compiling and deployment, so that the automation and intelligent degree of the CAA feature development process can be improved, and the development experience can be improved. Based on the same idea, the application also provides a system for constructing, compiling and deploying a CAA custom feature plug-in. The above method is executed through a functional module, and is suitable for programmers to use when performing secondary development on a 3DE platform component application architecture (CAA).
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of three-dimensional design and development, and specifically discloses a method and system for constructing, compiling and deploying CAA custom feature plug-ins. Background Art

[0002] The Dassault Systemes 3DE platform is the mainstream 3D design and BIM application platform in today's water conservancy and hydropower industry. Featuring four key components: collaborative design, analytical calculations, construction simulation, and business intelligence, it boasts powerful functionality and widespread application. The 3DE platform's secondary development suite consists of CAA+RADE. The CAA component application architecture, developed based on component-oriented programming, enables binary-level reuse and modular development, making it a mainstream approach to large-scale industrial software development. RADE, a plug-in for the Microsoft Visual Studio integrated development environment (IDE), provides CAA development functionality, including code creation, compilation and linking, unit testing, and debugging.

[0003] The geometric modeling engine of the Dassault 3DE platform is the CGM core, which provides a complete set of solutions such as interoperability, solid modeling, polyhedron modeling, advanced free-form surfaces, feature recognition, and constraint solving. Among them, features are the most basic concept of 3D design. All geometric objects are ultimately abstracted as features based on the OOP concept. Therefore, 3D design is also called feature-oriented modeling, and everything is a feature. Therefore, CAA development often requires custom feature scenarios. Although Dassault RADE provides the CATfctEditorAssistant.exe dictionary compilation auxiliary tool specifically for feature development, unfortunately, the tool has weak functions, tedious operations, slow compilation and operation, and a low degree of automation, which is not friendly to developers.

[0004] Under the conventional thinking mode, there are seven main steps to develop custom features using the Dassault Systèmes dictionary compilation tool CATfctEditorAssistant.exe: ① Set the login ticket environment variable CATFctEditorAssistant_login, including the user name and login ticket. The login ticket is a long string that needs to be applied for in advance on the web page; ② Use the ticket of this environment variable to create a session and establish a connection on the platform server backend; ③ Initialization, use the -create-new-catalog option to create an empty catalog dictionary file with the file suffix .CATfct (this file is a binary file and cannot be read). At the same time, this step also requires the use of -with-client-id to provide the user password. All subsequent steps require this password to access; ④ Decompile, use the -describe-as-osm option to decompile the empty dictionary file into a feature source file with the file suffix .osm (this file is a text file and can be read) with some initial fields; ⑤ Modify based on the decompiled OSM feature source file and add custom feature business logic; ⑥ Recompile, use the -update-catalog option to compile and update the user OSM feature source file into the final dictionary file. ⑦ Deploy the final dictionary file to the CATGraphicPath runtime environment of the 3DE platform client to take effect.

[0005] From the above steps, we can see that in order to solve the problem that the Dassault Systèmes CATfctEditorAssistant.exe dictionary compilation auxiliary tool is very cumbersome to use, first of all, the second step of creating a session with the server is very time-consuming (often taking 2-5 minutes), and occupies a very large amount of memory (about 200M) and network and other hardware resources; secondly, the degree of automation is very low, and it is necessary to repeatedly create CATfct dictionary files, decompile them into OSM feature source files, and then compile them into CATfct dictionary files. These files have strict requirements on file names and suffixes, which is very easy to make mistakes; finally, they need to be deployed to the runtime environment directory to take effect.

[0006] Therefore, in order to address the shortcomings of Dassault's CATfctEditorAssistant.exe, such as tedious operations, slow operation, high resource consumption, and low degree of automation, the present invention proposes a method for quickly and automatically compiling and deploying OSM custom features. This method is implemented in C / C++ language and published as a plug-in. In addition to realizing feature compilation, it can also provide auxiliary functions such as syntax checking and formatting, which can improve the automation and intelligence of CAA feature development and help enhance the development experience. Summary of the Invention

[0007] To overcome the above shortcomings, the present invention provides a method for building, compiling, and deploying a CAA custom feature plug-in, comprising the following steps: reading a user-defined feature OSM source file, and sequentially checking the following contents for syntax errors: document node, global attribute security field, container node, container metadata node, and document metadata node;

[0008] Get the calling context by using the symbolic address obtained by GetProcAddress (Microsoft's own program); build the calling parameter list; display the calling symbols and compile the OSM features into a CATfct dictionary file;

[0009] Deploy the compiled CATfct (Dassault Software's own program) dictionary file to the runtime environment to complete the construction of the CAA custom feature plug-in; the deployment includes obtaining the runtime CATGraphicPath (Dassault Software's own program) environment variable, using semicolons to separate it into a set of path directories; checking whether the dictionary file is already located in the path directory; if it already exists, overwrite the original version; if it does not exist, copy it to the first user directory.

[0010] Preferably, the checking of the document node includes the following steps:

[0011] S1. Check the document node format. If it is not closed with {}, an error is returned.

[0012] S2. Check the document header for special rules. If the document name does not end with .CATfct, an error is returned.

[0013] S3. Check the general rules of the document header, including but not limited to returning an error when one or more of the following conditions occur: the identifier is not unique, the attribute field does not have a # prefix, special characters are not enclosed in double quotes, or the attribute field is illegal;

[0014] S4. Enter {} to verify the lower-level nodes.

[0015] Preferably, the inspection of the container node includes the following steps:

[0016] S1. Check the container node format. If it is not enclosed with {}, an error is returned.

[0017] S2. Check the container header special rules and add the mandatory attribute #root if it is not included;

[0018] S3. Check compliance with the general rules of the container header; if not, return an error;

[0019] S4. Enter the {} inner loop to verify the attribute type declaration and initialization assignment.

[0020] Preferably, checking the container metadata node includes the following steps:

[0021] S1. Check the metadata node format. If it is not enclosed with {}, an error is returned.

[0022] S2. Check the metadata header for compliance with general rules; if not, return an error;

[0023] S3. Enter the {} inner loop to verify the attribute type declaration and initialization assignment.

[0024] Preferably, the calling parameter list includes parameter 1, parameter 2 and parameter 3; wherein parameter 1 is of type int, which refers to the group length selected by parameter 2; parameter 2 is of type char**const, which is a constant string array, including the compilation action, user password, the osm path name to be compiled, and the compiled dictionary output name; wherein the input osm file name must be the full path name, and the output dictionary name must be consistent with the document field defined in osm; parameter 3 serves as a calling identifier, and its type is a char const* constant string.

[0025] Based on the same idea, the present invention also provides a system for building, compiling, and deploying CAA custom feature plug-ins, including the following functional modules:

[0026] The check module is used to read the user-defined feature OSM source file and check the following contents in turn for syntax errors: document node, global attribute security field, container node, container metadata node, and document metadata node;

[0027] Compile module, used to obtain the call context through the symbol address obtained by GetProcAddress; build the call parameter list; display the call symbol, and compile OSM features into CATfct dictionary file;

[0028] The deployment module is used to deploy the compiled CATfct dictionary file to the runtime environment to complete the construction of the CAA custom feature plug-in; the deployment includes obtaining the runtime CATGraphicPath environment variable and using semicolons to separate it into a group of path directories; checking whether the dictionary file is already located in the path directory; if it already exists, overwriting the original version; if it does not exist, copying it to the first user directory.

[0029] Preferably, the checking of the document node in the checking module includes the following steps:

[0030] S1. Check the document node format. If it is not closed with {}, an error is returned.

[0031] S2. Check the document header for special rules. If the document name does not end with .CATfct, an error is returned.

[0032] S3. Check the document header general rules, including but not limited to the following one or more cases, return an error: identifier is not unique, attribute field without # prefix, special characters are not contained in double quotes, attribute field is not legal;

[0033] S4. Enter the {} internal verification of the lower level nodes.

[0034] Preferably, the checking of the container node in the checking module comprises the following steps:

[0035] S1. Check the container node format, if not closed with {}, return an error;

[0036] S2. Check the container header special rules, if not contain the mandatory attribute #root, add it;

[0037] S3. Check the compliance of the container header general rules, if not, return an error;

[0038] S4. Enter the {} internal loop to check the attribute type declaration and initialization assignment.

[0039] Preferably, the checking of the container metadata node in the checking module comprises the following steps:

[0040] S1. Check the metadata node format, if not closed with {}, return an error;

[0041] S2. Check the compliance of the metadata header general rules, if not, return an error;

[0042] S3. Enter the {} internal loop to check the attribute type declaration and initialization assignment.

[0043] Preferably, the calling parameter list in the compiling module comprises parameter 1, parameter 2 and parameter 3; wherein parameter 1 is of int type, indicating the group length selected by parameter 2; parameter 2 is of char**const type, which is a constant string array, including the compiling action, user password, osm path name to be compiled and the output name of the compiled dictionary; wherein the input osm file name must be a full path name, and the output dictionary name must be consistent with the document field defined in the osm; parameter 3 is used as a calling identifier, and is of charconst* constant string type.

[0044] Compared with the prior art, the present application has the following beneficial effects:

[0045] This solution independently encapsulates the calling environment, eliminating the need to establish a network session with the server in advance. This eliminates potential network delays and fluctuations, significantly improving the efficiency of CAA custom feature OSM compilation from minutes to milliseconds. Furthermore, by directly calling the underlying interface, unnecessary dynamic library loading and resource initialization are avoided, easily reducing memory resource usage by over 99%.

[0046] Secondly, the technical solution of the present invention is completely based on the developer's perspective. It can quickly compile the final CATfct dictionary file based on the OSM feature source file with one click, shielding all unnecessary intermediate links in traditional feature development, such as creating sessions, repeated compilation, etc., and can automatically realize the OSM feature from definition to compilation to deployment and effectiveness, which is conducive to allowing developers to focus on the implementation of OSM feature business logic, get rid of dependence on Dassault's CATfctEditorAssistant.exe tool, and self-encapsulate the context calling environment to complete feature compilation, which has good flexibility. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 This is a schematic diagram showing steps saved in the operation process according to the embodiment of the present invention compared to the original operation process;

[0048] Figure 2 This is a schematic diagram of a grammar checking process according to an embodiment of the present invention;

[0049] Figure 3 It is a schematic diagram of the feature compilation process in an embodiment of the present invention. DETAILED DESCRIPTION

[0050] To make the objectives, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention will be described below in conjunction with the accompanying drawings. The described embodiments are part of the embodiments of the present invention, but not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without making any innovative efforts shall fall within the scope of protection of the present invention.

[0051] In conjunction with the instructions Figure 1-3 The specific steps of a method for building, compiling, and deploying a CAA custom feature plug-in are as follows:

[0052] Step 1: Read the user-defined feature osm source file and parse the syntax line by line; see the syntax parsing flowchart Figure 2 .

[0053] Step 1.1 Check the document node

[0054] ① Check the document node format and use curly braces {} to close it; if not, return an error.

[0055] ② Check the document header special rules to see if the document name ends with .CATfct; if not, return an error.

[0056] ③ Check the general rules of the document header, including whether the identifier ID is unique, whether the attribute field has a # prefix, whether special characters are enclosed in quotation marks, and whether the attribute field is legal; if not, return an error.

[0057] ④ Enter the document body (i.e. inside the curly brackets) and start verifying the lower-level nodes.

[0058] Step 1.2 Check the global attribute security field

[0059] ① Check whether the global attribute security field check_revision and the hisroy historical version field exist;

[0060] ② If it exists, check whether the UUID value (universally unique identifier) ​​is legal; if it does not exist, generate and fill it;

[0061] Step 1.3 Check the container node

[0062] ① Check the container node format to see if it is enclosed in curly braces {}; if not, return an error.

[0063] ② Check the container header special rules to see if they contain the mandatory attribute #root. If not, add it.

[0064] ② Check the general rules of the container header; if not, return an error.

[0065] ③ Enter the container body (i.e. inside the braces) and start cyclically checking the feature nodes.

[0066] ④ Check the format of the container feature node to see if it is enclosed in curly braces {}; if not, return an error.

[0067] ⑤ Check the general rules of the feature header; if not, return an error.

[0068] ⑥ Enter the feature body to verify the attribute type declaration and initialization assignment.

[0069] ⑦ Exit the current feature node and continue to check the next feature until exiting the container body.

[0070] Step 1.4 Check the container metadata node

[0071] ① Check the metadata node format to see if it is enclosed in curly braces {}; if not, return an error.

[0072] ② Check the general rules of metadata header; if not, return an error.

[0073] ③ Enter the metadata and verify the attribute type declaration and initialization assignment.

[0074] ④ Exit the current metadata node and continue checking the next metadata until exiting the document body.

[0075] Step 1.5 Check that there is no extra content in the document metadata node, then exit normally and complete the preprocessing process

[0076] Step 2: Compile OSM features into CATfct dictionary file.

[0077] ① Get the calling context. The compiled OSM function is named CATOsmCatalogUtilities and is located in the CATOsmCatalogUtilities.dll dynamic library under the 3DE platform client running directory. However, this method is an internal method and cannot be called directly. Therefore, you need to use GetProcAddress to get the symbol address and get the calling context before you can use it.

[0078] ② Construct a call parameter list, where parameter 1 is of type int, which refers to the group length selected by parameter 2; parameter 2 is of type char**const, a constant string array, including the compilation action, user password, the path name of the osm to be compiled, and the compiled dictionary output name. The input osm file name must be the full path name, and the output dictionary name must be consistent with the document field defined in osm; parameter 3 is of type char const*, a constant string, which is the call identifier.

[0079] ③ Explicitly call symbolic execution compilation to compile the osm source file into a CATfct dictionary file.

[0080] Step 3: Deploy the compiled CATfct dictionary file to the runtime environment to take effect.

[0081] ① Get the runtime CATGraphicPath environment variable and use semicolons to separate it into a group of path directories.

[0082] ② Check whether the dictionary file is already located in the above path directory; if it exists, overwrite the original version.

[0083] ③If it does not exist, copy it to the first user directory and the deployment will take effect.

[0084] A system for building, compiling and deploying CAA custom feature plug-ins is just a way of expressing the above method using virtual modules, and the basic content is unchanged. The embodiments of the system are not described here again.

[0085] Those skilled in the art will appreciate that embodiments of the present application can be provided as methods, systems, or computer program products. Accordingly, the present application can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application can take the form of a computer program product on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROMs, optical storage devices, etc.) embodying computer readable program code.

[0086] The present application is described in reference to the flow diagrams and / or block diagrams of the methods, apparatus (systems) and computer program products according to embodiments of the present application. It should be understood that each flow and / or block in the flow diagrams and / or block diagrams, and combinations of flows and / or blocks in the flow diagrams and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general purpose computer, special purpose computer, embedded processing machine, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flow diagrams and / or block diagrams block or blocks. Figure 1 one or more flows and / or blocks Figure 1 means for carrying out the function specified by the flow or flows and / or block or blocks.

[0087] These computer program instructions can also be stored in a computer- readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instructions which implement the flow diagrams and / or block diagrams flow or flows and / or block or blocks. Figure 1 one or more flows and / or blocks Figure 1 means for carrying out the function specified by the flow or flows and / or block or blocks.

[0088] These computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the flow diagrams and / or block diagrams flow or flows and / or block or blocks. Figure 1 one or more flows and / or blocks Figure 1 means for carrying out the function specified by the flow or flows and / or block or blocks.

[0089] Finally, it should be noted that the above only describes the preferred embodiments of the present application and is not intended to limit the present application. Although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art will appreciate that the technical solutions described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalent ones. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A method for building, compiling, and deploying a CAA custom feature plug-in, characterized in that , including the following steps: Read the user-defined feature OSM source file and check the following contents in turn for syntax errors: document node, global attribute security field check_revision, container node, container metadata node, and document metadata node; Get the calling context through the symbolic address obtained by GetProcAddress; Build call parameter list; display call symbols, compile OSM features into CATfct dictionary file; The calling parameter list includes parameter 1, parameter 2 and parameter 3; parameter 1 is of type int, which refers to the group length selected by parameter 2; parameter 2 is of type char**const, which is a constant string array, including the compilation action, user password, the osm path name to be compiled, and the compiled dictionary output name; The input osm file name must be the full path name, and the output dictionary name must be consistent with the document field defined in osm; parameter 3 is the call identifier, and its type is a charconst* constant string; Deploy the compiled CATfct dictionary file to the runtime environment to complete the construction of the CAA custom feature plug-in; the deployment includes obtaining the runtime CATGraphicPath environment variable, using semicolons to separate it into a set of path directories; and checking whether the dictionary file is already located in the path directory; If it already exists, overwrite the original version; If it does not exist, copy it to the first user directory.

2. A method for building, compiling, and deploying a CAA custom feature plug-in according to claim 1, characterized in that: The inspection of the document node consists of the following steps: S1. Check the document node format. If it is not closed with {}, an error is returned. S2. Check the document header for special rules. If the document name does not end with .CATfct, an error is returned. S3. Check the general rules of the document header, including but not limited to returning an error when one or more of the following conditions occur: the identifier is not unique, the attribute field does not have a # prefix, special characters are not enclosed in double quotes, or the attribute field is illegal; S4. Enter {} to verify the lower-level nodes.

3. The method for building, compiling, and deploying a CAA custom feature plug-in according to claim 2, wherein: Checking the container node includes the following steps: S1. Check the container node format. If it is not enclosed with {}, an error is returned. S2. Check the container header special rules and add the mandatory attribute #root if it is not included; S3. Check compliance with the general rules of the container header; if not, return an error; S4. Enter the {} inner loop to verify the attribute type declaration and initialization assignment.

4. A method for building, compiling, and deploying a CAA custom feature plug-in according to claim 3, characterized in that: Checking the container metadata node includes the following steps: S1. Check the metadata node format. If it is not enclosed with {}, an error is returned. S2. Check the metadata header for compliance with general rules; if not, return an error; S3. Enter the {} inner loop to verify the attribute type declaration and initialization assignment.

5. A system for building, compiling, and deploying CAA custom feature plug-ins, characterized in that: Includes the following functional modules: The check module is used to read the user-defined feature OSM source file and check the following contents in sequence for syntax errors: document node, global attribute security field check_revision, container node, container metadata node, and document metadata node; Compile the module to get the calling context through the symbol address obtained by GetProcAddress; Build call parameter list; display call symbols, compile OSM features into CATfct dictionary file; The calling parameter list includes parameter 1, parameter 2 and parameter 3; parameter 1 is of type int, which refers to the group length selected by parameter 2; parameter 2 is of type char**const, which is a constant string array, including the compilation action, user password, the osm path name to be compiled, and the compiled dictionary output name; The input osm file name must be the full path name, and the output dictionary name must be consistent with the document field defined in osm; parameter 3 is the call identifier, and its type is a charconst* constant string; The deployment module is used to deploy the compiled CATfct dictionary file to the runtime environment to complete the construction of the CAA custom feature plug-in; the deployment includes obtaining the runtime CATGraphicPath environment variable, using semicolons to separate it into a group of path directories; and checking whether the dictionary file is already located in the path directory; If it already exists, overwrite the original version; If it does not exist, copy it to the first user directory.

6. A system for building, compiling, and deploying a CAA custom feature plug-in according to claim 5, characterized in that: The inspection of the document node in the inspection module includes the following steps: S1. Check the document node format. If it is not closed with {}, an error is returned. S2. Check the document header for special rules. If the document name does not end with .CATfct, an error is returned. S3. Check the general rules of the document header, including but not limited to returning an error when one or more of the following conditions occur: the identifier is not unique, the attribute field does not have a # prefix, special characters are not enclosed in double quotes, or the attribute field is illegal; S4. Enter {} to verify the lower-level nodes.

7. A system for building, compiling, and deploying a CAA custom feature plug-in according to claim 6, characterized in that: The inspection module checks the container node, including the following steps: S1. Check the container node format. If it is not enclosed with {}, an error is returned. S2. Check the container header special rules and add the mandatory attribute #root if it is not included; S3. Check compliance with the general rules of the container header; if not, return an error; S4. Enter the {} inner loop to verify the attribute type declaration and initialization assignment.

8. The system for building, compiling, and deploying a CAA custom feature plug-in according to claim 7, wherein: The inspection of the container metadata node in the inspection module includes the following steps: S1. Check the metadata node format. If it is not enclosed with {}, an error is returned. S2. Check the metadata header for compliance with general rules; if not, return an error; S3. Enter the {} inner loop to verify the attribute type declaration and initialization assignment.

Citation Information

Patent Citations

  • RSA offline encryption technology suitable for CAA secondary development software

    CN114239012A

  • CAA secondary development method and system based on VsCode

    CN116185422A