code: public QueryTreeElement getQuery(String id) {
  		for (QueryTreeElement query : queries) {
  			if (query.getID().equals(id)) {
  				return query;
  			}
  		}
  		return null;
  	}
docs: Searches a specific query and returns the object query else returns null.