public virtual QQueryBase.CreateCandidateCollectionResult CreateCandidateCollection () { List4 candidatesList = CreateQCandidatesList(); bool checkDuplicates = false; bool topLevel = true; IEnumerator i = IterateConstraints(); while (i.MoveNext()) { QCon constraint = (QCon)i.Current; QCon old = constraint; constraint = constraint.GetRoot(); if (constraint != old) { checkDuplicates = true; topLevel = false; } ClassMetadata classMetadata = constraint.GetYapClass(); if (classMetadata == null) { break; } AddConstraintToCandidatesList(candidatesList, constraint); } return(new QQueryBase.CreateCandidateCollectionResult(candidatesList, checkDuplicates , topLevel)); }
internal virtual Db4objects.Db4o.Internal.Query.Processor.QCon GetRoot() { if (i_parent != null) { return(i_parent.GetRoot()); } return(this); }
private List4 CreateQCandidatesList() { List4 candidatesList = null; IEnumerator i = IterateConstraints(); while (i.MoveNext()) { QCon constraint = (QCon)i.Current; constraint = constraint.GetRoot(); ClassMetadata classMetadata = constraint.GetYapClass(); if (classMetadata == null) { continue; } if (ConstraintCanBeAddedToExisting(candidatesList, constraint)) { continue; } QCandidates candidates = new QCandidates((LocalTransaction)_trans, classMetadata, null); candidatesList = new List4(candidatesList, candidates); } return(candidatesList); }