Examples of bind()


Examples of org.odmg.Database.bind()

        Transaction tx = odmg.newTransaction();
        tx.begin();
        try
        {
            db.bind(example, bindingName);
            Article value = (Article) db.lookup(bindingName);
            assertTrue("Could not lookup object for binding name: "+bindingName, value != null);
            tx.commit();
        }
        catch (ObjectNameNotFoundException ex)
View Full Code Here

Examples of org.odmg.OQLQuery.bind()

        tx.commit();

        tx.begin();
        OQLQuery query = odmg.newOQLQuery();
        query.create("select shops from " + Shop.class.getName() + " where name like $1");
        query.bind(name + "%");
        Collection result = (Collection) query.execute();

        assertEquals(2, result.size());

        query = odmg.newOQLQuery();
View Full Code Here

Examples of org.omg.CosNaming.NamingContext.bind()

                namingCtx.resolve(new NameComponent[] {finalName});
                // no exception means that some object is already registered
                // under this name, we need to crash here
                throw new CorbaHostException(CorbaHostException.BINDING_IN_USE);
            } catch (NotFound e) {
                namingCtx.bind(new NameComponent[] {finalName}, servantObject);
                registerURI(uri);
            }
        } catch (CorbaHostException e) {
            throw e;
        } catch (Exception e) {
View Full Code Here

Examples of org.omg.CosNaming.NamingContextExt.bind()

            {
                NamingContextExt nc =
        NamingContextExtHelper.narrow(orb.resolve_initial_references("NameService"));
                NameComponent [] name = new NameComponent[1];
                name[0] = new NameComponent( "TransactionService", "service");
                nc.bind(name, transactionService.get_reference());
            }
            if (logger.isInfoEnabled())
                logger.info("TransactionService up");
        }
        catch ( Exception e )
View Full Code Here

Examples of org.perl6.nqp.io.AsyncServerSocketHandle.bind()

        task.schedulee = schedulee;

        AsyncServerSocketHandle handle = new AsyncServerSocketHandle(tc);
        task.handle = handle;

        handle.bind(tc, host, (int) port);
        handle.accept(tc, task);

        return task;
    }
View Full Code Here

Examples of org.python.core.PyBuiltinCallable.bind()

    public static PyBuiltinCallable createBound(MethodExposer me) throws Exception {
        Class<?> descriptor = me.load(new BytecodeLoader.Loader());
        PyBuiltinCallable func = instantiate(descriptor, me.getNames()[0]);
        if (me instanceof ClassMethodExposer) {
            return func.bind(new SimpleExposed().getType());
        }
        return func.bind(new SimpleExposed());
    }

    public static PyBuiltinCallable instantiate(Class<?> descriptor, String name) throws Exception {
View Full Code Here

Examples of org.qi4j.dci.moneytransfer.context.PayBillsContext.bind()

        try
        {
            BalanceData source = uow.get( BalanceData.class, CHECKING_ACCOUNT_ID );

            PayBillsContext context = new PayBillsContext();
            context.bind( source ).payBills();
        }
        finally
        {
            uow.discard();
        }
View Full Code Here

Examples of org.qi4j.dci.moneytransfer.context.PayBillsContext2.bind()

        try
        {
            BalanceData source = uow.get( BalanceData.class, CHECKING_ACCOUNT_ID );

            PayBillsContext2 context = module.newObject( PayBillsContext2.class );
            context.bind( source ).payBills();
        }
        finally
        {
            uow.discard();
        }
View Full Code Here

Examples of org.qi4j.dci.moneytransfer.context.TransferMoneyContext.bind()

            BalanceData source = uow.get( BalanceData.class, SAVINGS_ACCOUNT_ID );
            BalanceData destination = uow.get( BalanceData.class, CHECKING_ACCOUNT_ID );

            // Instantiate context and execute enactments with that context
            TransferMoneyContext context = new TransferMoneyContext();
            context.bind( source, destination );

            // Query for half the balance
            final Integer amountToTransfer = context.availableFunds() / 2;

            // Transfer from savings to checking
View Full Code Here

Examples of org.qi4j.runtime.injection.InjectedFieldModel.bind()

                public boolean visitEnter( Object visited ) throws BindingException
                {
                    if( visited instanceof InjectedFieldModel )
                    {
                        InjectedFieldModel fieldModel = (InjectedFieldModel) visited;
                        fieldModel.bind( resolution.forField( fieldModel.field() ) );
                        return false;
                    } else if( visited instanceof Binder )
                    {
                        Binder constructorsModel = (Binder) visited;
                        constructorsModel.bind( resolution );
View Full Code Here
TOP
Copyright © 2015 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.