![]() System : Linux absol.cf 5.4.0-198-generic #218-Ubuntu SMP Fri Sep 27 20:18:53 UTC 2024 x86_64 User : www-data ( 33) PHP Version : 7.4.33 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, Directory : /proc/thread-self/root/usr/share/doc/gnustep-base-doc/BaseAdditions/Reference/ |
Upload File : |
<?xml version="1.0"?> <!DOCTYPE gsdoc PUBLIC "-//GNUstep//DTD gsdoc 1.0.4//EN" "http://www.gnustep.org/gsdoc-1_0_4.dtd"> <gsdoc base="GCObject" up="BaseAdditions"> <head> <title>GCObject documentation</title> <author name="Richard Frith-Macdonald"> <email address="rfm@gnu.org"> rfm@gnu.org </email> </author> <copy>2002 Free Software Foundation, Inc.</copy> </head> <body> <front><contents /></front> <chapter> <heading> Software documentation for the GCArray class </heading> <class name="GCArray" super="NSArray" ovadd="1.0.0"> <declared>GNUstepBase/GCObject.h</declared> <desc> <em>Description forthcoming.</em> </desc> <ivariable type="id*" name="_contents" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="unsigned int" name="_count" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="BOOL*" name="_isGCObject" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="gcInfo" name="gc" validity="protected" ovadd="1.0.0"> <desc> <em>Description forthcoming.</em> </desc> </ivariable> </class> </chapter> <chapter> <heading> Software documentation for the GCDictionary class </heading> <class name="GCDictionary" super="NSDictionary" ovadd="1.0.0"> <declared>GNUstepBase/GCObject.h</declared> <desc> <em>Description forthcoming.</em> </desc> <ivariable type="NSMapTable*" name="_map" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="gcInfo" name="gc" validity="protected" ovadd="1.0.0"> <desc> <em>Description forthcoming.</em> </desc> </ivariable> </class> </chapter> <chapter> <heading> Software documentation for the GCMutableArray class </heading> <class name="GCMutableArray" super="NSMutableArray" ovadd="1.0.0"> <declared>GNUstepBase/GCObject.h</declared> <desc> <em>Description forthcoming.</em> </desc> <ivariable type="id*" name="_contents" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="unsigned int" name="_count" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="BOOL*" name="_isGCObject" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="unsigned int" name="_maxCount" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="gcInfo" name="gc" validity="protected" ovadd="1.0.0"> <desc> <em>Description forthcoming.</em> </desc> </ivariable> </class> </chapter> <chapter> <heading> Software documentation for the GCMutableDictionary class </heading> <class name="GCMutableDictionary" super="NSMutableDictionary" ovadd="1.0.0"> <declared>GNUstepBase/GCObject.h</declared> <desc> <em>Description forthcoming.</em> </desc> <ivariable type="NSMapTable*" name="_map" validity="protected" ovadd="1.0.0"> <desc> <em>Warning</em> the underscore at the start of the name of this instance variable indicates that, even though it is not technically <em>private</em>, it is intended for internal use within the package, and you should not use the variable in other code. </desc> </ivariable> <ivariable type="gcInfo" name="gc" validity="protected" ovadd="1.0.0"> <desc> <em>Description forthcoming.</em> </desc> </ivariable> </class> </chapter> <chapter> <heading> Software documentation for the GCObject class </heading> <class name="GCObject" super="NSObject" ovadd="1.0.0"> <declared>GNUstepBase/GCObject.h</declared> <desc> <p> The GCObject class is both the base class for all garbage collected objects, and an infrastructure for handling garbage collection. </p> <p> It maintains a list of all garbage collectable objects and provides a method to run a garbage collection pass on those objects. </p> </desc> <ivariable type="gcInfo" name="gc" validity="protected" ovadd="1.0.0"> <desc> <em>Description forthcoming.</em> </desc> </ivariable> <method type="void" factory="yes" ovadd="1.0.0"> <sel>gcCollectGarbage</sel> <desc> <p> This method runs a garbage collection, causing unreferenced objects to be deallocated. This is done using a simple three pass algorithm - </p> <deflist> <term>Pass 1</term> <desc> All the garbage collectable objects are sent a <ref type="method" id="-gcDecrementRefCountOfContainedObjects">-gcDecrementRefCountOfContainedObjects</ref> message. </desc> <term>Pass 2</term> <desc> All objects having a refCount greater than 0 are sent an <ref type="method" id="-gcIncrementRefCountOfContainedObjects">-gcIncrementRefCountOfContainedObjects</ref> message. </desc> <term>Pass 3</term> <desc> All the objects that still have the refCount of 0 are part of cyclic graphs and none of the objects from this graph are held by some object outside graph. These objects receive the <ref type="method" id="-dealloc"> -dealloc </ref> message. In this method they should send the <ref type="method" id="-dealloc"> -dealloc </ref> message to any garbage collectable (GCObject and subclass) instances they contain. </desc> </deflist> <p> During garbage collection, the <ref type="method" id="+gcIsCollecting"> +gcIsCollecting </ref> method returns <code>YES</code>. </p> </desc> </method> <method type="BOOL" factory="yes" ovadd="1.0.0"> <sel>gcIsCollecting</sel> <desc> Returns a flag to indicate whether a garbage collection is in progress. </desc> </method> <method type="void" factory="yes" ovadd="1.0.0"> <sel>gcObjectWillBeDeallocated:</sel> <arg type="GCObject*">anObject</arg> <desc> Called to remove <var>anObject</var> from the list of garbage collectable objects. <br /> This method is provided so that classes which are not subclasses of GCObject (but which have the same initial instance variable layout) can use multiple inheritance (behaviors) to act as GCObject instances, but can have their own <ref type="method" id="-dealloc"> -dealloc </ref> methods. <br /> These classes should call this in their own <ref type="method" id="-dealloc"> -dealloc </ref> methods. </desc> </method> <method type="void" ovadd="1.0.0"> <sel>gcDecrementRefCount</sel> <desc> Decrements the garbage collection reference count for the receiver. <br /> </desc> </method> <method type="void" ovadd="1.0.0"> <sel>gcDecrementRefCountOfContainedObjects</sel> <desc> <p> Marks the receiver as not having been visited in the current garbage collection process (first pass of collection). </p> <p> All container subclasses should override this method to call the super implementation then decrement the ref counts of their contents as well as sending the <ref type="method" id="-gcDecrementRefCountOfContainedObjects">-gcDecrementRefCountOfContainedObjects</ref> message to each of them. </p> </desc> </method> <method type="void" ovadd="1.0.0"> <sel>gcIncrementRefCount</sel> <desc> Increments the garbage collection reference count for the receiver. <br /> </desc> </method> <method type="BOOL" ovadd="1.0.0"> <sel>gcIncrementRefCountOfContainedObjects</sel> <desc> <p> Checks to see if the receiver has already been visited in the current garbage collection process, and either marks the receiver as visited (and returns <code>YES</code>) or returns <code>NO</code> to indicate that it had already been visited. </p> <p> All container subclasses should override this method to call the super implementation then, if the method returns <code>YES</code>, increment the reference count of any contained objects and send the <ref type="method" id="-gcIncrementRefCountOfContainedObjects">-gcIncrementRefCountOfContainedObjects</ref> to each of the contained objects too. </p> </desc> </method> </class> </chapter> <chapter> <heading> Software documentation for the GCObject(Extra) category </heading> <category name="Extra" class="GCObject" ovadd="1.0.0"> <declared>GNUstepBase/GCObject.h</declared> <desc> This category implements accessor methods for the instance variables used for garbage collecting. If/when we can ensure that all garbage collecting classes use the same initial ivar layout, we can remove these methods and the garbage collector can access the ivars directly, making a pretty big performance improvement during collecting. <br /> NB. These methods must *only* be used by the garbage collecting process or in methods called from the garbage collector. Anything else is not thread-safe. </desc> <method type="BOOL" ovadd="1.0.0"> <sel>gcAlreadyVisited</sel> <desc> <em>Description forthcoming.</em> </desc> </method> <method type="GCObject*" ovadd="1.0.0"> <sel>gcNextObject</sel> <desc> <em>Description forthcoming.</em> </desc> </method> <method type="GCObject*" ovadd="1.0.0"> <sel>gcPreviousObject</sel> <desc> <em>Description forthcoming.</em> </desc> </method> <method type="GCObject*" ovadd="1.0.0"> <sel>gcSetNextObject:</sel> <arg type="GCObject*">anObject</arg> <desc> <em>Description forthcoming.</em> </desc> </method> <method type="GCObject*" ovadd="1.0.0"> <sel>gcSetPreviousObject:</sel> <arg type="GCObject*">anObject</arg> <desc> <em>Description forthcoming.</em> </desc> </method> <method type="void" ovadd="1.0.0"> <sel>gcSetVisited:</sel> <arg type="BOOL">flag</arg> <desc> <em>Description forthcoming.</em> </desc> </method> </category> </chapter> </body> </gsdoc>