CN113177292B - Universal BIM secondary development implementation method and device - Google Patents

Universal BIM secondary development implementation method and device Download PDF

Info

Publication number
CN113177292B
CN113177292B CN202110362087.7A CN202110362087A CN113177292B CN 113177292 B CN113177292 B CN 113177292B CN 202110362087 A CN202110362087 A CN 202110362087A CN 113177292 B CN113177292 B CN 113177292B
Authority
CN
China
Prior art keywords
modeling software
development
bim
environment
universal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110362087.7A
Other languages
Chinese (zh)
Other versions
CN113177292A (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.)
Third Engineering Co Ltd of China Railway Electrification Engineering Group Co Ltd
Original Assignee
Third Engineering Co Ltd of China Railway Electrification Engineering Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Third Engineering Co Ltd of China Railway Electrification Engineering Group Co Ltd filed Critical Third Engineering Co Ltd of China Railway Electrification Engineering Group Co Ltd
Priority to CN202110362087.7A priority Critical patent/CN113177292B/en
Publication of CN113177292A publication Critical patent/CN113177292A/en
Application granted granted Critical
Publication of CN113177292B publication Critical patent/CN113177292B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Evolutionary Computation (AREA)
  • Geometry (AREA)
  • Stored Programmes (AREA)

Abstract

The invention provides a general BIM secondary development realization method and device, wherein the method comprises the following steps: packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to a plurality of modeling software; packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; in a general development environment, writing a plugin by calling the general interface function so as to carry out BIM secondary development; determining the modeling software selected at present, and modifying the plug-in by adopting a script and a code corresponding to the modeling software selected at present so as to adapt to the modeling software selected at present, thereby completing secondary development operation. The method of the invention allows the developer to only concentrate on the upper layer application when developing the BIM plug-in for the second time, and does not need to care about the environment and the bottom layer realization, namely, one plug-in can be suitable for different BIM modeling software, thereby saving the development time and reducing the working difficulty.

Description

Universal BIM secondary development implementation method and device
Technical Field
The invention relates to the technical field of computers, in particular to a general BIM secondary development realization method and device.
Background
There are many BIM modeling software in the market, such as Revit, bentley, CATIA, when these software are developed secondarily, different development interfaces are often needed to be adapted to different software, for example, revit needs to introduce two interface component files, namely Revit API. Dll and Revit APIUI. Dll, a namespace reference of Revit API is added at the head of a program, a transaction mode and an update mode are set, new classes are created, and a method of a reloading function is derived from the interfaces; for the secondary development of the micro of Bentley, one set of NET programs can run as Addins under the micro station, three conditions need to be met: (1) comprises a class derived from bentley. (2) The derived class must provide a one-parameter (MDL descriptor of IntPtr type) constructor that needs to be linked to the base class constructor; (3) the derived class must cover the virtual method Run () in the Addin base class.
The secondary development of different software requires different environments and interfaces, so that technicians can need a lot of repeated workload due to different platforms if the plug-ins with the same function are to be developed, the working difficulty is increased, and the implementation of the functions of the specific plug-ins cannot be focused.
Disclosure of Invention
The invention provides a general BIM secondary development implementation method and device, which are used for solving the problems that in the prior art, different environments and interfaces are needed for secondary development of different software, so that technicians need a lot of repeated workload because of different platforms if plug-ins with the same function are to be developed, the working difficulty is increased, and the implementation of the functions of specific plug-ins cannot be focused. The method has the advantages that the method can be suitable for different BIM modeling software by writing one plug-in, saves development time and reduces working difficulty.
In a first aspect, the present invention provides a general BIM secondary development implementation method, including:
packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software;
packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software;
in the general development environment, writing a plugin by calling the general interface function so as to perform BIM secondary development;
Determining the modeling software selected currently, and modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, thereby completing secondary development operation.
Further, the invention provides a method for implementing secondary development of a universal BIM, wherein the method for packaging development environments of multiple modeling software of the BIM to obtain a packaged universal development environment comprises the following steps:
determining environment requirements respectively corresponding to a plurality of modeling software;
and writing a script according to the environment requirements respectively corresponding to the modeling software to realize the encapsulation of the development environment of the modeling software of the BIM and obtain an encapsulated general development environment.
Further, the invention provides a method for implementing secondary development of universal BIM, wherein the method for packaging interface functions of multiple modeling software of BIM to obtain packaged universal interface functions comprises the following steps:
determining interface function requirements respectively corresponding to a plurality of modeling software;
and writing codes according to the interface function requirements respectively corresponding to the modeling software to package the interface functions of the modeling software of the BIM so as to obtain a packaged general interface function.
Further, the present invention provides a method for implementing a universal BIM secondary development, wherein in the universal development environment, by calling the universal interface function, a plug-in is written to perform the BIM secondary development, including:
and writing a plug-in by calling the universal interface function in the universal development environment according to the secondary development function to be realized so as to carry out BIM secondary development.
Further, the present invention provides a general BIM secondary development implementation method, wherein, determining the modeling software selected currently, modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently, so as to adapt to the modeling software selected currently, and completing secondary development operation, including:
determining currently selected modeling software, and extracting an environment script corresponding to the currently selected modeling software from the general development environment;
extracting an interface function corresponding to the currently selected modeling software from the universal interface function;
and modifying the plug-in based on the environment script corresponding to the currently selected modeling software and the interface function corresponding to the currently selected modeling software so as to adapt to the currently selected modeling software, and completing secondary development operation.
Further, the invention provides a general BIM secondary development implementation method, wherein the plurality of modeling software comprises Revit, microstation, OBD, ORD and CATIA.
In a second aspect, the present invention provides a universal BIM secondary development implementation apparatus, including:
the development environment packaging module is used for packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software;
the interface function packaging module is used for packaging the interface functions of the BIM modeling software to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software;
the first development module is used for compiling a plug-in by calling the universal interface function in the universal development environment so as to carry out BIM secondary development;
and the second development module is used for determining the modeling software selected currently, modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, and completing secondary development operation.
Further, the invention provides a general BIM secondary development implementation device, wherein the development environment packaging module is further used for:
determining environment requirements respectively corresponding to a plurality of modeling software;
and writing a script according to the environment requirements respectively corresponding to the modeling software to realize the encapsulation of the development environment of the modeling software of the BIM and obtain an encapsulated general development environment.
In a third aspect, the invention provides an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of any of the methods described above when the program is executed.
In a fourth aspect, the present invention provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of any of the methods described above.
According to the method and the device for realizing the secondary development of the universal BIM, provided by the invention, the development environments of various modeling software of the BIM are packaged to obtain the packaged universal development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software; meanwhile, packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software; the generalization of the development environment and the interface function is realized through the two steps. And then, in the general development environment, writing a plugin by calling the general interface function so as to perform BIM secondary development. Then, the developer determines the modeling software selected currently, and modifies the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, thereby completing secondary development operation. When developing BIM plug-ins for the second time, the developer only concentrates on the upper layer application, does not need to care about the environment and the bottom layer realization, namely, one plug-in can be applicable to different BIM modeling software, the development time is saved, and the working difficulty is reduced.
Drawings
In order to more clearly illustrate the invention or the technical solutions of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are some embodiments of the invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a general BIM secondary development implementation method provided by the invention;
FIG. 2 is a flow chart of a unified interface package provided by the present invention;
FIG. 3 is a schematic diagram of an interface function package for Revit and Microstation packaging functions provided by the present invention;
FIG. 4 is a schematic diagram of a general BIM secondary development implementation device provided by the invention;
fig. 5 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The following describes a general BIM secondary development implementation method provided by the embodiment of the invention with reference to fig. 1-2, which comprises the following steps:
step 100, packaging development environments of various modeling software of BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software; the environmental requirements corresponding to different modeling software are:
microstation: VS2015, microStation CE (Update 7), net frame 4.6.1, configuration csproj files;
OBD, open Building Designer, requires the development environment of: OBD software, VS2017, net framework4.6.1, configuration cs proj file, configuration openSln.bat file, configuration mke file, configuration Commandable.xml file, configuration cfg file;
ORD, open Rail Designer, requires the development environment of: ORD software, ORD SDK, VS2017, net frame 4.6.1, configuration csproj file, configuration openSln.bat file, configuration mke file, configuration Commandable.xml file, configuration cfg file;
revit: revit 2019, VS2017, revit SDK 2019, addinManager, revit Lookup, ILSpy 4.0.1; configuring AddinManager and Revit Lookup;
CATIA:catia、vs、caa、RADE。
Step 200, packaging interface functions of various modeling software of BIM to obtain packaged general interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software; the interface function requirements for the different modeling software are shown in table 1 below:
TABLE 1
Step 300, writing a plug-in by calling the universal interface function in the universal development environment so as to perform BIM secondary development;
step 400, determining the modeling software selected currently, and modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, thereby completing secondary development operation.
Specifically, the BIM (building information modeling) building information model is based on various relevant information data of a building engineering project, and is constructed by simulating real information of a building through digital information. Meanwhile, various BIM modeling software such as Revit, bentley, CATIA exists in the market, so that when the software is subjected to secondary development, different development interfaces are often required to be adapted to different software, for example, revit needs to introduce two interface component files, namely Revit API.dll and Revit APIUI.dll; for the secondary development of the micro of Bentley, one set of NET programs could be run as Addins under the micro station, requiring that three conditions be met. Each modeling software corresponds to a different development environment. In step 1, the development environment is packaged by various modeling software of the BIM. The development environment refers to a software development environment (Software Development Environment, SDE) which refers to a group of software used for supporting engineering development and maintenance of system software and application software on the basis of basic hardware and digital software, and is abbreviated as SDE. The system consists of a software tool and an environment integration mechanism, wherein the software tool is used for supporting related processes, activities and tasks of software development, and the environment integration mechanism is used for providing unified support for tool integration and development, maintenance and management of software.
In step 100, different development environments are integrated to form a general development environment, so that a developer does not need to distinguish the corresponding development environments according to different modeling software when developing the software:
microstation: script installation VS2015, microStation CE (Update 7), net frame 4.6.1; configuration csproj file: the script is written to add related reference files such as the operation. Dll and the like under the ItemGroup node.
OBD: script installation ORD software, VS2017, net framework4.6.1; configuration csproj file: the writing script adds "< OutputPath > $ (ORD) \mdlapps </OutputPath >" under the PropertyGroup node, and the writing script adds related reference files such as the operation. Dll and the like under the ItemGroup node; configuration of opensln.bat file: writing a script, copying an openSln.bat file in one other project, copying the openSln.bat file to the directory of the project sln, and modifying the project name in the script to be the current project name; configuration mke file: writing a script to copy a 'ManagedSDKExample.mke' file, and modifying the item name in the file to be the current item name; configuring a Commandable. Xml file: writing a script, creating a Commandable. Xml file in the Visual Studio item, and adding related contents such as general attributes of the xml file, key-in command tree labels and the like; configuration cfg file: writing a new cfg file, filling corresponding codes and storing the codes in an ORD directory.
ORD: script installation ORD software, ORD SDK, VS2017, net framework4.6.1; configuration csproj file: the writing script adds "< OutputPath > $ (ORD) \mdlapps </OutputPath >" under the PropertyGroup node, and the writing script adds related reference files such as the operation. Dll and the like under the ItemGroup node; configuration of opensln.bat file: writing a script, copying an openSln.bat file in one other project, copying the openSln.bat file to the directory of the project sln, and modifying the project name in the script to be the current project name; configuration mke file: writing a script to copy a 'ManagedSDKExample.mke' file, and modifying the item name in the file to be the current item name; configuring a Commandable. Xml file: writing a script, creating a Commandable. Xml file in the Visual Studio item, and adding related contents such as general attributes of the xml file, key-in command tree labels and the like; configuration cfg file: writing a new cfg file, filling corresponding codes and storing the codes in an ORD directory.
Revit: writing a script to install Revit 2019, VS2017, revit SDK 2019, addinManager, revit Lookup, ILSpy 4.0.1; configuration of AddinManager: writing a script to copy AddInManager.dll and Autodesk.AddInManager.addin files under an Add-In Manager directory under an SDK file into an Autodesk/Revit/Addins/2019 directory, changing a path In a tag In the Autodesk.AddInManager.addin file into an actual installation path of the SDK, and storing the paths; configuration of Revit Lookup: the writing script adds the revit reference file, and the writing script modifies the path of the fourth behavior RevitLookup.dll of the RevitLookup.add file.
CATIA: installing cata software; installing a corresponding secondary development vs version; installing a corresponding caa; and installing RADE and configuring environment.
That is, the developer can directly develop in the packaged development environment without considering whether the corresponding development environment is suitable for modeling software to be used, and the trouble of the developer in considering the bottom layer problem is reduced.
A function interface refers to a function that a module writes (primarily) to other modules. Simply stated, the interface function is a public function in the class. Wherein the encapsulation conceals the object's attributes and implementation details, only exposes the interface to the outside, controlling the access level of the read and modification of the attributes in the program. In addition, since different modeling software has different function interfaces, in step 200, these function interfaces are packaged to form a unified function interface, so that a developer does not need to consider a specific class of the function interface to be called when performing secondary development, and likewise, the developer does not need to consider the bottom layer. Examples of encapsulated function interfaces are shown in table 2 below:
TABLE 2
The general function interface can be obtained by packaging the following codes:
/>
A BIM general development platform (BIM GDP) is defined, and a function library used for development is determined according to a platform used by a user. The function library of the user is packaged by the classes BIM_Revit, BIM_Bentley and BIM_CATIA, and the user can develop the function by only calling the public interface function of BIMSoftware.
Step 300 is to write corresponding plug-ins based on step 100 and step 200, i.e. based on the general development environment obtained in step 100 and the general interface function obtained in step 200. The plug-in refers to a program written by an application program interface conforming to a certain specification. It can only run under a program-specified system platform (possibly supporting multiple platforms simultaneously) and cannot run separately from the specified platform. The secondary development is simply to perform custom modification on the existing software, expand functions, and then achieve the functions wanted by the user, and generally, the kernel of the original system is not changed. Therefore, in the step 300, by calling the universal interface function and writing the plugin in the universal development environment, the method has a universal effect, can be suitable for a plurality of packaged modeling software, can be suitable for different BIM modeling software by writing one plugin, saves development time and reduces working difficulty.
Since the plug-ins on different modeling software may require many repeated operations due to different platforms, in step 300, one plug-in may be adapted to a plurality of different modeling software by using a generic development environment and invoking a generic interface function, but the plug-ins may not be directly applied to the corresponding modeling software, and a technical developer may be required to modify the plug-ins according to the selected modeling software by using scripts and codes corresponding to the currently selected modeling software to adapt to the currently selected modeling software, thereby completing the secondary development operation. In step 400, a generic plug-in is adapted to specific modeling software, so that the plug-in performs a corresponding function.
According to the general BIM secondary development implementation method provided by the invention, the development environments of various modeling software of the BIM are packaged to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software; meanwhile, packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software; the generalization of the development environment and the interface function is realized through the two steps. And then, in the general development environment, writing a plugin by calling the general interface function so as to perform BIM secondary development. At this time, the written plug-in is suitable for a plurality of different modeling software, but cannot be directly applied to the corresponding modeling software. Then, a developer is required to modify the plug-in by adopting a script and a code corresponding to the currently selected modeling software according to the determined currently selected modeling software so as to adapt to the currently selected modeling software, and secondary development operation is completed. When developing BIM plug-ins for the second time, the developer only concentrates on the upper layer application, does not need to care about the environment and the bottom layer realization, namely, one plug-in can be applicable to different BIM modeling software, the development time is saved, and the working difficulty is reduced.
In still another embodiment of the present invention, in a general-purpose BIM secondary development implementation method, the packaging is performed on development environments of multiple modeling software of the BIM to obtain a packaged general-purpose development environment, including:
determining environment requirements respectively corresponding to a plurality of modeling software; that is, since different modeling software has different requirements on the development environment, secondary development for each modeling software needs to be adapted to the environment of the corresponding modeling software, and at the same time, the environment between the respective modeling software is not universal, and thus, the corresponding environment requirement of each modeling software needs to be determined.
And writing a script according to the environment requirements respectively corresponding to the modeling software to realize the encapsulation of the development environment of the modeling software of the BIM and obtain an encapsulated general development environment. As script is an extension of batch file, it is a program stored in pure text, and generally, a computer script program is a combination of a series of determined control computer operations, in which a certain logic branch can be implemented. Although different modeling software has different environmental requirements, the environments cannot coexist completely, so that the environments of multiple modeling software of the BIM can be packaged in a script writing manner, and a general development environment can be obtained through packaging, wherein the general development environment can avoid unique environments required by each modeling software, and the repeated writing work part can be reduced.
The invention provides an embodiment, in a general BIM secondary development implementation method, wherein, packaging interface functions of multiple modeling software of BIM to obtain packaged general interface functions, comprising:
determining interface function requirements respectively corresponding to a plurality of modeling software; since different modeling software corresponds to different interface functions and the interface functions corresponding to different modeling software are not common, it is necessary to determine the interface function corresponding to each modeling software.
And writing codes according to the interface function requirements respectively corresponding to the modeling software to package the interface functions of the modeling software of the BIM so as to obtain a packaged general interface function. Namely, as the interface functions of the modeling software are different, but not mutually exclusive, corresponding codes can be written, the interface functions corresponding to the different modeling software are packaged to obtain a universal interface function, and the special requirements of the modeling software on the interface functions can be avoided by establishing the universal interface function, so that the work of the written software on repeated parts of the different interface functions can be reduced.
In one embodiment provided by the invention, in a general development environment, writing a plugin by calling the general interface function to perform BIM secondary development, wherein the method comprises the following steps:
and writing a plug-in by calling the universal interface function in the universal development environment according to the secondary development function to be realized so as to carry out BIM secondary development. Therefore, in the general development environment, the general interface is called, and the written plug-in has universality, namely, the general development environment and the general interface can be widely adaptive, and the method is applicable to a plurality of encapsulated modeling software.
In one embodiment, determining the modeling software selected currently, modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently to adapt to the modeling software selected currently, and completing secondary development operation, including:
determining currently selected modeling software, and extracting an environment script corresponding to the currently selected modeling software from the general development environment;
extracting an interface function corresponding to the currently selected modeling software from the universal interface function;
and modifying the plug-in based on the environment script corresponding to the currently selected modeling software and the interface function corresponding to the currently selected modeling software so as to adapt to the currently selected modeling software, and completing secondary development operation.
Specifically, since the plug-in obtained according to the general development environment and the general interface function has wide applicability, but cannot be directly combined with any modeling software to be packaged, the obtained general plug-in needs to be adaptively modified in combination with the selected modeling software to adapt to the currently selected modeling software, thereby completing secondary development operation.
In one embodiment, the invention provides a general BIM secondary development implementation method, wherein the plurality of modeling software comprises Revit, microstation, OBD, ORD and CATIA.
The implementation method in the above embodiment is further described below with reference to fig. 3 by taking the review and the microstructure as examples:
embodiments of the Revit script deployment environment:
embodiments of a Microstation script deployment environment:
build app. Bat content:
/>
opening a modeless dialog box:
before compiling the program, firstly judging which platform plug-in is to be developed by the technician, and then running the environment script of the platform.
/>
Referring to fig. 4, a general BIM secondary development implementation apparatus provided by the present invention is described below, and a general BIM secondary development implementation apparatus described below and a general BIM secondary development implementation method described above may be referred to correspondingly.
In yet another embodiment of the present invention, a generic BIM secondary development implementation apparatus includes:
the development environment packaging module is used for packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software; the interface function packaging module is used for packaging the interface functions of the BIM modeling software to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software; the first development module is used for compiling a plug-in by calling the universal interface function in the universal development environment so as to carry out BIM secondary development; and the second development module is used for determining the modeling software selected currently, modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, and completing secondary development operation.
Specifically, the BIM (building information modeling) building information model is based on various relevant information data of a building engineering project, and is constructed by simulating real information of a building through digital information. Meanwhile, various BIM modeling software such as Revit, bentley, CATIA exists in the market, so that when the software is subjected to secondary development, different development interfaces are often required to be adapted to different software, for example, revit needs to introduce two interface component files, namely Revit API.dll and Revit APIUI.dll; for the secondary development of the micro of Bentley, one set of NET programs could be run as Addins under the micro station, requiring that three conditions be met. Each modeling software corresponds to a different development environment. In step 1, the development environment is packaged by various modeling software of the BIM. The development environment refers to a software development environment (Software Development Environment, SDE) which refers to a group of software used for supporting engineering development and maintenance of system software and application software on the basis of basic hardware and digital software, and is abbreviated as SDE. The system consists of a software tool and an environment integration mechanism, wherein the software tool is used for supporting related processes, activities and tasks of software development, and the environment integration mechanism is used for providing unified support for tool integration and development, maintenance and management of software.
In the development environment packaging module, different development environments are integrated to form a general development environment, so that a developer does not need to distinguish the corresponding development environments according to different modeling software when developing software. That is, the developer can directly develop in the packaged development environment without considering whether the corresponding development environment is suitable for modeling software to be used, and the trouble of the developer in considering the bottom layer problem is reduced.
A function interface refers to a function that a module writes (primarily) to other modules. Simply stated, the interface function is a public function in the class. Wherein the encapsulation conceals the object's attributes and implementation details, only exposes the interface to the outside, controlling the access level of the read and modification of the attributes in the program. In addition, because different modeling software has different function interfaces, in the interface function packaging module, the function interfaces are packaged to form a unified function interface, so that a developer does not need to consider the specific category of the function interface to be called when developing, and the developer does not need to consider the bottom layer.
The first development module is based on the development environment packaging module and the interface function packaging module, namely based on the general development environment obtained by the development environment packaging module and the general interface function obtained by the interface function packaging module, and carries out corresponding plug-in writing. The plug-in refers to a program written by an application program interface conforming to a certain specification. It can only run under a program-specified system platform (possibly supporting multiple platforms simultaneously) and cannot run separately from the specified platform. The secondary development is simply to perform custom modification on the existing software, expand functions, and then achieve the functions wanted by the user, and generally, the kernel of the original system is not changed. Therefore, in the general development environment in the first development module, the plug-in written by calling the general interface function has a general effect, and can be applied to a plurality of packaged modeling software, so that writing one plug-in can be applied to different BIM modeling software, development time is saved, and working difficulty is reduced.
Because the plug-ins on different modeling software can need many repeated works because of different platforms, in the first development module, one plug-in can be suitable for a plurality of different modeling software through a general development environment and a general interface function, but the plug-ins cannot be directly applied to corresponding modeling software, and a technical developer is required to modify the plug-ins according to the selected modeling software by adopting scripts and codes corresponding to the currently selected modeling software so as to adapt to the currently selected modeling software, so that secondary development operation is completed. In the second development module, a general plug-in is adapted to specific modeling software, so that the plug-in plays a corresponding function.
In yet another embodiment, the present invention provides a generic BIM secondary development implementation apparatus, where the development environment packaging module is further configured to:
determining environment requirements respectively corresponding to a plurality of modeling software; and writing a script according to the environment requirements respectively corresponding to the modeling software to realize the encapsulation of the development environment of the modeling software of the BIM and obtain an encapsulated general development environment.
Specifically: determining environment requirements respectively corresponding to a plurality of modeling software; that is, since different modeling software has different requirements on the development environment, secondary development for each modeling software needs to be adapted to the environment of the corresponding modeling software, and at the same time, the environment between the respective modeling software is not universal, and thus, the corresponding environment requirement of each modeling software needs to be determined.
And writing a script according to the environment requirements respectively corresponding to the modeling software to realize the encapsulation of the development environment of the modeling software of the BIM and obtain an encapsulated general development environment. As script is an extension of batch file, it is a program stored in pure text, and generally, a computer script program is a combination of a series of determined control computer operations, in which a certain logic branch can be implemented. Although different modeling software has different environmental requirements, the environments cannot coexist completely, so that the environments of multiple modeling software of the BIM can be packaged in a script writing manner, and a general development environment can be obtained through packaging, wherein the general development environment can avoid unique environments required by each modeling software, and the repeated writing work part can be reduced.
Fig. 5 illustrates a physical schematic diagram of an electronic device, as shown in fig. 5, which may include: processor 510, communication interface (Communications Interface) 520, memory 530, and communication bus 540, wherein processor 510, communication interface 520, memory 530 complete communication with each other through communication bus 540. Processor 510 may invoke logic instructions in memory 530 to perform a generic BIM secondary development implementation method comprising: packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software; packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software; in the general development environment, writing a plugin by calling the general interface function so as to perform BIM secondary development; determining the modeling software selected currently, and modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, thereby completing secondary development operation.
Further, the logic instructions in the memory 530 described above may be implemented in the form of software functional units and may be stored in a computer-readable storage medium when sold or used as a stand-alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In another aspect, the present invention also provides a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, are capable of executing the methods provided above to perform a generic BIM secondary development implementation method, the method comprising: packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software; packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software; in the general development environment, writing a plugin by calling the general interface function so as to perform BIM secondary development; determining the modeling software selected currently, and modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, thereby completing secondary development operation. In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, is implemented to perform the above-provided methods for performing a generic BIM secondary development implementation, the method comprising: packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software; packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software; in the general development environment, writing a plugin by calling the general interface function so as to perform BIM secondary development; determining the modeling software selected currently, and modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, thereby completing secondary development operation.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on this understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the prior art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the respective embodiments or some parts of the embodiments.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (9)

1. The utility model provides a general BIM secondary development implementation method which is characterized in that the method comprises the following steps:
packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software;
packaging interface functions of various modeling software of the BIM to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software;
in the general development environment, writing a plugin by calling the general interface function so as to perform BIM secondary development;
Determining the currently selected modeling software, and modifying the plug-in by adopting a script and a code corresponding to the currently selected modeling software to adapt to the currently selected modeling software so as to complete secondary development operation;
determining the modeling software selected currently, modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, and completing secondary development operation, wherein the method comprises the following steps:
determining currently selected modeling software, and extracting an environment script corresponding to the currently selected modeling software from the general development environment;
extracting an interface function corresponding to the currently selected modeling software from the universal interface function;
and modifying the plug-in based on the environment script corresponding to the currently selected modeling software and the interface function corresponding to the currently selected modeling software so as to adapt to the currently selected modeling software, and completing secondary development operation.
2. The method for implementing the secondary development of the universal BIM according to claim 1, wherein the step of encapsulating the development environments of the plurality of modeling software of the BIM to obtain an encapsulated universal development environment includes:
Determining environment requirements respectively corresponding to a plurality of modeling software;
and writing a script according to the environment requirements respectively corresponding to the modeling software to realize the encapsulation of the development environment of the modeling software of the BIM and obtain an encapsulated general development environment.
3. The method for implementing the secondary development of the universal BIM according to claim 1, wherein the step of encapsulating the interface functions of the plurality of modeling software of the BIM to obtain the encapsulated universal interface functions includes:
determining interface function requirements respectively corresponding to a plurality of modeling software;
and writing codes according to the interface function requirements respectively corresponding to the modeling software to package the interface functions of the modeling software of the BIM so as to obtain a packaged general interface function.
4. The universal BIM secondary development implementation method according to claim 1, wherein in the universal development environment, by calling the universal interface function, writing a plug-in to perform BIM secondary development includes:
and writing a plug-in by calling the universal interface function in the universal development environment according to the secondary development function to be realized so as to carry out BIM secondary development.
5. The universal BIM secondary development implementation method of any of claims 1 to 4, wherein the plurality of modeling software includes Revit, microstation, OBD, ORD and CATIA.
6. A universal BIM secondary development implementation apparatus, comprising:
the development environment packaging module is used for packaging development environments of various modeling software of the BIM to obtain a packaged general development environment; the general development environment comprises environment requirements respectively corresponding to the modeling software;
the interface function packaging module is used for packaging the interface functions of the BIM modeling software to obtain packaged universal interface functions; the universal interface function comprises interface function requirements respectively corresponding to the modeling software;
the first development module is used for compiling a plug-in by calling the universal interface function in the universal development environment so as to carry out BIM secondary development;
the second development module is used for determining the modeling software selected currently, modifying the plug-in by adopting a script and a code corresponding to the modeling software selected currently so as to adapt to the modeling software selected currently, and completing secondary development operation;
The second development module is specifically used for:
determining currently selected modeling software, and extracting an environment script corresponding to the currently selected modeling software from the general development environment;
extracting an interface function corresponding to the currently selected modeling software from the universal interface function;
and modifying the plug-in based on the environment script corresponding to the currently selected modeling software and the interface function corresponding to the currently selected modeling software so as to adapt to the currently selected modeling software, and completing secondary development operation.
7. The universal BIM secondary development implementation device of claim 6, wherein the development environment packaging module is further configured to:
determining environment requirements respectively corresponding to a plurality of modeling software;
and writing a script according to the environment requirements respectively corresponding to the modeling software to realize the encapsulation of the development environment of the modeling software of the BIM and obtain an encapsulated general development environment.
8. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any one of claims 1 to 5 when the program is executed.
9. A non-transitory computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method according to any one of claims 1 to 5.
CN202110362087.7A 2021-04-02 2021-04-02 Universal BIM secondary development implementation method and device Active CN113177292B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110362087.7A CN113177292B (en) 2021-04-02 2021-04-02 Universal BIM secondary development implementation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110362087.7A CN113177292B (en) 2021-04-02 2021-04-02 Universal BIM secondary development implementation method and device

Publications (2)

Publication Number Publication Date
CN113177292A CN113177292A (en) 2021-07-27
CN113177292B true CN113177292B (en) 2024-02-02

Family

ID=76923057

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110362087.7A Active CN113177292B (en) 2021-04-02 2021-04-02 Universal BIM secondary development implementation method and device

Country Status (1)

Country Link
CN (1) CN113177292B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115328544B (en) * 2022-10-14 2023-02-28 统信软件技术有限公司 Environment customization method, computing device and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101876917A (en) * 2010-07-02 2010-11-03 深圳市迅雷网络技术有限公司 Control development method and device
CN102622241A (en) * 2011-01-26 2012-08-01 腾讯科技(深圳)有限公司 Software upgrading method and software upgrading device
CN104504171A (en) * 2014-11-20 2015-04-08 北京索为高科***技术有限公司 Modeling method based on unified modeling environment
KR20150134681A (en) * 2014-05-22 2015-12-02 박경란 How to construct the cross-platform-based open BIM system to support a large number of heterogeneous computing platforms and data interoperability between other fields
CN111428289A (en) * 2020-02-26 2020-07-17 中国电力工程顾问集团西南电力设计院有限公司 Design method for ladder stand of hyperbolic cooling tower

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101876917A (en) * 2010-07-02 2010-11-03 深圳市迅雷网络技术有限公司 Control development method and device
CN102622241A (en) * 2011-01-26 2012-08-01 腾讯科技(深圳)有限公司 Software upgrading method and software upgrading device
KR20150134681A (en) * 2014-05-22 2015-12-02 박경란 How to construct the cross-platform-based open BIM system to support a large number of heterogeneous computing platforms and data interoperability between other fields
CN104504171A (en) * 2014-11-20 2015-04-08 北京索为高科***技术有限公司 Modeling method based on unified modeling environment
CN111428289A (en) * 2020-02-26 2020-07-17 中国电力工程顾问集团西南电力设计院有限公司 Design method for ladder stand of hyperbolic cooling tower

Also Published As

Publication number Publication date
CN113177292A (en) 2021-07-27

Similar Documents

Publication Publication Date Title
CN108765158B (en) Intelligent contract engine system based on block chain and contract execution method thereof
US8448132B2 (en) Systems and methods for modifying code generation templates
US9037595B2 (en) Creating graphical models representing control flow of a program manipulating data resources
CN109299587A (en) Algorithm protection method, device, equipment and storage medium based on go language
US8418134B2 (en) Method for efficiently managing property types and constraints in a prototype based dynamic programming language
CN109542506B (en) System capable of flexibly configuring interface and rapidly delivering service
US20040015822A1 (en) Method and apparatus for dynamic assembly and verification of software components into flexible applications
Blouin et al. Combining aspect-oriented modeling with property-based reasoning to improve user interface adaptation
US10747510B1 (en) Application runtime modification
CN113064593B (en) Method and device for dynamic mobile APP, computer equipment and storage medium
WO2019242586A1 (en) Training model implementation method and device, and storage medium
JP2004503866A (en) Modular computer system and related methods
CN113312046A (en) Sub-application page processing method and device and computer equipment
CN111966357A (en) Operating system application compiling method and device and electronic equipment
US20190087160A1 (en) System and method for creating domain specific language
CN113177292B (en) Universal BIM secondary development implementation method and device
CN109558121A (en) Development approach, device, equipment and the storage medium of interface drive program
CN111367512B (en) Method and device for creating Android library module dependency relationship in application development
CN110018831B (en) Program processing method, program processing apparatus, and computer-readable storage medium
CN115629795A (en) Configuration method and device of executable file and electronic equipment
CN106775608A (en) The implementation method and device of autonomous system process
CN114064218A (en) Mirror image generation method, system, medium and application for machine learning component
CN114911541A (en) Configuration information processing method and device, electronic equipment and storage medium
CN117234466B (en) Enterprise management software development method, system, equipment and storage medium
CN111459570B (en) PDF plug-in loading method, electronic equipment and computer storage medium

Legal Events

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