public async Task <bool> RemoveConnection(string Id) { var conn = await _connectionRepository.GetById(Id); if (conn is null) { return(false); } return(await _connectionRepository.DeleteById(conn)); }
private Connection GetConnection(Guid connectionId) { var connectionInfo = _connectionRepository.GetById(connectionId); if (connectionInfo == null) { throw new ConnectionNotFoundException(); } return(connectionInfo); }
private string GetConnectionString(Guid connectionId) { var eventStoreConnection = _connectionRepository.GetById(connectionId); if (eventStoreConnection == null) { throw new EventStoreConnectionNotFoundException(); } return(eventStoreConnection.ConnectionString); }
public Connection GetById(Guid id) { return(_connectionRepository.GetById(id)); }