Transactions are used to group multiple operations on multiple objects together as a single operation. Transactions are started and managed through the Transaction Manager. Once a transaction is started, you can then use the GetObject function to open an object.
事务是用于将多个对象的多个操作一起当作一个简单的操作。事务是通过事务管理器启动和管理的。只要事务启动了,就可以使用 GetObject 函数打开对象。
As you work with objects opened with GetObject, the Transaction manager keeps track of the changes that are being made to the object. Any new objects that you create and add to the database should be added to a transaction as well with the AddNewlyCreatedDBObject function. Once the objects have been edited or added to the database, you can save the changes made to the database and close all the open objects with the Commit function on the Transaction object created with the Transaction Manager. Once you are finished with a transaction, call the Dispose function close the transaction.
当用 GetObject 打开使用的对象时,事务管理器会追踪对对象所做的修改。任何创建和添加到数据库的新对象,最好使用 AddNewlyCreatedDBObject 函数将其添加到事务中。一旦对象完成编辑或添加到数据库,应该保存对数据库所做的修改并关闭所有打开的对象,可以使用事务管理器创建的事务对象的 Commit 函数完成此操作。只要完成一个事务,就要用 Dispose 函数关闭事务。