public ScriptExecutionService(
            ITargetService targetService,
            ICredentialService credentialService,
            IVariableService variableService,
            ITargetCommandSender targetCommandSender,
            IScriptRunner scriptRunner)
        {
            if (targetService == null)
            {
                throw new ArgumentNullException("targetService");
            }
            _targetService = targetService;

            if (credentialService == null)
            {
                throw new ArgumentNullException("credentialService");
            }
            _credentialService = credentialService;

            if (targetCommandSender == null)
            {
                throw new ArgumentNullException("targetCommandSender");
            }
            _targetCommandSender = targetCommandSender;

            if (scriptRunner == null)
            {
                throw new ArgumentNullException("scriptRunner");
            }
            _scriptRunner = scriptRunner;
        }
 public async Task <Application?> GetApplicationAsync(
     [Parent] VariableValue value,
     [Service] IVariableService variableService,
     IApplicationDataLoader applicationById,
     CancellationToken cancellationToken)
 => value.Key.ApplicationId is
 {
Пример #3
0
        /// <summary>
        /// Initializes a new instance of the <see cref="CollisionService" /> class.
        /// </summary>
        /// <param name="entityService">The entity service.</param>
        /// <param name="mapService">The map service.</param>
        /// <param name="renderService">The render service.</param>
        /// <param name="varService">The variable service.</param>
        public CollisionService(IEntityService entityService, IMapService mapService, IRenderService renderService, IVariableService varService)
        {
            if (entityService == null)
            {
                throw new ArgumentNullException(nameof(entityService));
            }

            if (mapService == null)
            {
                throw new ArgumentNullException(nameof(mapService));
            }

            if (renderService == null)
            {
                throw new ArgumentNullException(nameof(renderService));
            }

            if (varService == null)
            {
                throw new ArgumentNullException(nameof(varService));
            }

            _entityService = entityService;
            _mapService    = mapService;
            _renderService = renderService;
            _varService    = varService;

            _quadPool    = new QuadtreePool();
            _entListPool = new ObjectPool <List <GameEntity> >(() => new List <GameEntity>(10));

            _varShowTracelines = _varService.GetVar <bool>("r_showtracelines");
        }
Пример #4
0
 public async Task <IEnumerable <VariableValue> > GetVariableValuesAsync(
     [Service] IVariableService service,
     [Parent] Application application,
     CancellationToken cancellationToken)
 {
     return(await service.GetValuesByApplicationAsync(application.Id, cancellationToken));
 }
Пример #5
0
 public ExtractVariableVisitor(
     IDomainItemLocator domainItemLocator,
     IVariableService variableService)
 {
     m_domainItemLocator = domainItemLocator;
     m_variableService   = variableService;
 }
Пример #6
0
 public StateMachineService(IBotFlowService botFlowService, IVariableService variableService,
                            IComparisonService comparisonService)
 {
     _variableService   = variableService;
     _comparisonService = comparisonService;
     _botFlowService    = botFlowService;
 }
 //TODO: Global Data y Data Rerence tienen que estar en un controlador base
 public VariableController(IVariableService service, ISpartan_Bitacora_SQLService bitacoraService)
 {
     this.service     = service;
     serviceBitacora  = bitacoraService;
     baseApi          = ConfigurationManager.AppSettings["DBBaseURL"].ToString();
     ApiControllerUrl = "api/Variable";
 }
Пример #8
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Ring" /> class.
        /// </summary>
        /// <param name="varService">The variable service.</param>
        /// <param name="resourceService">The resource service.</param>
        /// <param name="audioService">The audio service.</param>
        public Ring(IVariableService varService, IResourceService resourceService, IAudioService audioService, IEntityService entityService)
            : base(varService, resourceService)
        {
            if (varService == null)
            {
                throw new ArgumentNullException(nameof(varService));
            }

            if (resourceService == null)
            {
                throw new ArgumentNullException(nameof(resourceService));
            }

            if (audioService == null)
            {
                throw new ArgumentNullException(nameof(audioService));
            }

            if (entityService == null)
            {
                throw new ArgumentNullException(nameof(entityService));
            }

            _variableService = varService;
            _entityService   = entityService;
            _audioService    = audioService;
            _resourceService = resourceService;

            _resourceService.PreloadResource <Sprite>("ring");
            _resourceService.PreloadResource <Sound>("ring");

            _killTime = 0.0;
        }
Пример #9
0
 public CalculationVisitor(
     IDomainItemLocator domainItemLocator,
     IVariableService variableService)
 {
     m_domainItemLocator = domainItemLocator;
     m_variableService   = variableService;
 }
Пример #10
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Bridge" /> class.
        /// </summary>
        /// <param name="entityService">The entity service.</param>
        /// <param name="resourceService">The resource service.</param>
        /// <param name="variableService">The variable service.</param>
        /// <param name="collisionService">The collision service.</param>
        public Bridge(IEntityService entityService, IResourceService resourceService, IVariableService variableService, ICollisionService collisionService)
        {
            if (entityService == null)
            {
                throw new ArgumentNullException(nameof(entityService));
            }

            if (resourceService == null)
            {
                throw new ArgumentNullException(nameof(resourceService));
            }

            if (variableService == null)
            {
                throw new ArgumentNullException(nameof(variableService));
            }

            if (collisionService == null)
            {
                throw new ArgumentNullException(nameof(collisionService));
            }

            _collisionService = collisionService;
            _variableService  = variableService;
            _entityService    = entityService;
            _resourceService  = resourceService;

            _resourceService.PreloadResource <Sprite>("bridgelog");

            _depressionFactor = 0.0;
            _standIndex       = 4;
        }
        public ProjectService(IUnitOfWorkFactory unitOfWorkFactory,
                              ITargetGroupEnvironmentService targetGroupEnvironmentService,
                              IVariableService variableService,
                              IDeploymentPlanStepService deploymentPlanStepService,
                              IProjectTargetService projectTargetService)
            : base(unitOfWorkFactory)
        {
            if (targetGroupEnvironmentService == null)
            {
                throw new ArgumentNullException("targetGroupEnvironmentService");
            }
            _targetGroupEnvironmentService = targetGroupEnvironmentService;

            if (variableService == null)
            {
                throw new ArgumentNullException("variableService");
            }
            _variableService = variableService;

            if (deploymentPlanStepService == null)
            {
                throw new ArgumentNullException("deploymentPlanStepService");
            }
            _deploymentPlanStepService = deploymentPlanStepService;

            if (projectTargetService == null)
            {
                throw new ArgumentNullException("projectTargetService");
            }
            _projectTargetService = projectTargetService;
        }
Пример #12
0
 public UnknownTypeValidator(
     IDomainItemLocator domainItemLocator,
     IVariableService variableService)
 {
     m_domainItemLocator = domainItemLocator;
     m_variableService   = variableService;
 }
Пример #13
0
        /// <summary>
        /// Initializes a new instance of the <see cref="MonitorPowerup" /> class.
        /// </summary>
        /// <param name="variableService">The variable service.</param>
        /// <param name="resourceService">The resource service.</param>
        /// <param name="entityService">The entity service.</param>
        public MonitorPowerup(IVariableService variableService, IResourceService resourceService, IEntityService entityService, IAudioService audioService)
            : base(variableService, resourceService)
        {
            if (resourceService == null)
            {
                throw new ArgumentNullException(nameof(resourceService));
            }

            if (variableService == null)
            {
                throw new ArgumentNullException(nameof(variableService));
            }

            if (entityService == null)
            {
                throw new ArgumentNullException(nameof(entityService));
            }

            if (audioService == null)
            {
                throw new ArgumentNullException(nameof(audioService));
            }

            _audioService    = audioService;
            _entityService   = entityService;
            _variableService = variableService;
            _resourceService = resourceService;
            _resourceService.PreloadResource <Sprite>("mpowerup");

            _resourceService.PreloadResource <Sound>("ring");
        }
Пример #14
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Spring" /> class.
        /// </summary>
        /// <param name="variableService">The variable service.</param>
        /// <param name="resourceService">The resource service.</param>
        public Spring(IVariableService variableService, IResourceService resourceService, IAudioService audioService)
            : base(variableService, resourceService)
        {
            if (resourceService == null)
            {
                throw new ArgumentNullException(nameof(resourceService));
            }

            if (variableService == null)
            {
                throw new ArgumentNullException(nameof(variableService));
            }

            if (audioService == null)
            {
                throw new ArgumentNullException(nameof(audioService));
            }

            _variableService = variableService;
            _resourceService = resourceService;
            _audioService    = audioService;

            _resourceService.PreloadResource <Sprite>("spring");
            _resourceService.PreloadResource <Sound>("spring");

            _springType = SpringType.Red;
            _isOpen     = false;
        }
Пример #15
0
 public async Task <IEnumerable <VariableValue> > GetValuesAsync(
     [Service] IVariableService service,
     [Parent] Variable variable,
     CancellationToken cancellationToken)
 => await service.GetValuesAsync(
     variable,
     new VariableValueFilter(variable.Id),
     false,
     cancellationToken);
Пример #16
0
        /// <summary>
        /// Initializes a new instance of the <see cref="SonicCamera" /> class.
        /// </summary>
        /// <param name="varService">The variable service.</param>
        public SonicCamera(IVariableService varService)
        {
            if (varService == null)
            {
                throw new ArgumentNullException(nameof(varService));
            }

            _varService = varService;
        }
Пример #17
0
 public DeploymentJobsController(IDeploymentJobService service, IVariableService variableService)
     : base(service, isDeleteEnabled: false)
 {
     if (variableService == null)
     {
         throw new ArgumentNullException("variableService");
     }
     _variableService = variableService;
 }
Пример #18
0
 public AddCargoBorderViewModel(ICargoService cargoService, IVariableService variableService, ICargoBorderService cargoBorderService)
 {
     this.cargoService       = cargoService;
     this.variableService    = variableService;
     this.cargoBorderService = cargoBorderService;
     LoadCommands();
     LoadData();
     Messenger.Default.Register <Cargo>(this, HandleCargoMessage);
 }
Пример #19
0
 public async Task <Variable> CreateVariableAsync(
     [Service] IVariableService variableService,
     string name,
     bool isSecret,
     string? @namespace,
     string?defaultValue,
     CancellationToken cancellationToken)
 => await variableService
 .CreateAsync(name, @namespace, isSecret, defaultValue, cancellationToken);
        public BusquedaVariableServiceUnitTest()
        {
            this.componentContainer = new ComponentContainer();

            this.componentContainer.Register <IVariableService, VariableService>();
            this.componentContainer.Register <IListaLinealService, ListaLinealService>();

            this.iVariableService    = componentContainer.Resolve <IVariableService>();
            this.iListaLinealService = componentContainer.Resolve <IListaLinealService>();
        }
Пример #21
0
        /// <summary>
        /// Initializes a new instance of the <see cref="RenderService"/> class.
        /// </summary>
        /// <param name="engine">The game engine.</param>
        public RenderService(IVariableService variableService)
        {
            if (variableService == null)
            {
                throw new ArgumentNullException(nameof(variableService));
            }

            _variableService = variableService;
            _renderables     = new LinkedList <Renderable>();
        }
Пример #22
0
 public void Init()
 {
     cargoService       = new CargoService(LoggedUser.Username, LoggedUser.Password);
     cargoBorderService = new CargoBorderService(LoggedUser.Username, LoggedUser.Password);
     employeeService    = new EmployeeService(LoggedUser.Username, LoggedUser.Password);
     exceedingsService  = new ExceedingsPerCargoService(LoggedUser.Username, LoggedUser.Password);
     logService         = new LogService(LoggedUser.Username, LoggedUser.Password);
     sensorDataService  = new SensorDataService(LoggedUser.Username, LoggedUser.Password);
     sensorService      = new SensorService(LoggedUser.Username, LoggedUser.Password);
     variableService    = new VariableService(LoggedUser.Username, LoggedUser.Password);
 }
Пример #23
0
 public DataController(
     ILogger <DataController> logger,
     IStationService stationService,
     IStationDataService stationDataService,
     IPublicService publicService,
     IVariableService variableService)
 {
     _logger             = logger;
     _stationService     = stationService;
     _stationDataService = stationDataService;
     _publicService      = publicService;
     _variableService    = variableService;
 }
Пример #24
0
 public StateMachine(IBotFlowService botFlowService,
                     IUserSemaphoreService userSemaphoreService,
                     IVariableService variableService,
                     ICustomActionService customActionService,
                     IStateMachineService stateMachineService,
                     INlpProvider nlpProvider)
 {
     _botFlowService       = botFlowService;
     _userSemaphoreService = userSemaphoreService;
     _variableService      = variableService;
     _stateMachineService  = stateMachineService;
     _customActionService  = customActionService;
     _nlpProvider          = nlpProvider;
 }
 public BuildDefinitionService(IAzureClient azureClient,
                               IVariableGroupService variableGroupService,
                               ITaskGroupService taskGroupService,
                               IVariableService variableService,
                               ITriggersService triggersService,
                               ITagsService tagsService)
 {
     _azureClient          = azureClient;
     _variableGroupService = variableGroupService;
     _taskGroupService     = taskGroupService;
     _variableService      = variableService;
     _triggersService      = triggersService;
     _tagsService          = tagsService;
 }
Пример #26
0
    public async Task <IEnumerable <VariableValue> > GetVariableValuesAsync(
        [Service] IVariableService variableService,
        [ID(nameof(Variable))] Guid variableId,
        [ID(nameof(Application))] Optional <Guid?> applicationId,
        [ID(nameof(ApplicationPart))] Optional <Guid?> applicationPartId,
        CancellationToken cancellationToken)
    {
        VariableValueFilter filter = new(variableId)
        {
            ApplicationId = applicationId,
            PartId        = applicationPartId
        };

        return(await variableService.GetValuesAsync(filter, false, cancellationToken));
    }
Пример #27
0
        /// <summary>
        /// Initializes a new instance of the <see cref="SpindashDust"/> class.
        /// </summary>
        /// <param name="varService">The variable service.</param>
        /// <param name="resourceService">The resource service.</param>
        public SpindashDust(IVariableService varService, IResourceService resourceService)
            : base(varService, resourceService)
        {
            if (resourceService == null)
            {
                throw new ArgumentNullException(nameof(resourceService));
            }

            if (varService == null)
            {
                throw new ArgumentNullException(nameof(varService));
            }

            _resourceService = resourceService;
            _resourceService.PreloadResource <Sprite>("spindashsmoke");
        }
Пример #28
0
 public async Task <VariableValue> SaveVariableValueAsync(
     [Service] IVariableService variableService,
     [ID(nameof(Variable))] Guid variableId,
     string value,
     [ID(nameof(VariableValue))] Guid?valueId,
     [ID(nameof(Application))] Guid?applicationId,
     [ID(nameof(ApplicationPart))] Guid?partId,
     [ID(nameof(Environment))] Guid?environmentId,
     CancellationToken cancellationToken)
 => await variableService.SaveValueAsync(variableId,
                                         value,
                                         valueId,
                                         applicationId,
                                         partId,
                                         environmentId,
                                         cancellationToken);
Пример #29
0
        /// <summary>
        /// Initializes a new instance of the <see cref="PlayerMoveController" /> class.
        /// </summary>
        /// <param name="player">The player entity to control.</param>
        /// <param name="collisionService">The collision service.</param>
        /// <param name="varService">The variable service.</param>
        /// <param name="inputService">The input service.</param>
        /// <param name="audioService">The audio service.</param>
        public PlayerMoveController(Player player, ICollisionService collisionService, IVariableService varService, IInputService inputService, IAudioService audioService)
            : base(player)
        {
            if (collisionService == null)
            {
                throw new ArgumentNullException(nameof(collisionService));
            }

            if (varService == null)
            {
                throw new ArgumentNullException(nameof(varService));
            }

            if (inputService == null)
            {
                throw new ArgumentNullException(nameof(inputService));
            }

            if (audioService == null)
            {
                throw new ArgumentNullException(nameof(audioService));
            }

            _player = player;

            _audioService     = audioService;
            _inputService     = inputService;
            _varService       = varService;
            _collisionService = collisionService;

            _falling         = true;
            _rolling         = false;
            _jumping         = false;
            _pushing         = false;
            _turning         = false;
            _lookingUp       = false;
            _allowJump       = true;
            _controlsEnabled = true;

            _gravity = DefaultGravity;

            _controlLockTime = 0.0;
            _gsp             = 0.0;
        }
Пример #30
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Spikes"/> class.
        /// </summary>
        /// <param name="varService">The variable service.</param>
        /// <param name="resourceService">The resource service.</param>
        public Spikes(IVariableService varService, IResourceService resourceService)
            : base(varService, resourceService)
        {
            if (varService == null)
            {
                throw new ArgumentNullException(nameof(varService));
            }

            if (resourceService == null)
            {
                throw new ArgumentNullException(nameof(resourceService));
            }

            _resourceService = resourceService;
            _resourceService.PreloadResource <Sprite>("spikes");
            _direction = Direction.Up;

            Options  |= EntityOptions.Collidable;
            SolidType = SolidType.FullSolid;
        }
        public ScriptExecutionService(
            ITargetService targetService,
            ICredentialService credentialService,
            IVariableService variableService,
            ITargetCommandSender targetCommandSender,
            IScriptRunner scriptRunner)
        {
            if (targetService == null)
                throw new ArgumentNullException("targetService");
            _targetService = targetService;

            if (credentialService == null)
                throw new ArgumentNullException("credentialService");
            _credentialService = credentialService;

            if (targetCommandSender == null)
                throw new ArgumentNullException("targetCommandSender");
            _targetCommandSender = targetCommandSender;

            if (scriptRunner == null)
                throw new ArgumentNullException("scriptRunner");
            _scriptRunner = scriptRunner;
        }
        public DeploymentJobExecutionService(
            IDeploymentJobService deploymentJobService,
            IDeploymentJobStepService deploymentJobStepService,
            IDeploymentJobStepTargetService deploymentJobStepTargetService,
            IDeploymentPlanStepService deploymentPlanStepService,
            ITargetGroupService targetGroupService,
            ITargetGroupEnvironmentService targetGroupEnvironmentService,
            IProjectTargetService projectTargetService,
            ITargetService targetService,
            ICredentialService credentialService,
            IScriptService scriptService,
            IScriptExecutionService scriptExecutionService,
            IProjectEnvironmentService projectEnvironmentService,
            IVariableService variableService)
        {
            if (deploymentJobService == null)
                throw new ArgumentNullException("deploymentJobService");
            _deploymentJobService = deploymentJobService;

            if (deploymentJobStepService == null)
                throw new ArgumentNullException("deploymentJobStepService");
            _deploymentJobStepService = deploymentJobStepService;

            if (deploymentJobStepTargetService == null)
                throw new ArgumentNullException("deploymentJobStepTargetService");
            _deploymentJobStepTargetService = deploymentJobStepTargetService;

            if (deploymentPlanStepService == null)
                throw new ArgumentNullException("deploymentPlanStepService");
            _deploymentPlanStepService = deploymentPlanStepService;

            if (targetGroupService == null)
                throw new ArgumentNullException("targetGroupService");
            _targetGroupService = targetGroupService;

            if (targetGroupEnvironmentService == null)
                throw new ArgumentNullException("targetGroupEnvironmentService");
            _targetGroupEnvironmentService = targetGroupEnvironmentService;

            if (projectTargetService == null)
                throw new ArgumentNullException("projectTargetService");
            _projectTargetService = projectTargetService;

            if (targetService == null)
                throw new ArgumentNullException("targetService");
            _targetService = targetService;

            if (credentialService == null)
                throw new ArgumentNullException("credentialService");
            _credentialService = credentialService;

            if (scriptService == null)
                throw new ArgumentNullException("scriptService");
            _scriptService = scriptService;

            if (scriptExecutionService == null)
                throw new ArgumentNullException("scriptExecutionService");
            _scriptExecutionService = scriptExecutionService;

            if (projectEnvironmentService == null)
                throw new ArgumentNullException("projectEnvironmentService");
            _projectEnvironmentService = projectEnvironmentService;

            if (variableService == null)
                throw new ArgumentNullException("variableService");
            _variableService = variableService;
        }