Interface ResourcesContainerListener<T>

Type Parameters:
T - The type of the resource that is managed by the container.
All Superinterfaces:
EventListener, ResourcesContainerClearedListener

public interface ResourcesContainerListener<T> extends ResourcesContainerClearedListener
This listener provides callbacks to observe ResourcesContainer instances.
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    added(String resourceName, T resource)
    This method gets called after the ResourcesContainer.add method was executed.
    default void
    This method gets called after the ResourcesContainer.clear method was executed.
    default void
    removed(String resourceName, T resource)
    This method gets called after the ResourcesContainer.remove method was executed.
  • Method Details

    • added

      default void added(String resourceName, T resource)
      This method gets called after the ResourcesContainer.add method was executed.
      Parameters:
      resourceName - The name by which the added resource is identified.
      resource - The added resource.
      See Also:
    • removed

      default void removed(String resourceName, T resource)
      This method gets called after the ResourcesContainer.remove method was executed.
      Parameters:
      resourceName - The name by which the removed resource was identified.
      resource - The removed resource.
      See Also:
    • cleared

      default void cleared()
      This method gets called after the ResourcesContainer.clear method was executed. It notifies that all resources have been removed from the container.
      Specified by:
      cleared in interface ResourcesContainerClearedListener
      See Also: