Interface Scope


public interface Scope
The disposal list of an application, window or view scope, for what is not a bean.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns whether this scope is closed.
    void
    Registers a resource to close when this scope closes.
    Returns the scope this one is nested in, if any.
  • Method Details

    • parent

      Optional<Scope> parent()
      Returns the scope this one is nested in, if any.
      Returns:
      the scope this one is nested in, if any
    • onClose

      void onClose(AutoCloseable resource)
      Registers a resource to close when this scope closes. Resources are closed in reverse order of registration.
      Parameters:
      resource - the resource to close
    • isClosed

      boolean isClosed()
      Returns whether this scope is closed.
      Returns:
      whether this scope is closed