Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4283 in orxonox.OLD for orxonox/branches/physics/src/lib/lang


Ignore:
Timestamp:
May 24, 2005, 10:32:34 PM (20 years ago)
Author:
bensch
Message:

orxonox/branches/physics: merged the trunk back to branches/physics
merged with command
svn merge -r 4223:HEAD ../../trunk/ .
conflicts additively included

Location:
orxonox/branches/physics/src/lib/lang
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/branches/physics/src/lib/lang/base_object.cc

    r3651 r4283  
    3939BaseObject::~BaseObject ()
    4040{
    41   delete []this->className;
     41  //  delete []this->className;
    4242}
    4343
    44 void BaseObject::setClassName (char* className)
     44void BaseObject::setClassName (const char* className)
    4545{
    46   this->className = new char[strlen(className)+1];
    47   strcpy(this->className, className);
    48 }
    49 
    50 char* BaseObject::getClassName(void) const
    51 {
    52   return className;
     46  this->className = className;
    5347}
    5448
  • orxonox/branches/physics/src/lib/lang/base_object.h

    r3651 r4283  
    1717  virtual ~BaseObject ();
    1818
    19   void setClassName (char* className);
    20   char* getClassName(void) const;
     19  void setClassName (const char* className);
     20  inline const char* getClassName(void) const { return this->className;};
    2121  bool isA (char* className);
    2222
     
    2525
    2626 private:
    27   char* className;
     27  const char* className;
    2828  bool finalized;
    2929};
Note: See TracChangeset for help on using the changeset viewer.