Package horizons :: Package util :: Module preloader :: Class PreloadingThread
[hide private]
[frames] | no frames]

Class PreloadingThread

source code

        object --+        
threading._Verbose --+    
      threading.Thread --+

Preloads game data while in the main menu. Once a game is started, `wait_for_finish` is called to end the thread.

Instance Methods [hide private]
This constructor should always be called with keyword arguments.
source code
Preloads game data.
source code
Wait for preloading to finish.
source code

Inherited from threading.Thread: __repr__, daemon, getName, ident, isAlive, isDaemon, is_alive, join, name, setDaemon, setName, start

Inherited from threading.Thread (private): _block, _reset_internal_locks, _set_daemon, _set_ident

Inherited from threading._Verbose (private): _note

    Inherited from object
x.__delattr__('name') <==> del
default object formatter
x.__getattribute__('name') <==>
a new object with type S, a subtype of T
__new__(T, S, ...)
helper for pickle
helper for pickle
x.__setattr__('name', value) <==> = value
size of object in memory, in bytes
Abstract classes can override this to customize issubclass().
Properties [hide private]
    Inherited from object
the object's class
Method Details [hide private]


source code 

This constructor should always be called with keyword arguments. Arguments are:

*group* should be None; reserved for future extension when a ThreadGroup class is implemented.

*target* is the callable object to be invoked by the run() method. Defaults to None, meaning nothing is called.

*name* is the thread name. By default, a unique name is constructed of the form "Thread-N" where N is a small decimal number.

*args* is the argument tuple for the target invocation. Defaults to ().

*kwargs* is a dictionary of keyword arguments for the target invocation. Defaults to {}.

If a subclass overrides the constructor, it must make sure to invoke the base class constructor (Thread.__init__()) before doing anything else to the thread.

Overrides: object.__init__
(inherited documentation)


source code 

Preloads game data.

Keeps releasing and acquiring lock, runs until lock can't be acquired.