Ignore:
Timestamp:
Mar 11, 2007, 11:43:15 AM (18 years ago)
Author:
cinc
Message:

Improvements for the documentation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/nom/idl/nomobj.idl

    r219 r250  
    1616* The Initial Developer of the Original Code is
    1717* netlabs.org: Chris Wohlgemuth <cinc-ml@netlabs.org>.
    18 * Portions created by the Initial Developer are Copyright (C) 2005-2006
     18* Portions created by the Initial Developer are Copyright (C) 2005-2007
    1919* the Initial Developer. All Rights Reserved.
    2020*
     
    3232*
    3333* ***** END LICENSE BLOCK ***** */
     34/** \file nomobj.idl
     35   
     36Class definition file for the NOM class NOMObject.
     37*/
     38
    3439#ifndef NOMOBJ_IDL_INCLUDED
    3540#define NOMOBJ_IDL_INCLUDED
     
    3944//NOMCLASSNAME(NOMObject);
    4045
     46/** \interface NOMObject
     47
     48    This is the root class of NOM. It provides methods common to all objects.
     49
     50    \remarks NOMObject can't be replaced.
     51   
     52 */
    4153interface NOMObject
    4254{
     
    4759     This method is intended to be overriden by classes which need some initialization.
    4860
    49      \par How to override
     61     \remarks This method is called by the system during object creation. Don't call it
     62     from your code or unexpected things may happen.
     63
     64     \par How to override:
    5065     The parent class must always be called first when overriden.
    5166
    52      \sa impl_NOMObject_nomInit()
     67     \sa impl_NOMObject_nomInit(), nomUnInit()
    5368   */
    5469  void nomInit();
     
    6075     collected and calls nomUnInit() to give the object a chance for cleanup.
    6176
    62      \note It's not necessary to free memory in nomUnInit(). This is the job of the garbage collector.
    63      Only system resources like file handles etc. must be explicitely freed.
     77     \remarks It's not necessary to free memory in nomUnInit(). This is the job of the garbage collector.
     78     Only system resources like file handles etc. must be explicitely freed.
     79     This method is called by the system during object deletion. Don't call it
     80     from your code or unexpected things may happen.
    6481
    65      \par How to override
     82     \par How to override:
    6683     The parent method must be called after doing the own processing.
    6784
    68      \sa impl_NOMObject_nomUnInit()
     85     \sa impl_NOMObject_nomUnInit(), nomInit();
    6986   */
    7087  void nomUnInit();
     
    7390     Return the size of the object. That is sizeof(mTab*)+sizeof(all instance vars)
    7491
    75      \par How to override
     92     \par How to override:
    7693     This method is usually not overriden.
    7794
     
    8198
    8299  /**
    83      This method calls nomUnInit() to give the object a chance of freeing system resources.
     100     Delete an object. This method is useful if you have to control the point in time when
     101     an object is actually destroyed. Normally the garbage collector destroys any object when
     102     no longer in use but there is no way to control when this happens.
     103
     104     \remarks This method calls nomUnInit() to give the object a chance of freeing system resources.
    84105     Afterwards the memory occupied by the object is given back to the system and the
    85106     object is not accessible anymore.
    86107
    87      \sa impl_NOMObject_delete()
     108     \par HowTo override:
     109     This method is usually not overriden. If you need some own processing during object
     110     destruction override nomUnInit().
     111
     112     \sa impl_NOMObject_delete(), nomUnInit()
    88113   */
    89114  void delete();
     
    92117     This method returns a pointer to the class object of this object.
    93118
    94      \par How to override
     119     \par How to override:
    95120     This method is usually not overriden.
    96121
     
    105130     are properly handled without the need to override this method in every subclass.
    106131
     132     When deriving from classes new methods are added to a class but the already present ones are
     133     usually not changed. If one of these classes creates a new object of the class itself
     134     is an instance of unexpected things may happen. Consider the
     135     following class hierarchy:
     136
     137     \code
     138     NOMObject->NOMString->NOMPath
     139     \endcode
     140
     141     When a method introduced by \e NOMString tries to create a new \e NOMString object it may
     142     use the \e NOMStringNew() macro to do so. Problems arise if the method is called from
     143     within a \e NOMPath object. The caller probably doesn't want a \e NOMString but rather
     144     a \e NOMPath object. So instead of having to override the method using the creation macro
     145     which may mean to recreate the whole method implementation the macro should be replaced
     146     by a call to new().
     147
    107148     This method will get the class object of nomSelf and call nomNew() on it creating
    108149     a new object which has exactly the same class hierarchy of nomSelf.
    109150
    110      \par How to override
     151     \remarks Because a new object is created the whole object creation sequence will take
     152     place which means a call to nomInit() will be made by the system.
     153
     154     \par How to override:
    111155     This method is usually not overriden.
    112156
Note: See TracChangeset for help on using the changeset viewer.