From 3ee78810becfeeb3690468ac735b6ba20dc5c501 Mon Sep 17 00:00:00 2001 From: sc Date: Tue, 28 Nov 2000 14:52:16 +0000 Subject: Integration into IvyLeague Dnn -> Ivl Some class names changed, because of conflicts with previous Uch classes Imakefile is replaced with Makefile --- dnn/Disposable.cc | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) (limited to 'dnn/Disposable.cc') diff --git a/dnn/Disposable.cc b/dnn/Disposable.cc index 4e8a03a..041931b 100755 --- a/dnn/Disposable.cc +++ b/dnn/Disposable.cc @@ -15,33 +15,32 @@ #include "Disposable.h" #include "Loop.h" -bool DnnDisposable::ClassInitialized = false; -CcuInitializerFor DnnDisposable::Dependance; -CcuInitializerFor DnnDisposable::Initializer; -CcuListOf DnnDisposable::Garbage; +bool IvlDisposable::ClassInitialized = false; +IvlInitializerFor IvlDisposable::Dependance; +IvlInitializerFor IvlDisposable::Initializer; +IvlListOf IvlDisposable::Garbage; void -DnnDisposable :: ClassInit () +IvlDisposable :: ClassInit () { if (!ClassInitialized) { ClassInitialized = true; - DnnBaseMultiplexer::AddGlobalHook (&DnnDisposable::DeleteGarbage, true); + IvlBaseMultiplexer::AddGlobalHook (&IvlDisposable::DeleteGarbage, true); } } #if 0 void -DnnDisposable :: ClassClose () +IvlDisposable :: ClassClose () { - DnnBaseMultiplexer::RemoveGlobalHook (&DnnDisposable::DeleteGarbage); + IvlBaseMultiplexer::RemoveGlobalHook (&IvlDisposable::DeleteGarbage); } #endif - /*? -\typ{DnnDisposable} objects are objects whose deletion is called in a safe +\typ{IvlDisposable} objects are objects whose deletion is called in a safe place in an asynchronous way. -Instances of derived class of DnnDisposable which are to be deleted +Instances of derived class of IvlDisposable which are to be deleted asynchronously must be allocated only dynamically with new. An instance is put into it's class garbage list (and thus deleted) @@ -52,16 +51,16 @@ a deletion while in an unsafe state. Typically this class is to be used by derivation of UchChannel which can be deleted from within themselves after a call to \fun{HandleRead}. ?*/ -DnnDisposable :: DnnDisposable () +IvlDisposable :: IvlDisposable () { } -DnnDisposable :: ~DnnDisposable () +IvlDisposable :: ~IvlDisposable () { } void -DnnDisposable :: Trash () +IvlDisposable :: Trash () { Garbage.Append (this); }; @@ -70,9 +69,9 @@ DnnDisposable :: Trash () Delete all the instances which are in the garbage list. ?*/ void -DnnDisposable :: DeleteGarbage () +IvlDisposable :: DeleteGarbage () { - DnnDisposable* d; + IvlDisposable* d; while (d = Garbage.RemoveFirst ()) delete d; } -- cgit v1.1