r4871: *** empty log message ***
[umlisp.git] / class-support.lisp
index abf2cc6475901197ecae3a0a3fc1ca5feab798c3..8f97dd150001680086fac9885689c2350441bb0d 100644 (file)
@@ -2,12 +2,12 @@
 ;;;; *************************************************************************
 ;;;; FILE IDENTIFICATION
 ;;;;
-;;;; Name:          classes-support.lisp
-;;;; Purpose:       Class defintions for UMLisp
-;;;; Programmer:    Kevin M. Rosenberg
-;;;; Date Started:  Apr 2000
+;;;; Name:         classes-support.lisp
+;;;; Purpose:      Support for UMLisp classes
+;;;; Author:       Kevin M. Rosenberg
+;;;; Date Started: Apr 2000
 ;;;;
-;;;; $Id: class-support.lisp,v 1.1 2003/03/29 04:12:32 kevin Exp $
+;;;; $Id: class-support.lisp,v 1.5 2003/05/07 22:53:36 kevin Exp $
 ;;;;
 ;;;; This file, part of UMLisp, is
 ;;;;    Copyright (c) 2000-2002 by Kevin M. Rosenberg, M.D.
@@ -16,8 +16,7 @@
 ;;;; as governed by the terms of the GNU General Public License.
 ;;;; *************************************************************************
 
-(in-package :umlisp)
-(declaim (optimize (speed 3) (safety 1) (compilation-speed 0) (debug 3)))
+(in-package #:umlisp)
 
 
 ;;; Formatting routines
 (define-lookup-display display-term #'find-uterm-lui)
 (define-lookup-display display-str #'find-ustr-sui)
 
+(defun ucon-has-tui (ucon tui)
+  "Returns T if UCON has a semantic type of TUI."
+  (some #'(lambda (usty) (= tui (tui usty))) (s#sty ucon)))
+
+(defgeneric suistr (lo))
+(defmethod suistr ((lo ulo))
+  "Return the string for a ulo object"
+  (find-string-sui (sui lo)))
+
 #+(or scl cmu)
 (dolist (c '(urank udef usat uso ucxt ustr ulo uterm usty urel ucoc uatx ucon uxw uxnw uxns lexterm labr lagr lcmp lmod lnom lprn lprp lspl ltrm ltyp lwd sdef sstr sstre1 sstre2 usrl))
     #+cmu