Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Mar 27, 2013, 11:17:45 PM (11 years ago)
Author:
landauf
Message:

moved logic to remove an element from an ObjectListBase from MetaObjectList to ObjectListBase

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core6/src/libraries/core/object/ObjectListBase.h

    r9573 r9593  
    9393    class _CoreExport ObjectListBase
    9494    {
    95         friend class MetaObjectListElement;
    96 
    9795        public:
    98             ObjectListBase(Identifier* identifier);
     96            ObjectListBase();
    9997            ~ObjectListBase();
    10098
    101             ObjectListBaseElement* add(ObjectListBaseElement* element);
     99            template <class T>
     100            inline ObjectListBaseElement* add(T* object)
     101                { return this->addElement(new ObjectListElement<T>(object)); }
     102
     103            ObjectListBaseElement* addElement(ObjectListBaseElement* element);
     104            void removeElement(ObjectListBaseElement* element);
    102105
    103106            /// Helper struct, used to export an element and the list to an instance of Iterator.
     
    144147            void notifyIterators(Listable* object) const;
    145148
    146             inline Identifier* getIdentifier() const { return this->identifier_; }
    147 
    148149        private:
    149             Identifier* identifier_;                 //!< The Iterator owning this list
    150150            ObjectListBaseElement* first_;           //!< The first element in the list
    151151            ObjectListBaseElement* last_;            //!< The last element in the list
Note: See TracChangeset for help on using the changeset viewer.