Moved query model into separate package. Updated query model to respect GWT rpc needs. Minor cleanups.