Examples of depth()


Examples of com.arjuna.ats.arjuna.coordinator.ActionHierarchy.depth()

        /*
         * Do the manditory stuff first.
         */

        ActionHierarchy txHier = currentCoordinator.getHierarchy();
                final int depth = txHier.depth() ;
                _identifierValues = new String[depth] ;
                _expiresValues = new int[depth] ;

                _identifierValues[0] = txHier.getDeepestActionUid().stringForm() ;
                _expiresValues[0] = hier.activity(hier.size()-1).getTimeout() ;
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

        EntityBean detailBean = prop.getValueAsEntityBean(parentBean);
        if (detailBean != null) {
          if (prop.isSaveRecurseSkippable(detailBean)) {
            // skip saving this bean
          } else {
            t.depth(+1);
            prop.setParentBeanToChild(parentBean, detailBean);
            saveRecurse(detailBean, t, parentBean, insertMode);
            t.depth(-1);
          }
        }
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

            // skip saving this bean
          } else {
            t.depth(+1);
            prop.setParentBeanToChild(parentBean, detailBean);
            saveRecurse(detailBean, t, parentBean, insertMode);
            t.depth(-1);
          }
        }
      }
    }
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

      Set<?> modifyRemovals = c.getModifyRemovals();
      if (modifyRemovals != null && !modifyRemovals.isEmpty()) {

        SpiTransaction t = saveMany.getTransaction();
        // increase depth for batching order
        t.depth(+1);
        for (Object removedBean : modifyRemovals) {
          if (removedBean instanceof EntityBean) {
            EntityBean eb = (EntityBean)removedBean;
            if (eb._ebean_getIntercept().isLoaded()) {
              // only delete if the bean was loaded meaning that
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

              // it is know to exist in the DB
              deleteRecurse(removedBean, t);
            }
          }
        }
        t.depth(-1);
      }
    }
  }

  /**
 
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

      detailIds = new ArrayList<Object>();
    }

    // increase depth for batching order
    SpiTransaction t = saveMany.getTransaction();
    t.depth(+1);

    // if a map, then we get the key value and
    // set it to the appropriate property on the
    // detail bean before we save it
    boolean isMap = ManyType.JAVA_MAP.equals(prop.getManyType());
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

    if (detailIds != null) {
      // deleteMissingChildren is true so deleting children that were not just processed
      deleteManyDetails(t, prop.getBeanDescriptor(), parentBean, prop, detailIds);
    }

    t.depth(-1);
  }

  public int deleteManyToManyAssociations(EntityBean ownerBean, String propertyName, Transaction t) {

    BeanDescriptor<?> descriptor = beanDescriptorManager.getBeanDescriptor(ownerBean.getClass());
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

      EntityBean assocBean = oneProp.getValueAsEntityBean(parentBean);

      int depth = oneProp.isOneToOneExported() ? 1 : -1;
      int revertDepth = -1 * depth;

      trans.depth(depth);
      saveRecurse(assocBean, t, parentBean, true);
      trans.depth(revertDepth);

    } else {
      String msg = "Expecting [" + prop.getFullBeanName() + "] to be a OneToMany, OneToOne, ManyToOne or ManyToMany property?";
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

      int depth = oneProp.isOneToOneExported() ? 1 : -1;
      int revertDepth = -1 * depth;

      trans.depth(depth);
      saveRecurse(assocBean, t, parentBean, true);
      trans.depth(revertDepth);

    } else {
      String msg = "Expecting [" + prop.getFullBeanName() + "] to be a OneToMany, OneToOne, ManyToOne or ManyToMany property?";
      throw new PersistenceException(msg);
    }
View Full Code Here

Examples of com.avaje.ebeaninternal.api.SpiTransaction.depth()

      deletions = manyValue.getModifyRemovals();
      // reset so the changes are only processed once
      manyValue.modifyReset();
    }

    t.depth(+1);

    if (additions != null && !additions.isEmpty()) {
      for (Object other : additions) {
        EntityBean otherBean = (EntityBean)other;
        // the object from the 'other' side of the ManyToMany
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.