def get_parent(last_parent, klass)
      if last_parent.is_a?(klass)
        return last_parent
      else
        return last_parent.get_parent(last_parent.parent, klass)
      end
    end
def get_parent(last_parent, klass)
      if last_parent.is_a?(klass)
        return last_parent
      else
        return last_parent.get_parent(last_parent.parent, klass)
      end
    end
Follows the tree of parents until the appropriate parent of the requesting record is found.

 @param [Record] last_parent the previous parent (the record from the previous line in the RTP file)
 @param [Record] klass the expected parent record class of this record (e.g. Plan, Field)