All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.cookingfox.chefling.api.CheflingLifecycle Maven / Gradle / Ivy

Go to download

Chefling is a very minimal dependency injection container written in pure Java.

There is a newer version: 7.1.1
Show newest version
package com.cookingfox.chefling.api;

/**
 * This interface provides methods that hook into the container instance creation process:
 * - {@link #initialize()} is called right after an instance of the implementing class is created.
 * This is when the class's dependencies have been resolved and additional initialization operations
 * can be performed.
 * - {@link #dispose()} is called just before an instance of the implementing class is destroyed.
 * This destruction process is initiated when an instance is removed from the container. It provides
 * a hook for cleaning up instance resources before it is destroyed.
 */
public interface CheflingLifecycle {

    /**
     * Dependencies have been resolved: perform additional initialization operations.
     */
    void initialize();

    /**
     * Instance will be destroyed: perform clean-up operations.
     */
    void dispose();

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy