java api for query and result