private IDataPolicy _CreateDataPolicy(CommandOutput output) { IDataPolicy dataPolicy = _dataPolicyFactory.CreateDataPolicy(); _AddDataPolicy(output, dataPolicy); return(dataPolicy); }
private IDataPolicy _GetDataPolicy(CommandOutput output) { lock (_outputDataPolicies) { IDataPolicy dataPolicy; _outputDataPolicies.TryGetValue(output.Id, out dataPolicy); return dataPolicy; } }
public void AddOutput(CommandOutput output) { _outputMediator.AddOutput(output); IDataFlowComponent component = _adapterFactory.GetAdapter(output); VixenSystem.DataFlow.AddComponent(component); VixenSystem.OutputControllers.AddControllerOutputForDataFlowComponent(component, this, output.Index); }
private IDataPolicy _GetDataPolicy(CommandOutput output) { lock (_outputDataPolicies) { IDataPolicy dataPolicy; _outputDataPolicies.TryGetValue(output.Id, out dataPolicy); return(dataPolicy); } }
/// <summary> /// Append a command to the list of commands for a given output controller. /// </summary> public void AddCommand(CommandOutput commandOutput) { if (!_outputStateList.ContainsKey(commandOutput.Id)) { _AddOutput(commandOutput); } _outputStateList[commandOutput.Id] = commandOutput.Command; }
private ICommand GenerateOutputCommand(CommandOutput output) { if (output.State != null) { return(_dataPolicy.GenerateCommand(output.State)); } return(null); }
public void RemoveOutput(CommandOutput output) { _outputMediator.RemoveOutput(output); IDataFlowComponent component = _adapterFactory.GetAdapter(output); VixenSystem.DataFlow.RemoveComponent(component); VixenSystem.OutputControllers.RemoveControllerOutputForDataFlowComponent(component); }
private ICommand _GenerateOutputCommand(CommandOutput output) { if (output.State != null) { IDataPolicy effectiveDataPolicy = _dataPolicyProvider.GetDataPolicyForOutput(output); return(effectiveDataPolicy.GenerateCommand(output.State)); } return(null); }
public IDataFlowComponent GetAdapter(CommandOutput output) { CommandOutputDataFlowAdapter adapter; if (!_instances.TryGetValue(output.Id, out adapter)) { adapter = new CommandOutputDataFlowAdapter(output); _instances[output.Id] = adapter; } return adapter; }
private ICommand _GenerateOutputCommand(CommandOutput output) { if (output.State != null) { var lst = output.State.Value as List <IIntentState>; IDataPolicy effectiveDataPolicy = _dataPolicyProvider.GetDataPolicyForOutput(output); return(effectiveDataPolicy.GenerateCommand(output.State)); } return(null); }
private ICommand _GenerateOutputCommand(CommandOutput output) { if (output.State != null) { IDataPolicy effectiveDataPolicy = _dataPolicyProvider.GetDataPolicyForOutput(output); ICommand command = effectiveDataPolicy.GenerateCommand(output.State); if (command != null) { List <ICommand> commands = new List <ICommand>(); commands.Add(command); CommandsDataFlowData data = new CommandsDataFlowData(commands); command = effectiveDataPolicy.GenerateCommand(data); } return(command); } return(null); }
public void SetOutput(CommandOutput output, int outputIndex) { _output = output; _outputIndex = outputIndex; _recalcControlPoints(); }
public override void CopyFrom(Shape source) { base.CopyFrom(source); if (source is OutputShape) { OutputShape src = (OutputShape) source; _controller = src.Controller; _output = src.Output; _CopyControlPointsFrom(src); } }
private IDataPolicy _CreateDataPolicy(CommandOutput output) { IDataPolicy dataPolicy = _dataPolicyFactory.CreateDataPolicy(); _AddDataPolicy(output, dataPolicy); return dataPolicy; }
private void _AddDataPolicy(CommandOutput output, IDataPolicy dataPolicy) { lock (_outputDataPolicies) { _outputDataPolicies[output.Id] = dataPolicy; } }
public IDataPolicy GetDataPolicyForOutput(CommandOutput output) { return _GetDataPolicy(output) ?? _CreateDataPolicy(output); }
private void _AddOutput(CommandOutput commandOutput) { _outputStateList.Add(commandOutput.Id,new List<ICommand>()); }
public CommandOutputDataFlowAdapter(CommandOutput output) { _output = output; Name = (_output.Index + 1).ToString(); }
public void RemoveOutput(CommandOutput output) { _outputMediator.RemoveOutput(output); VixenSystem.DataFlow.RemoveComponent(_adapterFactory.GetAdapter(output)); }
private void _AddOutput(CommandOutput commandOutput) { _outputStateList.Add(commandOutput.Id, commandOutput.Command); }
public void SetOutput(CommandOutput output) { _output = output; _recalcControlPoints(); }
public IDataFlowComponent GetDataFlowComponentForOutput(CommandOutput output) { return(_adapterFactory.GetAdapter(output)); }
public IDataPolicy GetDataPolicyForOutput(CommandOutput output) { return(_GetDataPolicy(output) ?? _CreateDataPolicy(output)); }