Class StartableContainer<T extends org.testcontainers.containers.GenericContainer<?>>

java.lang.Object
io.quarkus.devservices.common.StartableContainer<T>
Type Parameters:
T - the type of the container
All Implemented Interfaces:
io.quarkus.deployment.builditem.Startable, Closeable, AutoCloseable

public class StartableContainer<T extends org.testcontainers.containers.GenericContainer<?>> extends Object implements io.quarkus.deployment.builditem.Startable
A wrapper for a GenericContainer that implements the Startable interface.
  • Constructor Details

    • StartableContainer

      public StartableContainer(T container)
    • StartableContainer

      public StartableContainer(T container, Function<T,String> connectionInfoFunction)
  • Method Details

    • start

      public void start()
      Specified by:
      start in interface io.quarkus.deployment.builditem.Startable
    • getConnectionInfo

      public String getConnectionInfo()
      Specified by:
      getConnectionInfo in interface io.quarkus.deployment.builditem.Startable
    • getContainer

      public T getContainer()
    • getContainerId

      public String getContainerId()
      Specified by:
      getContainerId in interface io.quarkus.deployment.builditem.Startable
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable