More buffer stuff: deadlines, indexOf and read.

Rename Timeout to Deadline. I'm still unsatisfied with this API,
but at least the new name is accurate.

Implement indexOf as a linear scan and read by delegating to
write.
Merge pull request #492 from square/jwilson_0127_indexof

More buffer stuff: deadlines, indexOf and read.