public void addQuery(Query q) { if (!isRootQuery(q)) { clusterQueryMapper.Add(q, new List<Query>()); } }
/* * Check if one query subsumes another */ public Boolean SubsumesOrEqual(Query q2) { return SubsumesOrEqual(this.queryTables, q2.queryTables) //table check && SubsumesOrEqual(this.queryProjectedAttributes, q2.queryProjectedAttributes) //attribute check && (this.querySelectionAttribute.attributeName == null || this.queryPercentSelection >= q2.queryPercentSelection); //selectivity check }
public bool isRootQuery(Query q) { return clusterQueryMapper.Keys.Contains(q); }