public interface TenantStore
extends com.google.common.util.concurrent.Service
Modifier and Type | Method and Description |
---|---|
void |
deleteTenantByName(String name)
Delete the
Tenant associated with the given name. |
List<Tenant> |
getAllTenants()
Get an immutable list of all
tenants . |
List<TenantSpecification> |
getAllTenantSpecifications()
Get an immutable list of all
TenantSpecification . |
String |
getNameForId(String id)
Get the name of the tenant that has the given id, or null if the tenant does not exist.
|
Tenant |
getTenantByID(String id)
Get the
Tenant associated with the given id or null if none exists. |
Tenant |
getTenantByName(String name)
Get the
Tenant associated with the given name or null if none exists. |
void |
writeTenant(Tenant tenant)
Write the given
Tenant to the store. |
Tenant getTenantByID(String id) throws IOException
Tenant
associated with the given id or null if none exists.id
- Id of the tenant.IOException
Tenant getTenantByName(String name) throws IOException
Tenant
associated with the given name or null if none exists.name
- Name of the tenant.IOException
List<Tenant> getAllTenants() throws IOException
tenants
.IOException
List<TenantSpecification> getAllTenantSpecifications() throws IOException
TenantSpecification
.IOException
void writeTenant(Tenant tenant) throws IOException
tenant
- Tenant to write.IOException
void deleteTenantByName(String name) throws IOException
Tenant
associated with the given name.name
- Name of the tenant to delete.IOException
String getNameForId(String id) throws IOException
id
- Id of the tenant to get the name forIOException
Copyright © 2013-2016 Cask Data, Inc. Licensed under the Apache License, Version 2.0.