is_class_member (instance|class, class)
This function checks if a given instance or class is a member (an instance or derived class) of another class.
This example is based on the classes developed in class. |
Gamma> sqB = new(Square); {Square (length) (sides . 4)} Gamma> is_class_member(sqB, Square); t Gamma> is_class_member(Square, RegPolygon); t Gamma> is_class_member(sqB, RegPolygon); t Gamma> polyF = new(RegPolygon); {RegPolygon (length) (sides)} Gamma> is_class_member(polyF, Square); nil Gamma>
Copyright © 1995-2010 by Cogent Real-Time Systems, Inc. All rights reserved.