public MiHomeManager( IMiCommunicationFactory communicationFactory, IDevicesKeeper devicesKeeper, ITokenKeeper tokenKeeper, IDevicesMap devicesMap, IKeyGeneratorFactory keyGeneratorFactory) { _devicesKeeper = devicesKeeper; _tokenKeeper = tokenKeeper; _devicesMap = devicesMap; var keyGenerator = keyGeneratorFactory.Build(_devicesMap, _tokenKeeper); _communication = communicationFactory.Build(CommandListener, keyGenerator); }
public KeyGenerator(IDevicesMap map, ITokenKeeper tokenKeeper, IGatewayPasswordKeeper passwordKeeper) { _map = map; _tokenKeeper = tokenKeeper; _passwordKeeper = passwordKeeper; }
public IKeyGenerator Build(IDevicesMap map, ITokenKeeper tokenKeeper) { return(new KeyGenerator(map, tokenKeeper, _passwordKeeper)); }