protected void InitQuery(vMainProductPhotoQuery query)
        {
            query.OnLoadDelegate = this.OnQueryLoaded;

            if (!query.es2.HasConnection)
            {
                query.es2.Connection = ((IEntityCollection)this).Connection;
            }
        }
 public bool Load(vMainProductPhotoQuery query)
 {
     this.query = query;
     InitQuery(this.query);
     return(Query.Load());
 }