Esempio n. 1
0
 public void CancelChanges(RemotingService sender, string clientAddress, string signature)
 {
     if (CancelChangesRequested != null)
         CancelChangesRequested(sender, new RemoteCommandEventArgs { IpAddress = clientAddress, Signature = signature });
 }
Esempio n. 2
0
 public void ToggleDevices(RemotingService sender, string clientAddress, string signature, IEnumerable<DeviceDescriptor> devices, bool enabled)
 {
     if (ToggleDevicesRequested != null)
         ToggleDevicesRequested(sender, devices, enabled, new RemoteCommandEventArgs { IpAddress = clientAddress, Signature = signature });
 }
Esempio n. 3
0
 public void ToggleDynamicIntensity(RemotingService sender, string clientAddress, string signature, bool enabled)
 {
     if (ToggleDynamicIntensityRequested != null)
         ToggleDynamicIntensityRequested(sender, enabled, new RemoteCommandEventArgs { IpAddress = clientAddress, Signature = signature });
 }
Esempio n. 4
0
 public void SetDevicesToCoin(RemotingService sender, string clientAddress, string signature, IEnumerable<DeviceDescriptor> devices, string coinSymbol)
 {
     if (SetDeviceToCoinRequested != null)
         SetDeviceToCoinRequested(sender, devices, coinSymbol, new RemoteCommandEventArgs { IpAddress = clientAddress, Signature = signature });
 }
Esempio n. 5
0
 public void StopMining(RemotingService sender, string clientAddress, string signature)
 {
     if (StopMiningRequested != null)
         StopMiningRequested(sender, new RemoteCommandEventArgs { IpAddress = clientAddress, Signature = signature });
 }
Esempio n. 6
0
        public void SetApplicationConfiguration(
            RemotingService sender, 
            string clientAddress, 
            string signature, 
            Data.Transfer.Configuration.Application application, 
            Data.Transfer.Configuration.Engine engine, 
            Data.Transfer.Configuration.Path path, 
            Data.Transfer.Configuration.Perks perks)
        {
            ConfigurationEventArgs ea = new ConfigurationEventArgs()
            {
                IpAddress = clientAddress,
                Signature = signature,
                Application = application,
                Engine = engine,
                Path = path,
                Perks = perks
            };

            if (SetConfigurationRequested != null)
                SetConfigurationRequested(sender, ea);
        }
Esempio n. 7
0
 public void SetAllDevicesToCoin(RemotingService sender, string clientAddress, string signature, string coinSymbol)
 {
     if (SetAllDevicesToCoinRequested != null)
         SetAllDevicesToCoinRequested(sender, coinSymbol, new RemoteCommandEventArgs { IpAddress = clientAddress, Signature = signature });
 }
Esempio n. 8
0
 public void ScanHardware(RemotingService sender, string clientAddress, string signature)
 {
     if (ScanHardwareRequested != null)
         ScanHardwareRequested(sender, new RemoteCommandEventArgs { IpAddress = clientAddress, Signature = signature });
 }
Esempio n. 9
0
        public void GetApplicationModels(
            RemotingService sender,
            string clientAddress,
            string signature,
            out IEnumerable<Data.Transfer.Device> devices,
            out IEnumerable<CryptoCoin> configurations,
            out bool mining,
            out bool hasChanges,
            out bool dynamicIntensity)
        {
            ModelEventArgs ea = new ModelEventArgs();
            ea.IpAddress = clientAddress;
            ea.Signature = signature;

            if (GetModelRequested != null)
                GetModelRequested(sender, ea);

            devices = ea.Devices;
            configurations = ea.ConfiguredCoins;
            mining = ea.Mining;
            hasChanges = ea.HasChanges;
            dynamicIntensity = ea.DynamicIntensity;
        }
Esempio n. 10
0
        public void GetApplicationConfiguration(
            RemotingService sender, 
            string clientAddress, 
            string signature, 
            out Data.Transfer.Configuration.Application application, 
            out Data.Transfer.Configuration.Engine engine, 
            out Data.Transfer.Configuration.Path path, 
            out Data.Transfer.Configuration.Perks perks)
        {
            ConfigurationEventArgs ea = new ConfigurationEventArgs();
            ea.IpAddress = clientAddress;
            ea.Signature = signature;

            if (GetConfigurationRequested != null)
                GetConfigurationRequested(sender, ea);

            application = ea.Application;
            engine = ea.Engine;
            path = ea.Path;
            perks = ea.Perks;
        }