Package org.qi4j.api.structure

Examples of org.qi4j.api.structure.Application.passivate()


            @Override
            @SuppressWarnings( "CallToThreadDumpStack" )
            public void run()
            {
                try {
                    application.passivate();
                } catch ( Exception ex ) {
                    System.err.println( "Unable to passivate Qi4j application!" );
                    ex.printStackTrace();
                }
            }
View Full Code Here


        }
        finally
        {
            try
            {
                app.passivate();
                fail( "No PassivationException" );
            }
            catch( PassivationException ex )
            {
                ex.printStackTrace();
View Full Code Here

            UnitOfWorkFactory unitOfWorkFactory = domain;
            createABunchOfStuffAndDoQueries( unitOfWorkFactory, domain );
        }
        finally
        {
            application.passivate();
        }
    }

    @Test
    public void canCreateAndQueryWithAllInMemory()
View Full Code Here

            UnitOfWorkFactory unitOfWorkFactory = domain;
            createABunchOfStuffAndDoQueries( unitOfWorkFactory, domain );
        }
        finally
        {
            application.passivate();
        }
    }

    @Test
    public void canCreateAndQueryWithNativeRdfWithInMemoryStore()
View Full Code Here

            UnitOfWorkFactory unitOfWorkFactory = domain;
            createABunchOfStuffAndDoQueries( unitOfWorkFactory, domain );
        }
        finally
        {
            application.passivate();
        }
    }

    @Test
    public void canCreateAndQueryWithInMemoryRdfWithJdbm()
View Full Code Here

            UnitOfWorkFactory unitOfWorkFactory = domain;
            createABunchOfStuffAndDoQueries( unitOfWorkFactory, domain );
        }
        finally
        {
            application.passivate();
        }
    }

    public void createABunchOfStuffAndDoQueries( UnitOfWorkFactory unitOfWorkFactory,
                                                 QueryBuilderFactory queryBuilderFactory
View Full Code Here

                application.registerActivationEventListener( new EventsRecorder( events ) );
            }

        };
        Application application = assembler.application();
        application.passivate();

        Iterator<ActivationEvent> it = events.iterator();

        // Activation
        assertEvent( it.next(), ACTIVATING, "Application" );
View Full Code Here

        events.clear();
        application.activate();
        Module module = assembler.module();
        module.findService( TestService.class ).get().test();
        application.passivate();

        for( ActivationEvent event : events ) {
            System.out.println( event );
        }
View Full Code Here

            SomeValue someNewValue = valueSerialization.deserialize( SomeValue.class, json );
            assertThat( someNewValue, equalTo( someValue ) );
        }
        finally
        {
            app.passivate();
        }
    }

    private SomeValue someNewValueInstance( Module module )
    {
View Full Code Here

        // Assert activated
        Assert.assertEquals( "Activation Level", 2, activationLevel );

        // Passivate
        application.passivate();

        // Assert passivated
        Assert.assertEquals( "Passivation Level", 2, passivationLevel );
    }
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.