Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5806 in orxonox.OLD for branches/network/src/lib


Ignore:
Timestamp:
Nov 28, 2005, 6:49:58 PM (19 years ago)
Author:
patrick
Message:

network: made some functions and arguments const, since they musn't change any data.

Location:
branches/network/src/lib/network
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/network/src/lib/network/synchronizeable.cc

    r5804 r5806  
    4040                          \brief write data to NetworkStream
    4141 */
    42  void Synchronizeable::writeBytes(byte* data, int length)
     42 void Synchronizeable::writeBytes(const byte* data, int length)
    4343{
    4444
     
    5151                                 \brief read data from NetworkStream
    5252 */
    53  int Synchronizeable::readBytes(byte* data)
     53 int Synchronizeable::readBytes(byte* data) const
    5454{
    5555
     
    5959}
    6060
    61  void Synchronizeable::writeDebug()
     61 void Synchronizeable::writeDebug() const
    6262{
    6363
    6464}
    6565
    66  void Synchronizeable::readDebug()
     66 void Synchronizeable::readDebug() const
    6767{
    6868
  • branches/network/src/lib/network/synchronizeable.h

    r5804 r5806  
    1717    ~Synchronizeable();
    1818
    19     virtual void      writeBytes(byte* data, int length);
    20     virtual int       readBytes(byte* data);
    21     virtual void      writeDebug();
    22     virtual void      readDebug();
     19    virtual void      writeBytes(const byte* data, int length);
     20    virtual int       readBytes(byte* data) const;
     21    virtual void      writeDebug() const;
     22    virtual void      readDebug() const;
    2323
    24     inline const char* getName() { return this->name; }
     24    inline const char* getName() const { return this->name; }
    2525
    2626  private:
Note: See TracChangeset for help on using the changeset viewer.