codekitchen/ruby-protocol-buffers — pull request #27 by peter-edge (2013-11-13 11:22:20+00:00)
Title: get_expected_field, get_optional_field

get_expected_field takes nested field names and gets the field, throwing an ArgumentError if it does not exist. get_optional_field returns nil if it does not exist. Let me know if there are different names you want/what else would be good with this, but we have been using something similar for a long time.