Infer Command (Macro)
Smart Client Extension for AutoCAD
Infer Command (Macro)
Command: AFM_INFER
This command is accessed primarily from the Navigator in CAD, but it can also be run from the command line, or by selecting Infer from the Macro group on the Ribbon toolbar.
Note:
When the Extension for AutoCAD loads, the Ribbon shows the Archibus tab by default. To see the Graphic and Tools commands, select the Utilities tab on the Ribbon.
Purpose: The Infer command applies data from a selected area asset symbol to all visible asset symbols located within its boundary. Use this command to update assets when the information of surrounding area asset symbols has changed. The command can operate on a selection of multiple area asset symbols of different asset types.
It is used primarily from command macros from process task records, but you can also run it from the command line
The Infer macro command is useful for existing block plans for which you want to add room information for existing items, such as equipment or jacks.
For example, use the Infer command to:
- Infer Room Location to Equipment
- Infer Department Assignment to Equipment (useful if the equipment is not assigned to an employee)
- Infer Room Location to Furniture
- Infer Department Assignment to Furniture
- Infer Room Location to Jacks
The default schema calls for inferring space and organizational information, but you can change the default schema to infer any data.
Setting the Layers
Before issuing this command, you need to do the following:
- Make the layer holding the contained asset symbols (to which you want to infer data) visible.
- Make the area asset symbol layer selectable. Any layer can be the drawing's current layer. (AutoCAD does not distinguish between visible and selectable layers. Therefore, if you are using the Infer command, simply make the area asset symbol layer visible.)
- Hide asset symbol layers housing items you do not want to update.
Example
Suppose you have added jacks to rooms belonging to various departments, and your schema calls for inferring space and organizational data. To update the space and organizational data of the jack assets, follow these steps:
- Use AutoCAD's Layers command to make the Room and Equipment asset layers visible. Hide layers holding items you do not want to update. For example, if you don't want to update furniture items located within the rooms, hide the furniture asset layers.
-
Run the Infer command from the command line. The infer command prompts for a "from" object (for example, rooms) a "to" object (for example, jacks), and a list of fields to consider (for example, bl_id, fl_id, rm_id):
Command: AFM_INFER
Containing asset layer: rm
Contained asset layer: jk
Fields to infer:bl_id,fl_id,rm_id,dv_id,dp_id
Select Rooms to which to infer properties to contained jack: <user selects items>
- Select all the room asset symbols that have had jacks added. The command updates the space and organizational data of the equipment asset symbols located within these rooms.
Process Task Record Example
The following is an example of the Infer command used as a command macro from a process task record.
Infer Room Location to Equipment afm_infer;rm;jk;bl_id,fl_id,rm_id,dv_id,dp_id;
Setting the Layers
Before issuing this command, you need to do the following:
- Make the layer holding the contained asset symbols (to which you want to infer data) visible.
- Make the area asset symbol layer selectable. Any layer can be the drawing's current layer. (AutoCAD does not distinguish between visible and selectable layers. Therefore, if you are using the Infer command, simply make the area asset symbol layer visible.)
- Hide asset symbol layers housing items you do not want to update.
Example
Suppose you have moved equipment assets between rooms belonging to various departments, and your schema calls for inferring space and organizational data. To update the space and organizational data of the equipment assets, follow these steps:
- Use AutoCAD's Layers command to make the Room and Equipment asset layers visible. Hide layers holding items you do not want to update. For example, if you don't want to update furniture items located within the rooms, hide the furniture asset layers.
- Issue the Infer command, located on the Archibus menu.
- Select all the room asset symbols whose equipment content has changed. The command updates the space and organizational data of the equipment asset symbols located within these rooms.
Determining if an Asset Symbol is Located within an Area Asset Symbol
To determine whether an asset symbol is located within an area asset symbol, the command follows these rules:
- For asset symbols composed of polylines , the command checks that each of the polyline's vertices falls within the boundary of the surrounding area asset symbol.
- For asset symbols composed of blocks , the command checks that the block's extent (the smallest possible box that completely encloses the block) falls within the area boundary.
- By design, Infer does not infer blank or null values.
For instance, if you have a room without a division or department code, and you infer to employees in that room, the Infer command will not clear the employees' existing division and department assignments. The employee's division and department assignment is usually carefully made, and should not get cleared if the employee is moved to a room that does not have a division and department assignment.
Note : To control the fields that the Infer command updates, set the Inferable Fields field of the A/FM Schema Preferences table.