Show
Ignore:
Timestamp:
01/16/08 16:07:40 (1 year ago)
Author:
cneumann
Message:

changed: - factory functions return a TransitPtr? that can not be implicitly

converted to C Ptr. Should help with porting.

added: - GlobalRefPtr?, needed for cases where upon return from main

a RefPtr? goes out of scope (it would attempt to access the
FCFactory which is already shutdown at that point).

status: - vrml loader does not compile (needs porting to ref ptr)

  • tutorials compile, run and exit cleanly
  • multithreading and cluster are untested, yet
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/Carsten_PtrWork2/Source/System/FileIO/OSB/OSGNFIOBase.h

    r1023 r1039  
    9090    /*! \{                                                                 */ 
    9191 
    92     static NodePtr  read    (std::istream &is, 
    93                              const std::string &options); 
    94     static bool     write   (const NodePtr &node, std::ostream &os, 
    95                              const std::string &options); 
     92    static NodeTransitPtr read (std::istream &is, 
     93                                const std::string &options); 
     94    static bool           write(const NodePtr &node, std::ostream &os, 
     95                                const std::string &options); 
    9696 
    9797    /*! \}                                                                 */ 
     
    107107 
    108108    /*! \}                                                                 */ 
     109    /*---------------------------------------------------------------------*/ 
    109110    /*! \name                      Init                                    */ 
    110111    /*! \{                                                                 */ 
     
    114115 
    115116    /*! \}                                                                 */ 
     117    /*---------------------------------------------------------------------*/ 
    116118    /*! \name                      Read                                    */ 
    117119    /*! \{                                                                 */ 
    118120 
    119     virtual FieldContainerPtr readFC(const std::string &typeName) = 0; 
     121    virtual FieldContainerTransitPtr readFC(const std::string &typeName) = 0; 
    120122 
    121123    static std::string readFCFields    (const FieldContainerPtr &fc, 
     
    231233    /*! \{                                                                 */ 
    232234 
    233     static FieldContainerPtr readFieldContainer(void); 
     235    static FieldContainerTransitPtr readFieldContainer(void); 
    234236 
    235237    /*! Wrap info about an fc. 
     
    246248        bool isMultiField(void) const; 
    247249 
    248         FieldContainerPtr   _fc;          /*!< The fc we reference. */ 
    249         UInt32              _fieldId;     /*!< Id of the field that needs patched. */ 
    250         UInt32              _id;          /*!< fcptr id, if 0, we wrap a mfield. */ 
    251         GetFieldHandlePtr    _field;       /*!< ptr to the field in the fc. */ 
    252         std::vector<UInt32>  _ids;       /*!< If mfield, list of ids to replace. */ 
     250        FieldContainerRefPtr _fc;        /*!< The fc we reference. */ 
     251        UInt32              _fieldId;   /*!< Id of the field that needs patched. */ 
     252        UInt32              _id;        /*!< fcptr id, if 0, we wrap a mfield. */ 
     253        GetFieldHandlePtr    _field;     /*!< ptr to the field in the fc. */ 
     254        std::vector<UInt32>  _ids;       /*!< If mfield, list of ids to replace. */ 
    253255    }; 
    254256 
     
    272274 
    273275    //static UInt32                        _id; 
    274     static std::list<FieldContainerPtr>  _fcList;        /*!< List of all fc's encountered. */ 
    275     static std::set<UInt32>              _fcSet;         /*!< Set of all fc ids encountered. */ 
     276    static std::list<FieldContainerRefPtr>  _fcList;        /*!< List of all fc's encountered. */ 
     277    static std::set<UInt32>                 _fcSet;         /*!< Set of all fc ids encountered. */ 
    276278    //typedef std::map<FieldContainerPtr, UInt32> IdMap; 
    277279    //static IdMap                         _ids;