Examples of begin()


Examples of com.youtube.vitess.vtgate.VtGate.begin()

    KeyspaceId kid = testEnv.getAllKeyspaceIds().get(0);
    Query insertQuery = new QueryBuilder(insertSql, testEnv.keyspace, "master")
        .addBindVar(BindVariable.forULong("id", UnsignedLong.valueOf("1")))
        .addBindVar(BindVariable.forULong("keyspace_id", ((UnsignedLong) kid.getId())))
        .addKeyspaceId(kid).build();
    vtgate.begin();
    vtgate.execute(insertQuery);
    vtgate.commit();
    vtgate.begin();
    try {
      vtgate.execute(insertQuery);
View Full Code Here

Examples of dclong.util.Timer.begin()

public class TestSpeed {
  public static void main(String[] args) {
    RandomGenerator rg = new Well44497b();
    RandomDataImpl rng = new RandomDataImpl(rg);
    Timer timer = new Timer();
    timer.begin();
    final int MAX_THREADS = Runtime.getRuntime().availableProcessors();
    ExecutorService pool = Executors.newFixedThreadPool(MAX_THREADS);
    for (int i = 0; i < 10000; i++) {
      pool.execute(new RandomPermutationRunnable(rng, 2869, 330));
    }
View Full Code Here

Examples of de.mhus.lib.jpa.JpaEntityManager.begin()

   
    JpaManager manager = new JpaManager(prop);
   
    JpaEntityManager em = manager.createEntityManager();
   
    em.begin();
   
    Book book1 = new Book();
    book1.setName("Oh wie schoen ist Panama");
    em.persist(book1);
   
View Full Code Here

Examples of de.willuhn.datasource.GenericIterator.begin()

  
    // Erstbefuellung
    GenericIterator items = getList(getKonto().getValue(),(Date)getFrom().getValue(),(Date)getTo().getValue(),(String)getText().getValue());
    if (items != null)
    {
      items.begin();
      while (items.hasNext())
        addItem(items.next());
    }

    super.paint(parent);
View Full Code Here

Examples of de.willuhn.datasource.rmi.DBIterator.begin()

        }

        Umsatz fromDB = null;
        // Anzahl der vorhandenen Umsaetze in der DB zaehlen
        int counter = 0;
        existing.begin();
        for (int j = 0; j<existing.size(); j++)
        {
          GenericObject dbObject = existing.next();
          if (dbObject.equals(umsatz)) {
            counter++;
View Full Code Here

Examples of helma.objectmodel.db.Transactor.begin()

    public void commit() throws Exception {
        Transactor tx = Transactor.getInstance();
        if (tx != null) {
            String tname = tx.getTransactionName();
            tx.commit();
            tx.begin(tname);
        }
    }

    /**
     * Rollback the current transaction and start a new one.
View Full Code Here

Examples of javassist.bytecode.CodeIterator.begin()

          bc.addGetfield(cc, "_counter", "I");
          bc.add(Bytecode.ICONST_1);
          bc.add(Bytecode.IADD);
          bc.addPutfield(cc, "_counter", "I");
          CodeIterator iter = info.getCodeAttribute().iterator();
          iter.begin();
          iter.insert(bc.get());
        }
      }
    }
    return cc.toBytecode();
View Full Code Here

Examples of javax.enterprise.context.Conversation.begin()

        // create conversation
        ConversationContext conversationContext = new ConversationContext();
        conversationContext.setActive(true);

        Conversation conversation = new ConversationImpl(session.getId(), getWebBeansContext());
        conversation.begin();

        ConversationManager conversationManager = getWebBeansContext().getConversationManager();
        conversationManager.addConversationContext(conversation, conversationContext);

        getWebBeansContext().registerService(ConversationService.class, new MockConversationService(session, conversation));
View Full Code Here

Examples of javax.jdo.Transaction.begin()

    /** */
    protected void insertPCPoints(PersistenceManager pm, int numInsert) {
        Transaction tx = pm.currentTransaction();
        try {
            tx.begin();
            for(int i = 0; i<numInsert; i++) {
                Object pc = new PCPoint(i, i);
                pm.makePersistent(pc);
                inserted.add(pc);
            }
View Full Code Here

Examples of javax.persistence.EntityTransaction.begin()

    if (!withoutService)
      return action.execute(method, parameters);
    else {
      EntityTransaction tx = entityManager.getTransaction();
      try {
        tx.begin();
        Object result = action.execute(method, parameters);
        tx.commit();
        return result;
      } catch (Exception e) {
        tx.rollback();
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.