[pulse][minor] reduce code duplication for attribute "getters"
[pulse][minor] reduce code duplication for attribute "getters"

Summary: This will be more useful later when adding another one.

Reviewed By: ezgicicek, jberdine

Differential Revision: D18115231

fbshipit-source-id: a0a01901a

jvillard/infer,facebook/infer,facebook/infer,jvillard/infer,facebook/infer,jvillard/infer,facebook/infer,jvillard/infer,facebook/infer,jvillard/infer,facebook/infer,facebook/infer,jvillard/infer,jvillard/infer