The type of records this symbol table manages
Creates a new AcDbSymbolTable instance.
The database this symbol table belongs to
Protected
_recordsMap of records indexed by object ID
Protected
_recordsMap of records indexed by name
Gets the attributes object for this AcDbObject.
The AcCmObject instance containing all attributes
Gets the database in which this object is resident.
When an object isn't added to a database, this property returns the current working database. After it is added to a database, it will be set automatically. You should never set this value manually.
The database this object belongs to
Sets the database for this object.
This is typically set automatically when the object is added to a database. Manual setting should be avoided unless you know what you're doing.
The database to associate with this object
Gets the object ID.
AutoCAD uses 64-bit integers to represent handles, which exceed the maximum integer value of JavaScript. Therefore, strings are used to represent object handles.
The object ID as a string
Sets the object ID.
The new object ID
Gets the object ID of the owner of this object.
The owner object ID
Sets the object ID of the owner of this object.
The new owner object ID
Adds a record to both the database containing the table and the table itself.
The record to add to the table
Searches the table for a record with the specified name.
The name to search for
The record with the specified name, or undefined if not found
Gets the value of the specified attribute.
This method will throw an exception if the specified attribute doesn't exist. Use getAttrWithoutException() if you want to handle missing attributes gracefully.
The name of the attribute to retrieve
The value of the specified attribute
Gets the value of the specified attribute without throwing an exception.
This method returns undefined if the specified attribute doesn't exist, making it safer for optional attributes.
The name of the attribute to retrieve
The value of the specified attribute, or undefined if it doesn't exist
Searches the table for a record with the specified ID.
The ID to search for
The record with the specified ID, or undefined if not found
Gets the owner ID of a record with the specified ID.
The ID to search for
The record with the specified ID, or undefined if not found
Creates an iterator object that can be used to iterate over the records in the table.
An iterator object that can be used to iterate over the records
Sets the value of an attribute.
The name of the attribute to set
Optional
val: AcDbObjectAttrs[A]The value to assign to the attribute
Base class for all symbol tables in AutoCAD.
AcDbSymbolTable is the base class for all classes used to manage AutoCAD's built-in symbol tables. Symbol tables organize and store various types of records such as layers, linetypes, text styles, dimension styles, etc.
Example