Exemplo n.º 1
0
 public ReferenceInfo GetOrCreateReference(string name, EntityInfo referenceEntity,ReferenceKinds kind) {
     var result = this.GetReference(referenceEntity,kind);
     if (result == null) {
         result = new ReferenceInfo(name, this, referenceEntity, kind);
         this._references.Add(result);
     }
     
     return result;
 }
Exemplo n.º 2
0
 public JoinTable GetOrCreate(ReferenceInfo info,JoinTable prev=null) {
     JoinTable result = null;
     for (var i = 0; i < this._tables.Count; i++) {
         result = this._tables[i];
         if (result.ReferenceInfo == info && result.JoinFrom == prev) return result;
     }
     result = new JoinTable("_TMP_Tb" + (this._tables.Count + 1).ToString(),info,prev);
     return result;
 }
Exemplo n.º 3
0
 public JoinTable(string alias, ReferenceInfo info,JoinTable prev=null) {
     this.Alias = alias;
     this.ReferenceInfo = info;
     this.JoinFrom = prev;
 }