Exemplo n.º 1
0
 /** To-one relationship, resolved on first access. */
 public Product getProduct() {
   Long __key = this.productId;
   if (product__resolvedKey == null || !product__resolvedKey.equals(__key)) {
     if (daoSession == null) {
       throw new DaoException("Entity is detached from DAO context");
     }
     ProductDao targetDao = daoSession.getProductDao();
     Product productNew = targetDao.load(__key);
     synchronized (this) {
       product = productNew;
       product__resolvedKey = __key;
     }
   }
   return product;
 }
Exemplo n.º 2
0
 /** called by internal mechanisms, do not call yourself. */
 public void __setDaoSession(DaoSession daoSession) {
   this.daoSession = daoSession;
   myDao = daoSession != null ? daoSession.getStoreDao() : null;
 }