Revamped register_first()/ _last()

This is an update on this previous pull request https://github.com/boto/botocore/pull/299/files. I need it for some future features in the cli.

cc @jamesls @danielgtaylor