Exemplo n.º 1
0
        private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            client = AppContext.Instance.Client.InnerClient;
            var treeRoot1 = client.GetPhysicalTopologyTree(0);
            var treeRoot2 = client.GetDepartmentTree();

            ResourceTreeView1.LoadData(treeRoot1, treeRoot2);
            ResourceTreeView1.TopoTree.Tree.SelectedItemChanged += Tree_SelectedItemChanged;

            var devList = client.GetDevInfos(null);

            DeviceListBox1.LoadData(devList);

            var personList = client.GetPersonList();

            PersonListBox1.LoadData(personList);

            var tagList = client.GetTags();

            TagListBox1.LoadData(tagList);

            var archorList = client.GetArchors();

            AchorListBox1.LoadData(archorList);

            AppContext.Instance.CallbackClient.LocAlarmsReceved += CallbackClient_LocAlarmsReceved;

            DeviceAlarm[] devAlarms = client.GetDeviceAlarms(new AlarmSearchArg());
            ShowDeviceAlarms(devAlarms);

            LocationAlarm[] locAlarms = client.GetLocationAlarms(new AlarmSearchArg());
            ShowLocationAlarms(locAlarms);

            InitAlarmHub();
        }
Exemplo n.º 2
0
        private void Getlocationalarms_Click(object sender, RoutedEventArgs e)
        {
            AlarmSearchArg arg = new AlarmSearchArg();

            arg.IsAll = true;

            LocationAlarm[] recv = client.GetLocationAlarms(arg);
            int             nn   = 0;
        }
Exemplo n.º 3
0
    void GetLocationAlarms()
    {
        Debug.Log("->GetLocationAlarms");
        LocationServiceClient client = GetLocationServiceClient();
        AlarmSearchArg        arg    = new AlarmSearchArg();

        LocationAlarm[] list = client.GetLocationAlarms(arg);
        foreach (LocationAlarm item in list)
        {
            Debug.Log("item:" + item.Content);
        }
    }