Esempio n. 1
0
 public double getDistance(DocPoint otherPoint)
 {
     return Math.Sqrt(Math.Pow(this.point_X - otherPoint.point_X, 2) + Math.Pow(this.point_Y - otherPoint.point_Y, 2));
 }
 private bool isArchive(DocPoint point)
 {
     return point.flagArchive;
 }
 private bool toRemove(DocPoint point)
 {
     return point.toRemove;
 }
Esempio n. 4
0
        private void AddDOCRecord(string createdBy, DateTime createdDate, double X, double Y, double? Z, 
            double measurement, string description, int? equipmentid, double? accuracy, bool? probe)
        {
            double xMerc, yMerc;
            Enbridge.Utilities.ProjectionConversion.toWebMercator(X, Y, out xMerc, out yMerc);

            //Set the extents
            this.extent["xMin"] = (xMerc < this.extent["xMin"] ? xMerc : this.extent["xMin"]);
            this.extent["xMax"] = (xMerc > this.extent["xMax"] ? xMerc : this.extent["xMax"]);
            this.extent["yMin"] = (yMerc < this.extent["yMin"] ? yMerc : this.extent["yMin"]);
            this.extent["yMax"] = (yMerc > this.extent["yMax"] ? yMerc : this.extent["yMax"]);

            DocPoint docPoint = new DocPoint(createdBy, createdDate, X, Y, Z, measurement, description, equipmentid, accuracy, probe, this.groupCreatedDate, this.username);
            docPoint.pointGroupId = this.pointGroupId;
            docPoint.routeEventId = this.routeEventId;
            docPoint.groupCreatedDate = this.groupCreatedDate;
            this.docPointList.Add(docPoint);
        }