Package org.picocontainer.defaults

Examples of org.picocontainer.defaults.VerifyingVisitor


   /**
    * @deprecated since 1.1 - Use new VerifyingVisitor().traverse(this)
   */
   public void verify() throws PicoVerificationException
   {
      new VerifyingVisitor().traverse(this);
   }
View Full Code Here


   /**
    * @deprecated since 1.1 - Use new VerifyingVisitor().traverse(this)
   */
   public void verify() throws PicoVerificationException
   {
      new VerifyingVisitor().traverse(this);
   }
View Full Code Here

   /**
    * @deprecated since 1.1 - Use new VerifyingVisitor().traverse(this)
   */
   public void verify() throws PicoVerificationException
   {
      new VerifyingVisitor().traverse(this);
   }
View Full Code Here

   /**
    * @deprecated since 1.1 - Use new VerifyingVisitor().traverse(this)
   */
   public void verify() throws PicoVerificationException
   {
      new VerifyingVisitor().traverse(this);
   }
View Full Code Here

   /**
    * @deprecated since 1.1 - Use new VerifyingVisitor().traverse(this)
   */
   public void verify() throws PicoVerificationException
   {
      new VerifyingVisitor().traverse(this);
   }
View Full Code Here

    public void testAggregatedVerificationException() {
        MutablePicoContainer pico = createPicoContainer(null);
        pico.registerComponentImplementation(ComponentA.class);
        pico.registerComponentImplementation(ComponentE.class);
        try {
            new VerifyingVisitor().traverse(pico);
            fail("we expect a PicoVerificationException");
        } catch (PicoVerificationException e) {
            List nested = e.getNestedExceptions();
            assertEquals(2, nested.size());
            assertTrue(-1 != e.getMessage().indexOf(ComponentA.class.getName()));
View Full Code Here

    public void testDelegationOfVerify() {
        DefaultPicoContainer mpc = new DefaultPicoContainer();
        mpc.registerComponentImplementation(Iterator.class, UnsatisfiableIterator.class);
        ImmutablePicoContainer ipc = new ImmutablePicoContainer(mpc);
        try {
            new VerifyingVisitor().traverse(ipc);;
            fail("wrong!");
        } catch (PicoVerificationException e) {
            // expected
        }
    }
View Full Code Here

    public void testHidingWithoutParameter() {
        // this was a bug reported by Arnd Kors on 21st Sept on the mail list.
        ImplementationHidingPicoContainer pico = new ImplementationHidingPicoContainer();
        pico.registerComponentImplementation(String.class);
        pico.registerComponentImplementation(Runnable.class, MyThread.class);
        new VerifyingVisitor().traverse(pico);
    }
View Full Code Here

        container.registerComponentImplementation(MockRunnable.class);
        container.registerComponentImplementation(OtherRunnable.class);
        container.registerComponentImplementation(MockRunner.class);

        // this will fail to resolve the Runnable array on the MockRunner
        VerifyingVisitor visitor = new VerifyingVisitor();
        visitor.traverse(container);

        container.start();
        assertNotNull(container.getComponentInstanceOfType(MockRunner.class));
    }
View Full Code Here

   /**
    * @deprecated since 1.1 - Use new VerifyingVisitor().traverse(this)
   */
   public void verify() throws PicoVerificationException
   {
      new VerifyingVisitor().traverse(this);
   }
View Full Code Here

TOP

Related Classes of org.picocontainer.defaults.VerifyingVisitor

Copyright © 2018 www.massapicom. 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.