std::io: expand the oneshot/periodic docs.

Examples!

Fixes #14714.
auto merge of #14745 : huonw/rust/timer-doc, r=alexcrichton

std::io: expand the oneshot/periodic docs.

Examples!

Fixes #14714.