public HostHandlerModule(NetworkInterfaceCard communicationModule, ContainerTable containerTable, ILoadManager loadManager) { MachineId = communicationModule.MachineId; ContainerTable = containerTable; LoadManager = loadManager; CommunicationModule = communicationModule; }
private static bool LoadModel(FileWithParam fwp) { Type type = typeof(clss.model.packet); XmlRootAttribute xRoot = new XmlRootAttribute() { ElementName = type.Name, IsNullable = true }; XmlSerializer xSer = new XmlSerializer(type, xRoot); TextReader reader = null; if (!GetTextViaXmlDocument(fwp, type.Name, out reader)) { return(false); } try { ILoadManager ilmngr = xSer.Deserialize(reader) as clss.model.packet; return(Load(ilmngr)); } catch (Exception ex) { Log.write(ex.Message); return(false); } finally { reader.Close(); } }
public Agency(ILoadManager man) { Name = man.ReadLine().Split(':')[1]; Phone = man.ReadLine().Split(':')[1]; Adress = man.ReadLine().Split(':')[1]; }
/// <summary> /// Загрузка объекта /// </summary> private static bool Load(ILoadManager ilmngr) { if (ilmngr == null) { return(false); } return(ilmngr.Load()); }
public LoadBalancerService(IEndpointWatcher watcher, IOptions <BalancerOptions> options, ILogger <LoadBalancerService> logger, ILoadManager loadManager) { _watcher = watcher; _options = options.Value; _logger = logger; _loadManager = loadManager; }
public Object1(ILoadManager man) { TypeOfProperty = man.ReadLine().Split(':')[1]; PriceObject = man.ReadLine().Split(':')[1]; District = man.ReadLine().Split(':')[1]; Street = man.ReadLine().Split(':')[1]; NumberHouse = man.ReadLine().Split(':')[1]; NumberApartament = man.ReadLine().Split(':')[1]; AreaObject = man.ReadLine().Split(':')[1]; NumberRoom = man.ReadLine().Split(':')[1]; Details = man.ReadLine().Split(':')[1]; Time = man.ReadLine().Split(':')[1]; }
public HostMachine(int id, Load maxLoad, NetworkSwitch networkSwitch, LoadPrediction currentLoadPrediction, Strategies strategy, ContainersType containerType, SimulationSize simulationSize) : base(id, networkSwitch) { if (containerType == ContainersType.D) { _containerTable = new DockerContainerTable(id, new ImageManager(this.CommunicationModule)); } else { _containerTable = new ContainerTable(id); } _loadManager = new HostLoadManager(this.MachineId, maxLoad, currentLoadPrediction, this.CommunicationModule, _containerTable); switch (strategy) { case Strategies.WAshraf2017Auction: _handler = new WAshrafHostHandlerModule(CommunicationModule, _containerTable, _loadManager); break; case Strategies.WAshraf2017: _handler = new WAshrafHostHandlerModule(CommunicationModule, _containerTable, _loadManager); break; case Strategies.Zhao: _handler = new ZhaoHostHandler(CommunicationModule, _containerTable, _loadManager, Global.CommonLoadManager); break; case Strategies.ForsmanPush: _handler = new ForsmanHostHandler(CommunicationModule, _containerTable, _loadManager, StrategyActionType.PushAction, simulationSize); break; case Strategies.ForsmanPull: _handler = new ForsmanHostHandler(CommunicationModule, _containerTable, _loadManager, StrategyActionType.PullAction, simulationSize); break; case Strategies.Proposed2018: _handler = new ProposedHostHandlerModule(CommunicationModule, _containerTable, _loadManager); break; default: throw new ArgumentOutOfRangeException(nameof(strategy), strategy, null); } }
public TypeOfAnimal(ILoadManager man) { Name = man.ReadLine().Split(':')[1];; daily_feed_intake = float.Parse(man.ReadLine().Split(':')[1]); continent_habitat = man.ReadLine().Split(':')[1];; if (continent_habitat == "Южная Америка" || continent_habitat == "Африка" || continent_habitat == "Австралия") { Heat = true; } else { Heat = false; } }
public IReadableObject Load(ILoadManager man) { return(new Owner(man)); }
void Awake() { Instance = this; //1、加载IABManifest StartCoroutine(IABManifestLoader.Instance.LoadManifest()); }
protected PushPullHostHandler(NetworkInterfaceCard communicationModule, ContainerTable containerTable, ILoadManager loadManager) : base(communicationModule, containerTable, loadManager) { }
public IReadableObject Load(ILoadManager man) { return(new Agency(man)); }
public ForsmanHostHandler(NetworkInterfaceCard communicationModule, ContainerTable containerTable, ILoadManager loadManager, StrategyActionType currentActionType, SimulationSize simulationSize) : base(communicationModule, containerTable, loadManager) { _currentActionType = currentActionType; SimulationSize = simulationSize; MaxUtilization = Global.OtherMaxUtilization; MinUtilization = Global.OtherMinUtilization; }
public IReadbleObject Load(ILoadManager man) { return(new FamilyOfAnimals(man)); }
public void SetDependencies(SceneTypeEnum sceneType, ILoadManager loadManager) { _loadManager = loadManager; SceneType = sceneType; }
private FamilyOfAnimals(ILoadManager man) { family_name = man.ReadLine().Split(':')[1]; Population = int.Parse(man.ReadLine().Split(':')[1]); }
private Student(ILoadManager man) { name = man.ReadLine().Split(':')[1]; group = man.ReadLine().Split(':')[1]; }
void Start() { _publisher = new Publisher(); _saveManager = new SaveManager(); _animaManager = new AnimaManager(); _objectLoader = new ObjectLoader(); _configurateManager = new ConfigurateManager(); _objectStorage = new ObjectStorage(_objectLoader,_configurateManager); _tokenRewardManager = new TokenRewardManager(_publisher, _animaManager, _objectStorage,_configurateManager); _audioManager = new AudioManager(_objectStorage, _coroutiner); _barsPlayerManager = new BarsPlayerManager(_objectStorage); _inventoryManager = new InventoryManager(_objectStorage, _publisher, _coroutiner,_configurateManager); _gameStageManager = new GameStageManager(_publisher, _coroutiner); _gameManager = new GameManager(_publisher, _animaManager, _objectStorage, _coroutiner,_inventoryManager,_configurateManager); _enemyManager = new EnemyManager(_publisher, _coroutiner,_animaManager,_objectStorage, _configurateManager); _alliesManager = new AlliesManager(_coroutiner, _configurateManager); _playersManager = new PlayersManager(_publisher,_animaManager, _tokenRewardManager); _barsEnemyManager = new BarsEnemyManager(_enemyManager, _publisher); _activateCardManager = new ActivateCardManager(_publisher, _barsPlayerManager,_enemyManager); _targetManager = new TargetManager(_publisher, _animaManager, _activateCardManager, _enemyManager); _deckManager = new DeckManager(_objectStorage,_inventoryManager,_animaManager,_publisher,_coroutiner, _targetManager,_configurateManager); _popupEvent = new PopupEvent(_objectStorage,_publisher,_animaManager,_coroutiner, _configurateManager); _popupGameMenu = new PopupGameMenu(_objectStorage, _publisher, _animaManager,_coroutiner); _popupInventory = new PopupInventory(_inventoryManager, _animaManager); _popupPlaceInSlot = new PopupPlaceInSlot(_publisher); _popupPlayers = new PopupPlayers(_animaManager, _objectStorage, _publisher, _configurateManager); //_descriptionCardPopup = new PopupDescriptionCard(_popupDescriptionCard); _popupDescriptionCard = new PopupDescriptionCard(_coroutiner,_animaManager); _popupRewardEvent = new PopupRewardEvent(_publisher, _objectStorage, _configurateManager, _coroutiner); _publisher.AddSubscriber((ISubscriber) _gameManager); _publisher.AddSubscriber((ISubscriber) _inventoryManager); _publisher.AddSubscriber((ISubscriber) _gameStageManager); _publisher.AddSubscriber((ISubscriber) _activateCardManager); _publisher.AddSubscriber((ISubscriber) _barsPlayerManager); _publisher.AddSubscriber((ISubscriber) _barsEnemyManager); _publisher.AddSubscriber((ISubscriber) _enemyManager); _publisher.AddSubscriber((ISubscriber) _alliesManager); _publisher.AddSubscriber((ISubscriber) _playersManager); _publisher.AddSubscriber((ISubscriber) _deckManager); _publisher.AddSubscriber((ISubscriber) _targetManager); _publisher.AddSubscriber((ISubscriber) _audioManager); _publisher.AddSubscriber((ISubscriber) _tokenRewardManager); _publisher.AddSubscriber((ISubscriber) _popupGameMenu); _publisher.AddSubscriber((ISubscriber) _popupInventory); _publisher.AddSubscriber((ISubscriber) _popupEvent); _publisher.AddSubscriber((ISubscriber) _popupPlayers); _publisher.AddSubscriber((ISubscriber) _popupDescriptionCard); _publisher.AddSubscriber((ISubscriber) _popupRewardEvent); _publisher.AddSubscriber((ISubscriber) _popupPlaceInSlot); _baseManagers = new BaseManagers(_saveManager,_animaManager,_publisher,_objectStorage,_configurateManager,_coroutiner, _audioManager); _gameManagers = new GameManagers(_gameManager, _activateCardManager, _barsPlayerManager, _barsEnemyManager, _enemyManager, _alliesManager, _playersManager, _deckManager, _inventoryManager, _targetManager, _tokenRewardManager); _popupManagers = new PopupManagers(_popupGameMenu,_popupInventory, _popupEvent, _popupPlayers, _popupDescriptionCard,_popupPlaceInSlot, _popupRewardEvent); _logicManager = new LogicManager(_baseManagers,_gameManagers, _popupManagers); _loadManager = new LoadManager(_logicManager); //-------------------Делаем переход в сцену "Меню" _loadManager.Navigate(SceneTypeEnum.Bootstrapper, SceneTypeEnum.Menu, CustomObject.Empty); }
public Owner(ILoadManager man) { FIO = man.ReadLine().Split(':')[1]; phone = man.ReadLine().Split(':')[1]; }
public Lodger(ILoadManager man) { Name = man.ReadLine().Split(':')[1]; Phone = man.ReadLine().Split(':')[1]; }
public ZhaoHostHandler(NetworkInterfaceCard communicationModule, ContainerTable containerTable, ILoadManager loadManager, CommonLoadManager commonLoadManager) : base(communicationModule, containerTable, loadManager) { _commonLoadManager = commonLoadManager; }
public ProposedHostHandlerModule(NetworkInterfaceCard communicationModule, ContainerTable containerTable, ILoadManager loadManager) : base(communicationModule, containerTable, loadManager) { MinUtilization = Global.MinUtilization; MaxUtilization = Global.MaxUtilization; }
public IReadbleObject Load(ILoadManager man) { return(new TypeOfAnimal(man)); }
public IReadbleObject Load(ILoadManager man) { return(new Student(man)); }
public State(ILoadManager loadManager, ILimits limits) { this.loadManager = loadManager; this.limits = limits; }