Share

AcDbXrecord

Class Hierarchy

AcRxObject
    AcGiDrawable
        AcDbObject
            AcDbXrecord

C++

class AcDbXrecord : public AcDbObject;

File

dbxrecrd.h

Description

The AcDbXrecord class is a data storage class that was implemented primarily to allow ADSRX and AutoLISP programs a means to store data in pieces larger than the xdata's 16KB-per-object limit. Each AcDbXrecord object is capable of storing up to 2GB. By establishing an object's extension dictionary as the xrecord's owner, it's possible to associate large amounts of data with that object.

The input or output mechanism for the data is via a linked list of resbuf structures very similar to the way xdata is accessed on objects. Unlike xdata, however, xrecords work with the standard AutoCAD group codes, which are all below 1000 in value. All the standard AutoCAD group codes are supported. This means that, in addition to all the normally used data types, an xrecord is capable of storing object IDs in any of the four types (hard owner, soft owner, hard pointer, soft pointer) which allows xrecords to own other objects, including other xrecords.

Remarks

AcDbXrecord is a built-in class, so xrecord obects are never proxies. On the other hand, xrecord data is directly accessible by other ADSRX and AutoLISP programs.

If data security is not an issue but always-available data (that is, never a proxy) is an issue, then xrecords are a good solution. If data security is an issue, then a custom data storage class is a better alternative.

Links

AcDbXrecord Methods

See Also

AcDbXrecordIterator

Was this information helpful?