Package org.jboss.arquillian.drone.spi

Examples of org.jboss.arquillian.drone.spi.Destructor.destroyInstance()


            droneLifecycleEvent.fire(new BeforeDroneDestroyed(dronePoint));

            // we need to get drone once again, at it might get modified by observers on previous event
            Object drone = context.get(dronePoint).getInstance();

            destructor.destroyInstance(drone);
        }

        if (wasInstantiated) {
            droneLifecycleEvent.fire(new AfterDroneDestroyed(dronePoint));
        }
View Full Code Here


            droneLifecycleEvent.fire(new BeforeDroneDestroyed(drone, injectionPoint));

            // we need to get drone once again, at it might get modified by observers on previous event
            drone = context.getDrone(injectionPoint);

            destructor.destroyInstance(drone);
        }

        context.removeDrone(injectionPoint);
        context.removeDroneConfiguration(injectionPoint);
View Full Code Here

            // get instance to be destroyed
            // if deployment failed, there is nothing to be destroyed
            Object instance = droneContext.get().get(typeClass, qualifier);
            if (instance != null) {
                destructor.destroyInstance(instance);
            }
            droneContext.get().remove(typeClass, qualifier);
        }
    }
View Full Code Here

                // get instance to be destroyed
                // if deployment failed, there is nothing to be destroyed
                Object instance = context.get(parameterTypes[i], qualifier);
                if (instance != null) {
                    destructor.destroyInstance(instance);
                }

                context.remove(parameterTypes[i], qualifier);
            }
        }
View Full Code Here

        try {
            destructor = registryInstance.get().getEntryFor(instanceClass, Destructor.class);
        } catch (Exception ignored) {
        }
        if (destructor != null && !destructor.getClass().equals(this.getClass())) {
            destructor.destroyInstance(instance);
        } else {
            instance.quit();
        }
    }
View Full Code Here

        try {
            destructor = registryInstance.get().getEntryFor(instanceClass, Destructor.class);
        } catch (Exception ignored) {
        }
        if (destructor != null && !destructor.getClass().equals(this.getClass())) {
            destructor.destroyInstance(instance);
        } else {
            instance.quit();
        }
    }
View Full Code Here

            // get instance to be destroyed
            // if deployment failed, there is nothing to be destroyed
            Object instance = droneContext.get(typeClass, qualifier);
            if (instance != null) {
                destructor.destroyInstance(instance);
            }
            droneContext.remove(typeClass, qualifier);
        }
    }
View Full Code Here

                // get instance to be destroyed
                // if deployment failed, there is nothing to be destroyed
                Object instance = droneMethodContext.get(parameterTypes[i], qualifier);
                if (instance != null) {
                    destructor.destroyInstance(instance);
                }

                droneMethodContext.remove(parameterTypes[i], qualifier);
            }
        }
View Full Code Here

        try {
            destructor = registryInstance.get().getEntryFor(instanceClass, Destructor.class);
        } catch (Exception ignored) {
        }
        if (destructor != null && !destructor.getClass().equals(this.getClass())) {
            destructor.destroyInstance(instance);
        }
        // this is default destructor
        else {
            instance.quit();
        }
View Full Code Here

            // get instance to be destroyed
            // if deployment failed, there is nothing to be destroyed
            Object instance = droneContext.get(typeClass, qualifier);
            if (instance != null) {
                instance = deenhance(typeClass, qualifier, instance);
                destructor.destroyInstance(instance);
            }
            droneContext.remove(typeClass, qualifier);
        }
    }
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.