Class ValueTenantIdResolver
- Namespace
- BytLabs.Multitenancy.Resolvers
- Assembly
- BytLabs.Multitenancy.dll
A simple tenant ID resolver that returns a predefined tenant ID value. Useful for testing or as a fallback resolver.
public class ValueTenantIdResolver : ITenantIdResolver
- Inheritance
-
ValueTenantIdResolver
- Implements
- Inherited Members
Constructors
ValueTenantIdResolver(TenantId?)
Initializes a new instance of the ValueTenantIdResolver class.
public ValueTenantIdResolver(TenantId? tenantId)
Parameters
tenantId
TenantIdThe predefined tenant ID to return.
Methods
TryGetCurrent(out TenantId?)
Attempts to get the predefined tenant ID.
public bool TryGetCurrent(out TenantId? tenantId)
Parameters
tenantId
TenantIdThe predefined tenant ID if set; otherwise, null.
Returns
- bool
true if a tenant ID was set; otherwise, false.