unity – How do I iterate through keyframes in an animation clip?

I have an animation clip that animates a human model.

I would like to ask if it is possible to iterate through all bones and their key frames like that:

(pseudo code)

 foreach( GameObject obj in objects)
     //get animation
     Animation anim = obj.GetComponent<Animation>();
     //some how get the keyframes
     Keyframes() keys = anim.???
     Vector3 trans = keys(0).transform.localPosition;
     Quaternion rot = keys(0).transform.localRotation;

I have copied this question from here because it resembles just the very same question but didn’t yield an answer.

Thank you!