Esempio n. 1
0
        /// <summary>
        /// Gets a list of nodes from the cacheDB and subscribes to opc-server change for all of them.
        /// The OPC-server notifies that a monitored item has changed value/status, when this happen
        /// an "Notification" event is fired on the client side. This method register the "OnNotification"
        /// event handler of all the added IOPCconnect interface to the service manager. For each item change
        /// all the event handlers are invoked, there is no filter currently.
        /// </summary>
        public void subscribeOpcNodes()
        {
            var nodes = db.getDbNodes();

            logger.Info("Number of selected nodes: " + nodes.Count);
            opc.subscribe(nodes, collectOnNotificationEventHandlers());
        }
Esempio n. 2
0
 /// <summary>
 /// Gets a list of nodes from the cacheDB and subscribes to opc-server change for all of them.
 /// The OPC-server notifies that a monitored item has changed value/status, when this happen
 /// an "Notification" event is fired on the client side. This method register the "OnNotification"
 /// event handler of all the added IOPCconnect interface to the service manager. For each item change
 /// all the event handlers are invoked, there is no filter currently.
 /// </summary>
 public void subscribeOpcNodes()
 {
     opc.subscribe(db.getDbNodes(), collectOnNotificationEventHandlers());
 }