Boost logo

Boost Users :

Subject: Re: [Boost-users] boost thread with class
From: Szymon Gatner (szymon.gatner_at_[hidden])
Date: 2012-12-30 06:53:54


Hi Philip,

2012/12/30 Philipp Kraus <philipp.kraus_at_[hidden]>:

>
> Which structure must be implementated for the class myThread and from which class must be derived?
>

no need for derivation. Just implement operator() for your class like so:

class myThread {
    public
          some methods

  void operator()()
  {
    // this will run in new thread
  }

     private
         some properties
}

Cheers,
Simon

-- 
Szymon Gatner
The Lordz Games Studio
www.thelordzgamesstudio.com

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net