function recordRows = getRecords(this, queryObject)
    % GETRECORDS
    
    % Copyright 2018 The MathWorks, Inc.
    
    scopedIds = {};
    if ~isempty(queryObject.TreeSelection)
        scopedIds = this.SpreadsheetScopingManager.getScopingIds(queryObject.TreeSelection);
    end
    recordRows = this.DataManager.getData(queryObject, scopedIds);
    
end