home *** CD-ROM | disk | FTP | other *** search
- #---------------------------------------------------------------------------
- #
- # (c) Westmount Technology 1994
- #
- # File: @(#)cbclasssta.tcl 1.2
- # Author: <generated>
- # Description:
- #---------------------------------------------------------------------------
- # SccsId = @(#)cbclasssta.tcl 1.2 28 Jul 1995 Copyright 1994 Westmount Technology
-
- # Start user added include file section
- # End user added include file section
-
-
- Class CBClassStack : {GCObject} {
- constructor
- method destructor
- method push
- method pop
- method size
- attribute classList
- }
-
- constructor CBClassStack {class this} {
- set this [GCObject::constructor $class $this]
- # Start constructor user section
- $this classList [List new]
- # End constructor user section
- return $this
- }
-
- method CBClassStack::destructor {this} {
- # Start destructor user section
- # End destructor user section
- }
-
- method CBClassStack::push {this newClass} {
- [$this classList] insert $newClass
- }
-
- method CBClassStack::pop {this} {
- if {[$this size] == 0} {
- return ""
- }
- set elem [[$this classList] index]
- [$this classList] remove 0
- return $elem
- }
-
- method CBClassStack::size {this} {
- return [llength [[$this classList] contents]]
- }
-
- # Do not delete this line -- regeneration end marker
-
-