Understanding Object Element List Formats
 
 
 

The contents of an Inspect element list vary, depending on the data type of the object being inspected. The following table identifies the list contents for each data type.

Inspect element lists

Data type

Contents of element list

INT (integer)

The various representations of integers.

REAL (floating point number)

Empty.

STRING

The sequence of characters in the string, which may in turn be inspected as integers.

SYMBOL

Three elements: value, print name, and flags.

LIST (for proper lists)

Items of the inspected list.

LIST (for improper lists)

Two elements: the car and cdr fields. It serves for all cases that are not proper LISP lists, that is, where the last cdr is not nil.

FILE

The name of the corresponding file and the file's opening attributes.

SUBR, EXRXSUBR, and USUBR

The name of the function (the name that was specified in defun or at load time). SUBR refers to internal and compiled functions, EXRXSUBR refers to external ARX functions, and USUBR identifies user-defined functions.

ENAME (drawing entity)

The fields in this element list correspond to the AutoCAD DXF object list, as returned by the AutoLISP built-in function.

PICKSET (selection set)

List of selected AutoCAD objects.

VARIANT

The data type and value of the variant.

SAFEARRAY

The data type, number of dimensions, and value of the safearray.

Sample Inspect windows for each data type follow.

INT

The INT (integer) Inspect window shows the number represented in binary, octal, decimal, hexadecimal, and character formats. Character format means the ASCII character that corresponds to the number (for large numbers it takes the last byte).

The INT Inspect window does not have an element list.

REAL

The REAL Inspect window does not have an element list.

STRING

Shows the string as a list of characters represented as numbers:

Double-click on a listed character to see its number representation.

SYMBOL

Contains the symbol name, the symbol value, and the flags that represent symbol attributes. Flags may be one of the following:

Pa Protect Assign

Tr Trace

De Debug on entry

Ea Export to ACAD

To change a symbol's value or flag settings, use the object line menu command Symbol Service, which shows the Symbol Service window.

Note that the information supplied by the SYMBOL Inspect window is available more conveniently through the Symbol Service feature.

LIST (properlist)

Shows the elements of a proper list:

LIST (improperlist)

Shows the car and cdr of an improper list. For example, a list constructed by (cons 4 '(5 . 0)) is represented as follows:

FILE

File Inspect fields include the following:

File name is the name string used in the open function.

Mode indicates whether the file is open for input, output, append, or whether the file is closed.

ID shows the internal file identifier.

Position shows the current position in the file.

EOF indicates whether or not the end of the file has been reached. This field does not appear if a file is open for output.

SUBR

The SUBR data type represents functions that cannot be debugged with the VLISP debugging tools (for example, you cannot set breakpoints). These are internal AutoLISP functions, or functions loaded from FAS or VLX files.

The SUBR Inspect window shows a string containing the name of the symbol, as in the following example:

USUBR

The USUBR data type represents functions that can be debugged with the VLISP debugging tools (for example, you can set breakpoints and view the values of program variables). These functions are loaded from LISP source code.

The USUBR Inspect window shows the name of the symbol, a list of function parameters (arguments), and a list of local variables declared in the function (listed after the “/” in the defun argument list). The following example shows an Inspect window for a function that accepts no arguments and declares several local variables:

EXRXSUBR

The EXRXSUBR data type represents functions loaded from external ARX applications. The EXRXSUBR Inspect window shows a string containing the function name, as in the following example:

ENAME

The contents of the ENAME Inspect window depend on the properties of the entity being inspected. The following example shows an Inspect window for a circle:

PICKSET

The PICKSET Inspect window lists the elements in a selection set:

VARIANT

The VARIANT Inspect window shows the data type and value of the variant. The following example shows an Inspect window for a variant that contains an array of doubles:

SAFEARRAY

The SAFEARRAY Inspect window shows the data type, number of dimensions, and value of the safearray. The following example shows a Safearray Inspect window for a single dimension array of doubles:

You can also use the Inspect feature to examine ActiveX. objects. See Using the Inspect Tool to View Object Properties for an example of this.