Ejemplo n.º 1
0
 public void LoadIdsFromLineDefinitions(LineDefinitionList lines)
 {
     foreach (var line in lines.LineDefinitions)
     {
         if (line.Active)
         {
             borderIds.Add(line.Id);
         }
     }
 }
Ejemplo n.º 2
0
        public HttpStatusCode GetSVGLayoutInfo(out Model.AreaDefinitionList areasList,
                                               out Model.LineDefinitionList linesList)
        {
            ValidateIsBound();

            var    client       = new MoveRestClient(_device, _port, _username, _password);
            string body         = null;
            var    responseCode = client.GetLayout(out body);
            string msg          = (body.Length > _DATA_PREVIEW_SIZE) ? body.Substring(0, _DATA_PREVIEW_SIZE) : body;

            Trace.TraceInformation("\nRaw JSON data:  {0}{1}", msg, (msg.Length < body.Length) ? "..." : "");

            areasList = XmlHelper.XmlToAreaDefinitionsList(body);
            linesList = XmlHelper.XmlToLineDefinitionsList(body);

            return(responseCode);
        }