public IDataFlowComponent GetAdapter(IntentOutput output)
        {
            IntentOutputDataFlowAdapter adapter;

            if (!_instances.TryGetValue(output.Id, out adapter))
            {
                adapter = new IntentOutputDataFlowAdapter(output);
                _instances[output.Id] = adapter;
            }
            return(adapter);
        }
        private void _ReadOutputs(SmartOutputController controller, XElement element)
        {
            XElement outputsElement = element.Element(ELEMENT_OUTPUTS);

            if (outputsElement != null)
            {
                int index = 0;
                foreach (XElement outputElement in outputsElement.Elements(ELEMENT_OUTPUT))
                {
                    Guid?  id   = XmlHelper.GetGuidAttribute(outputElement, ATTR_ID);
                    string name = XmlHelper.GetAttribute(outputElement, ATTR_NAME) ?? "Unnamed output";

                    IntentOutputFactory outputFactory = new IntentOutputFactory();
                    IntentOutput        output        = (IntentOutput)outputFactory.CreateOutput(id.GetValueOrDefault(), name, index++);

                    controller.AddOutput(output);
                }
            }
        }
 public IntentOutputDataFlowAdapter(IntentOutput output)
 {
     _output = output;
     Name    = (_output.Index + 1).ToString();
 }