类 ContainerConnectionSource<C extends org.testcontainers.containers.Container<?>>
java.lang.Object
org.springframework.boot.testcontainers.service.connection.ContainerConnectionSource<C>
- 类型参数:
C- the generic container type
- 所有已实现的接口:
OriginProvider
public final class ContainerConnectionSource<C extends org.testcontainers.containers.Container<?>>
extends Object
implements OriginProvider
Passed to
ContainerConnectionDetailsFactory to provide details of the
@ServiceConnection annotated Container that provides
the service.- 从以下版本开始:
- 3.1.0
- 作者:
- Moritz Halbritter, Andy Wilkinson, Phillip Webb
- 另请参阅:
-
方法概要
-
方法详细资料
-
accepts
public boolean accepts(String requiredConnectionName, Class<?> requiredContainerType, Class<?> requiredConnectionDetailsType) Return if this source accepts the given connection.- 参数:
requiredConnectionName- the required connection name ornullrequiredContainerType- the required container typerequiredConnectionDetailsType- the required connection details type- 返回:
- if the connection is accepted by this source
- 从以下版本开始:
- 3.4.0
-
getOrigin
从接口复制的说明:OriginProviderReturn the source origin ornullif the origin is not known.- 指定者:
getOrigin在接口中OriginProvider- 返回:
- the origin or
null
-
toString
-