Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Sep 11, 2010, 12:34:00 AM (14 years ago)
Author:
landauf
Message:

merged doc branch back to trunk

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/libraries/core/command/ExecutorPtr.h

    r7284 r7401  
    2727 */
    2828
     29/**
     30    @file
     31    @ingroup Command FunctorExecutor
     32    @brief Typedefs and definitions of ExecutorPtr, ExecutorStaticPtr, and ExecutorMemberPtr
     33
     34    Instances of orxonox::Executor are usually managed by an orxonox::SharedPtr. This ensures
     35    that Executors will be destroyed after usage. To make things easier, there's a typedef
     36    that defines ExecutorPtr as SharedPtr<Executor>.
     37
     38    Because there's not only orxonox::Executor, but also orxonox::ExecutorStatic, and
     39    orxonox::ExecutorMember, the shared pointers need to store them all and also reflect
     40    their hierarchy - ExecutorStatic and ExecutorMember should not be mixed, but both can
     41    be converted to Executor. This is achieved by using orxonox::SharedChildPtr.
     42
     43    Because it's not possible to use a typedef for a template, we have to define the
     44    helper class ExecutorMemberPtr<T> that makes it easier to use ExecutorMember.
     45*/
     46
    2947#ifndef _ExecutorPtr_H__
    3048#define _ExecutorPtr_H__
     
    3553namespace orxonox
    3654{
     55    /// ExecutorPtr is just a typedef of SharedPtr
    3756    typedef SharedPtr<Executor> ExecutorPtr;
    3857
     58    /// ExecutorStaticPtr is just a typedef of SharedChildPtr
    3959    typedef SharedChildPtr<ExecutorStatic, ExecutorPtr> ExecutorStaticPtr;
    4060
     61    /// It's not possible to use a typedef for ExecutorMemberPtr<T>, so we have to create a child-class instead. It inherits all functions from SharedChildPtr, but needs to (re-)implement some constructors.
    4162    template <class T>
    4263    class ExecutorMemberPtr : public SharedChildPtr<ExecutorMember<T>, ExecutorPtr>
Note: See TracChangeset for help on using the changeset viewer.