Skip to content

Commit

Permalink
README
Browse files Browse the repository at this point in the history
  • Loading branch information
hsbt committed Aug 22, 2018
1 parent 4fa7640 commit 58baa95
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
# Thwait
# ThreadsWait

Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/thwait`. To experiment with that code, run `bin/console` for an interactive prompt.

TODO: Delete this and the text above, and describe your gem
This class watches for termination of multiple threads. Basic functionality (wait until specified threads have terminated) can be accessed through the class method ThreadsWait::all_waits. Finer control can be gained using instance methods.

## Installation

Expand All @@ -22,7 +20,14 @@ Or install it yourself as:

## Usage

TODO: Write usage instructions here
```
ThreadsWait.all_waits(thr1, thr2, ...) do |t|
STDERR.puts "Thread #{t} has terminated."
end
th = ThreadsWait.new(thread1,...)
th.next_wait # next one to be done
```

## Development

Expand Down

0 comments on commit 58baa95

Please sign in to comment.