Reform API structure.

Signed-off-by: OGINO Masanori <masanori.ogino@gmail.com>
Add test::to_code_reserved test.

Signed-off-by: OGINO Masanori <masanori.ogino@gmail.com>