Title:

parent() - get the parent thread of a given thread.

Usage:

parent(thread = self() )

Arguments:

thread:
the thread whose parent we are requesting.

Return Value:

an object of class thread representing the parent is returned if the argument is a thread and has a parent. Otherwise, NULL is returned. The very toplevel thread which is the standard evaluator has no parent thread.

See Also:

children()
thread()

Examples:

        # have the parent restart this thread
        # given a function call Start which takes a
        # string to determine what expression to
        # evaluate in the new thread
      p = parent()
      sendTask(Quote(Start(self()@name)),p)

Key Words:

User Level Threads

Last modified: Thu Feb 6 18:32:27 1997