removed some duplicated code and improved name of getViewDataTableInfoFor method