The CAD Standards API architecture consists of three components: the host application, the CAD Standards framework, and CAD Standards plug-ins.
The AutoCAD program includes an ObjectARX® extension (AcStd.arx) and a stand-alone Batch Standards Checker application, both of which perform the duties of a host application.
Host Application Responsibilities
Host applications have the following general responsibilities:
- Provide a user interface for checking drawings
- Perform file management tasks, including opening DWG or DWS files
- Execute the drawing checking process using the CAD Standards framework components; define the DWG file to check, configure the appropriate plug-ins, and select the DWS files to check against
- Present results as either error notifications or a report
The CAD Standards framework (or standards engine) is partially exposed through COM APIs, but developers should not attempt to extend its functionality. The standards manager is the primary object that applications use for interacting with the CAD Standards feature and plug-ins. It provides the main entry point for configuring the CAD Standards feature, passing objects to plug-ins, and collecting and displaying error and fix information.
CAD Standards Framework Responsibilities
The CAD Standards framework has the following general responsibilities:
- Provide utility methods for persisting standards information in drawing files (for example, references to DWS files, per-object information such as ignore flags, and so on)
- Manage the lifetime of the plug-in
- Provide methods for enumerating and fixing errors
- Gather error and fix data for reports
CAD Standards plug-ins support specific audit operations, such as layer, linetype, and so on.
CAD Standards Plug-ins Responsibilities
CAD Standards plug-ins have the following responsibilities:
- Provide information about the plug-in's purpose, author, version, and so on
- Provide information about the data types being monitored
- Cache and manage the standards (DWS) file it is using for comparison
- Compare data for compliance
- Create an error object when a data type is not in compliance
- Provide fix objects
- Apply property fixes