@@ -154,14 +154,21 @@ + (id)objectForTLSKey: (OFTLSKey*)key; /** * \brief Returns the current thread. * - * \return The current thread or nil if we are in the main thread + * \return The current thread */ + (OFThread*)currentThread; +/** + * \brief Returns the main thread. + * + * \return The main thread + */ ++ (OFThread*)mainThread; + /** * \brief Suspends execution of the current thread for the specified time * interval. * * \param seconds The number of seconds to sleep @@ -190,10 +197,12 @@ * \brief Terminates the current thread, letting it return the specified object. * * \param object The object which the terminated thread will return */ + (void)terminateWithObject: (id)object; + ++ (void)_createMainThread; /** * \brief Initializes an already allocated thread with the specified object. * * \param object An object which is passed for use in the main method or nil