Interface ContainerRuntime

All Known Implementing Classes:
FrameworkContainerRuntime, NoContainerRuntime

@Internal public interface ContainerRuntime
The editable-slot half of the UI runtime. Internal; implemented by the chest backend item. Ownership is keyed by the opaque handle, never by its diagnostic name or SlotContainer#owner().
  • Method Details

    • create

      SlotContainer create(UiOwner owner, ContainerSpec spec, ContainerHost host)
      Creates a container for this module copy and its host. Server thread, after the service's own checks.
    • attach

      void attach(SlotContainer container, UiSession<?> session)
      session now shows container. Idempotent for a session/container pair. Server thread.
    • detach

      void detach(SlotContainer container, UiSession<?> session)
      session no longer shows container. Must tolerate an absent or partially failed attach. If the container's owner is unloading, end through the unload path using the deadline supplied to prepareUnload(UiOwner, long), never through endWhenUnviewed. Server thread.
    • engine

      GestureEngine engine()
      The engine that applies gestures to this runtime's containers.
    • prepareUnload

      void prepareUnload(UiOwner owner, long deadlineNanos)
      Unload step 2: freeze new work for this module copy and retain the shared absolute System.nanoTime deadline. All later detach/wait operations use that deadline, without restarting a timeout. Unloading thread.
    • startUnloadCommits

      void startUnloadCommits(UiOwner owner)
      Unload step 4: start changed COMMIT writes for this copy, reusing any write already in flight. Unloading thread.
    • finishUnload

      void finishUnload(UiOwner owner, long deadlineNanos)
      Unload step 6: await answers until the same deadline and end every container of this copy. Unloading thread.