示例#1
0
 public void ReturnGatewayInfo(GatewayInfo info, string userId)
 {
     Clients.Client(userId).returnGatewayInfo(info);
 }
示例#2
0
        public GatewayInfo GetGatewayInfo()
        {
            GatewayInfo info =new GatewayInfo();

            info.isGatewayConnected = IsConnected();

            info.gatewayNodesRegistered = nodes.Count;

            int sensors=0;
            foreach (var node in nodes)
                sensors += node.sensors.Count;
            info.gatewaySensorsRegistered = sensors;

            return info;
        }