LIST-CLASSES
Prev | Object Oriented Data Definition Language (OODDL) | Next

## Name

LIST-CLASSES — List classes for tables in SQL database.Function

## Syntax

          list-classes &key test root-class database => classes

## Arguments and Values

`test`

  a function used to filter the search. By default, `identity` is used which will return all classes.

`root-class`

  specifies the root class to the search. By default, `standard-db-object` is used which is the root for all view classes.

`database`

  The database to search for view classes. This will default to the value of *default-database*.

`classes`

  List of view classes.

## Description

Returns a list of all the View Classes which have been defined in the Lisp session and are connected to `database` and which descended from the class `root-class` and which satisfy the function `test`.

## Examples

    (list-classes)
    => (#<clsql-sys::standard-db-class big> #<clsql-sys::standard-db-class employee-address>
        #<clsql-sys::standard-db-class address> #<clsql-sys::standard-db-class company>
        #<clsql-sys::standard-db-class employee>)

    (list-classes :test #'(lambda (c) (> (length (symbol-name (class-name c))) 3)))
    => (#<clsql-sys::standard-db-class employee-address> #<clsql-sys::standard-db-class address>
        #<clsql-sys::standard-db-class company> #<clsql-sys::standard-db-class employee>)

## Side Effects

None.

## Affected by

Which view classes have been defined in the Lisp session.

## Exceptional Situations

None.

## See Also

`def-view-class`

## Notes

None.

Prev | Up | Next
DROP-VIEW-FROM-CLASS | Home | Object Oriented Data Manipulation Language (OODML)