Example #1
0
        /// <summary>
        /// Linked constructor
        /// </summary>
        /// <param name="linkedNode">The linked node</param>
        public LayerSectionNode(LayerSectionNode linkedNode)
        {
            _filters      = linkedNode._filters;
            _graphEntries = linkedNode._graphEntries;

            if (linkedNode._direction == LayerSectionGraphDirection.ClientToServer)
            {
                _direction = LayerSectionGraphDirection.ServerToClient;
            }
            else
            {
                _direction = LayerSectionGraphDirection.ClientToServer;
            }

            _linkedNode             = linkedNode;
            _linkedNode._linkedNode = this;
            IsMaster = false;
        }
Example #2
0
        /// <summary>
        /// Linked constructor
        /// </summary>
        /// <param name="linkedNode">The linked node</param>
        public LayerSectionNode(LayerSectionNode linkedNode)
        {
            _filters = linkedNode._filters;
            _graphEntries = linkedNode._graphEntries;

            if (linkedNode._direction == LayerSectionGraphDirection.ClientToServer)
            {
                _direction = LayerSectionGraphDirection.ServerToClient;
            }
            else
            {
                _direction = LayerSectionGraphDirection.ClientToServer;
            }

            _linkedNode = linkedNode;
            _linkedNode._linkedNode = this;
            IsMaster = false;
        }
Example #3
0
 public LayerSectionDataAdapter(LayerSectionNode outputNode)
 {
     _inputQueue  = new LockedQueue <DataFrame>();
     _readTimeout = Timeout.Infinite;
     _outputNode  = outputNode;
 }
        /// <summary>
        /// OnCreate method
        /// </summary>
        /// <param name="logger">The logger for this graph</param>
        /// <param name="graph">The associated netgraph</param>
        /// <param name="stateDictionary">State dictionary</param>
        /// <returns>The new pipeline node</returns>
        protected override BasePipelineNode OnCreate(Logger logger, NetGraph graph, Dictionary<string, object> stateDictionary)
        {
            // If this node has been created by a slave return as appropriate
            if (stateDictionary.ContainsKey(Id.ToString()))
            {
                return (BasePipelineNode)stateDictionary[Id.ToString()];
            }

            List<LayerSectionFilter> filters = new List<LayerSectionFilter>();

            foreach (LayerSectionFilterFactory factory in LayerFactories)
            {
                filters.Add(factory.Create());
            }

            LayerSectionNode ret = new LayerSectionNode(filters.ToArray(), DefaultMode, LayerSectionGraphDirection.ServerToClient);

            // Create paired slave node
            stateDictionary[SlaveFactory.Id.ToString()] = new LayerSectionNode(ret);

            return ret;
        }
Example #5
0
 public LayerSectionDataAdapter(LayerSectionNode outputNode)
 {
     _inputQueue = new LockedQueue<DataFrame>();
     _readTimeout = Timeout.Infinite;
     _outputNode = outputNode;
 }