[WIP] Perform queries on demand

This creates TableViews on demand rather than executing queries on RLMArray creation. This also fixes the bug when re-sorting RLMArrays and other issues caused by not holding onto the query used when creating a TableView.