@SPI
public final class ContextSpec
extends java.lang.Object
The spec includes the values required to build a BoundedContext
.
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
int |
hashCode() |
boolean |
isMultitenant()
Checks if the context is multitenant or not.
|
static ContextSpec |
multitenant(java.lang.String name)
Creates a spec of a multitenant context with the given name.
|
io.spine.core.BoundedContextName |
name()
Obtains the context name.
|
static ContextSpec |
singleTenant(java.lang.String name)
Creates a spec of a single tenant context with the given name.
|
ContextSpec |
toSingleTenant()
Returns a single-tenant version of this instance, if it is multitenant, or
this instance if it is single-tenant.
|
java.lang.String |
toString() |
public static ContextSpec singleTenant(java.lang.String name)
public static ContextSpec multitenant(java.lang.String name)
public io.spine.core.BoundedContextName name()
public boolean isMultitenant()
public ContextSpec toSingleTenant()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object