Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Mar 17, 2008, 1:33:00 AM (16 years ago)
Author:
landauf
Message:
  • added new XMLPortParam template to specify the template arguments / to specify the functor
  • implemented the Namespace object and
  • added a NamespaceNode class that helps keeping track of the existing namespaces in a level

this is not yet tested nor fully included in the loader nor usefull (as we have no scripts at the moment), but i think it's a good start.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core2/src/orxonox/core/Namespace.h

    r879 r895  
    4949            const BaseObject* saveObjects(unsigned int index) const;
    5050
    51             void addSubnamespace(Namespace* ns);
    52             bool hasSubnamespace(const std::string& name) const;
     51            void setAutogenerated(bool bAutogenerated)
     52                { this->bAutogeneratedFileRootNamespace_ = bAutogenerated; }
     53            bool isAutogenerated() const
     54                { return this->bAutogeneratedFileRootNamespace_; }
     55
     56            void setOperator(const std::string& op)
     57                { this->operator_ = op; }
     58            const std::string& getOperator() const
     59                { return this->operator_; }
     60
     61            bool includes(const Namespace* ns) const;
     62            bool isIncludedIn(const Namespace* ns) const { return ns->includes(this); }
    5363
    5464        private:
    55             std::map<std::string, Namespace*> namespaces_;
    56             Namespace* representingNamespace_;
     65            std::set<NamespaceNode*> representingNamespaces_;
     66            bool bAutogeneratedFileRootNamespace_;
     67            std::string operator_;
    5768    };
    5869}
Note: See TracChangeset for help on using the changeset viewer.