当前位置:网站首页>CAD secondary development object
CAD secondary development object
2022-07-02 06:59:00 【Xu Jirong】
From https://blog.csdn.net/adliy_happy/article/details/77715210?spm=1001.2014.3001.5501

Application object It is opened every time AutoCAD Application instance . The main function is to maintain Document( file ) And Database( database ) Consistency between . The application program displays the information in the database on the document for users to view , When the user operates the document to update the document, save the updated data back to the database . adopt Application Object you can get the object related to the operation of the current application . You can also set it through its properties and methods AutoCAD Program parameters and system variables .
Document( file ) object It's actually **Database( database )** In the view displayed to the user , One document and one Database( database ) It's one-to-one . It follows Application( Applications ) The regulation of Database( database ) The objects in are displayed to the user , At the same time, the user is right Document( file ) The operation of will also pass Application( Applications ) Write back to the database , When modifying the database in the background, in order to prevent the foreground document from being modified at the same time, the document must be locked first , Unlock the document after the operation .
Editor Namely AutoCAD Command line in the interface , It is a tool for users to interact with Applications . AutoCAD The basic input and output functions of interaction with users are Editor Object .
Transaction ( Business ) Is an object used to control database operations . When opening and processing database objects Transaction Provides an automatic shutdown mechanism , To avoid forgetting to close the object after it is opened, which will cause errors in the next operation of the object .

Database yes DWG The representation of a file in memory , Is a container for storing database objects . Database It mainly stores a large number of container objects : **SymbolTables( The symbol table )** And NameDictionaries( Named object dictionary ), All graphical objects and most non graphical objects are stored in the container .
From https://wenku.baidu.com/view/af9a571948d7c1c709a1457b.html
DBObject( Database objects )
DBObject Is the base class of all database objects. It is an abstract class , All database objects are derived from it , His attribute method is applicable to all subclasses .
Objects in a program may have two states 1、 In memory ( Instantiated but not added to the database ): You can modify the properties of the object at will .2、 In the database : You need to open it to modify properties .
SymbolTable( The symbol table ) yes AutoCAD Base class of table object , Symbol tables are container objects , For storage SymbolTableRecord( Symbol table records ).
SymbolTableRecord( Symbol table records ) Are the elements that make up the symbol table . Only specific symbol table records can be stored in a specific symbol table , Such as : In the block table , Only block table records can be stored .
DBDictionary ( The dictionary ) Is a general container object , Used to store non graphical objects . Unlike the symbol table , Only objects recorded in the fixed symbol table can be accessed in the symbol table , A dictionary can store many kinds of documents at the same time DBObject Class derived objects (Entity) With the exception of ( Dictionaries can also be stored in dictionaries ). Objects commonly used to store in dictionaries are DataTable( Data sheet )Xrecord( Extended records ).
Dictionaries exist mainly in two ways. One is the data stored in the database to save the whole drawing, which is called NameDictionaries( Named object dictionary ), One is the information data stored in the object to save the object, which is called ExtensionDictionary( Object extension dictionary ).
1、 NameDictionaries( Named object dictionary )
Every DWG Every database has a named object dictionary , Named object dictionaries are often used to store global extended data .
2、 ExtensionDictionary( Object extension dictionary )
All database objects can contain an extended dictionary , Used to store user-defined data , Unlike the named object dictionary , These data are stored at the object level, that is, the subsidiary information of the object .
DataTable( Data sheet ) yes AutoCAD A table used to organize data in , Is a database object used to store data , The drawing global information data can be stored in the named object dictionary , It can also be placed in the object extension dictionary to store the attribute data of the object , He compared XRecord The advantage is that : Organizing data in tabular form is more organized .
Xrecord( Extended records ) Maximum storage 2GB The data of .
Field( Field ) Is a container for storing expressions , Can store characters 、 Expressions that point to system variables 、 Formulas, expressions, etc . These expressions are used to display data that may be modified during the life cycle of the drawing . When fields are updated , The latest data will be displayed . Fields can be inserted into any kind of text ( Except for tolerances ) in , This includes table cells 、 Attribute and text in attribute definition . When operating in the Block Editor , You can use block placeholder fields in block attribute definitions .
Entity( Entity object ) Is the base class for all visible objects , Visible objects inherit their properties and methods .
边栏推荐
- Nodejs - Express middleware modification header: typeerror [err_invalid_char]: invalid character in header content
- SQLI-LABS通关(less1)
- Sqli-labs customs clearance (less18-less20)
- Common function writing method and set get writing method for calculating attributes
- Review of reflection topics
- sqli-labs通關匯總-page2
- flex九宫格布局
- Browser scrolling for more implementations
- sqli-labs通关汇总-page4
- SQLI-LABS通关(less18-less20)
猜你喜欢

搭建frp进行内网穿透

Win10: add or delete boot items, and add user-defined boot files to boot items

Brief analysis of PHP session principle

There is no way to drag the win10 desktop icon (you can select it, open it, delete it, create it, etc., but you can't drag it)

A preliminary study on ant group G6

Basic knowledge of software testing

CTF web practice competition

解决微信小程序swiper组件bindchange事件抖动问题

No process runs when querying GPU, but the video memory is occupied

Présence d'une panne de courant anormale; Problème de gestion de la fsck d'exécution résolu
随机推荐
ts和js区别
php中通过集合collect的方法来实现把某个值插入到数组中指定的位置
Vscode installation, latex environment, parameter configuration, common problem solving
Go package name
IDEA2020中PySpark的两表关联(字段名相同)
sqli-labs通关汇总-page1
There is no way to drag the win10 desktop icon (you can select it, open it, delete it, create it, etc., but you can't drag it)
蚂蚁集团g6初探
Deployment API_ automation_ Problems encountered during test
js删除字符串的最后一位
浏览器滚动加载更多实现
CTF web practice competition
默认google浏览器打不开链接(点击超链接没有反应)
Huawei mindspire open source internship machine test questions
sqli-labs通關匯總-page2
php中的二维数组去重
sqli-labs通关汇总-page3
如何调试微信内置浏览器应用(企业号、公众号、订阅号)
Sqli labs customs clearance summary-page3
Sqli-labs customs clearance (less6-less14)