Class AuthorizedHostService
- Namespace
- Dynamicweb.Headless
- Assembly
- Dynamicweb.dll
The service provides methods for fetching, adding, updating and removing authorized host data.
public sealed class AuthorizedHostService : ICacheStorage<int, AuthorizedHost>, ICacheStorage<int>, ICacheStorage
- Inheritance
-
AuthorizedHostService
- Implements
- Inherited Members
Constructors
AuthorizedHostService()
public AuthorizedHostService()
Methods
ClearCache()
Resets all keys to the default value for objects stored in the object cache
public void ClearCache()
ClearCache(IEnumerable<int>)
Resets the specified keys to the default value for objects stored in the object cache
public void ClearCache(IEnumerable<int> keys)
Parameters
keys
IEnumerable<int>Keys to reset
ClearCache(int)
Resets the specified key to the default value for objects stored in the object cache
public void ClearCache(int key)
Parameters
key
intKey to reset
Delete(int)
Delete the authorized host.
public void Delete(int authorizedHostId)
Parameters
authorizedHostId
intThe authorized host id
GetAll()
Gets all authorized hosts.
public IEnumerable<AuthorizedHost> GetAll()
Returns
GetByDomain(string)
Gets the authorized host by domain.
public AuthorizedHost? GetByDomain(string domain)
Parameters
domain
stringThe authorized host domain
Returns
GetById(int)
Gets the authorized host by id.
public AuthorizedHost? GetById(int authorizedHostId)
Parameters
authorizedHostId
intThe authorized host id
Returns
Save(AuthorizedHost)
Saves the authorized host.
public void Save(AuthorizedHost authorizedHost)
Parameters
authorizedHost
AuthorizedHostThe authorized host