Beispiel #1
0
 public void moveStatsPanel(Units unit)
 {
     if (unit.Equals(viewedUnit))
     {
         statsPanel.transform.position = (Vector2)unit.transform.position + statsPanelShift;
     }
 }
Beispiel #2
0
 public void removeStatsPanel(Units unit)
 {
     if (unit.Equals(viewedUnit))
     {
         statsPanel.SetActive(false);
         viewedUnit = null;
     }
 }
Beispiel #3
0
 public void SetProjectUnits(ProjectUnits target)
 {
     if (Units == null)
     {
         OnProjectUnitsSet(new ProjectUnits.SetEventArgs(target));
         this.Units = target;
     }
     else if (!Units.Equals(target))
     {
         OnProjectUnitsChange(new ProjectUnits.ChangeEventArgs(Units, target));
         ConvertUnits(target);
         this.Units = target;
     }
 }
Beispiel #4
0
 public void ToggleStatsPanel(Units unit)
 {
     if (unit.Equals(viewedUnit) == false)
     {
         statsPanel.SetActive(true);
         statsPanel.transform.position = (Vector2)unit.transform.position + statsPanelShift;
         viewedUnit = unit;
         UpdateStatsPanel();
     }
     else
     {
         statsPanel.SetActive(false);
         viewedUnit = null;
     }
 }
Beispiel #5
0
        /// <summary>
        /// Returns true if TemperatureZoneStatus instances are equal
        /// </summary>
        /// <param name="other">Instance of TemperatureZoneStatus to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(TemperatureZoneStatus other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                     ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ) &&
                 (
                     TemperatureValue == other.TemperatureValue ||
                     TemperatureValue != null &&
                     TemperatureValue.Equals(other.TemperatureValue)
                 ) &&
                 (
                     HumidityValue == other.HumidityValue ||
                     HumidityValue != null &&
                     HumidityValue.Equals(other.HumidityValue)
                 ) &&
                 (
                     PressureValue == other.PressureValue ||
                     PressureValue != null &&
                     PressureValue.Equals(other.PressureValue)
                 ) &&
                 (
                     Units == other.Units ||
                     Units != null &&
                     Units.Equals(other.Units)
                 ) &&
                 (
                     Timestamp == other.Timestamp ||
                     Timestamp != null &&
                     Timestamp.Equals(other.Timestamp)
                 ));
        }
Beispiel #6
0
        public bool Equals(Instance other)
        {
            var result = false;

            if (other != null)
            {
                if (SchemaReference.Equals(other.SchemaReference))
                {
                    if (Units.Equals(other.Units))
                    {
                        if (FilingIndicators.Equals(other.FilingIndicators))
                        {
                            if (Contexts.Equals(other.Contexts))
                            {
                                result |= Facts.Equals(other.Facts);
                            }
                        }
                    }
                }
            }

            return(result);
        }
Beispiel #7
0
        /// <summary>
        /// Returns true if DashboardWidgetOptionsBean instances are equal
        /// </summary>
        /// <param name="input">Instance of DashboardWidgetOptionsBean to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(DashboardWidgetOptionsBean input)
        {
            if (input == null)
            {
                return(false);
            }

            return
                ((
                     Uri == input.Uri ||
                     (Uri != null &&
                      Uri.Equals(input.Uri))
                     ) &&
                 (
                     ChartId == input.ChartId ||
                     (ChartId != null &&
                      ChartId.Equals(input.ChartId))
                 ) &&
                 (
                     ServiceId == input.ServiceId ||
                     (ServiceId != null &&
                      ServiceId.Equals(input.ServiceId))
                 ) &&
                 (
                     ItemId == input.ItemId ||
                     (ItemId != null &&
                      ItemId.Equals(input.ItemId))
                 ) &&
                 (
                     BarWidth == input.BarWidth ||
                     (BarWidth != null &&
                      BarWidth.Equals(input.BarWidth))
                 ) &&
                 (
                     BorderWidth == input.BorderWidth ||
                     (BorderWidth != null &&
                      BorderWidth.Equals(input.BorderWidth))
                 ) &&
                 (
                     Angle == input.Angle ||
                     (Angle != null &&
                      Angle.Equals(input.Angle))
                 ) &&
                 (
                     Rotate == input.Rotate ||
                     (Rotate != null &&
                      Rotate.Equals(input.Rotate))
                 ) &&
                 (
                     BarAngle == input.BarAngle ||
                     (BarAngle != null &&
                      BarAngle.Equals(input.BarAngle))
                 ) &&
                 (
                     LineCap == input.LineCap ||
                     (LineCap != null &&
                      LineCap.Equals(input.LineCap))
                 ) &&
                 (
                     ScaleMin == input.ScaleMin ||
                     (ScaleMin != null &&
                      ScaleMin.Equals(input.ScaleMin))
                 ) &&
                 (
                     ScaleMax == input.ScaleMax ||
                     (ScaleMax != null &&
                      ScaleMax.Equals(input.ScaleMax))
                 ) &&
                 (
                     Title == input.Title ||
                     (Title != null &&
                      Title.Equals(input.Title))
                 ) &&
                 (
                     Units == input.Units ||
                     (Units != null &&
                      Units.Equals(input.Units))
                 ) &&
                 (
                     Group == input.Group ||
                     (Group != null &&
                      Group.Equals(input.Group))
                 ) &&
                 (
                     FloorplanId == input.FloorplanId ||
                     (FloorplanId != null &&
                      FloorplanId.Equals(input.FloorplanId))
                 ));
        }
        /// <summary>
        /// Returns true if Settings instances are equal
        /// </summary>
        /// <param name="other">Instance of Settings to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(Settings other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Units == other.Units ||
                     Units != null &&
                     Units.Equals(other.Units)
                     ) &&
                 (
                     TimeFormat == other.TimeFormat ||
                     TimeFormat != null &&
                     TimeFormat.Equals(other.TimeFormat)
                 ) &&
                 (
                     CustomTitle == other.CustomTitle ||
                     CustomTitle != null &&
                     CustomTitle.Equals(other.CustomTitle)
                 ) &&
                 (
                     NightMode == other.NightMode ||
                     NightMode != null &&
                     NightMode.Equals(other.NightMode)
                 ) &&
                 (
                     Theme == other.Theme ||
                     Theme != null &&
                     Theme.Equals(other.Theme)
                 ) &&
                 (
                     Language == other.Language ||
                     Language != null &&
                     Language.Equals(other.Language)
                 ) &&
                 (
                     ShowPlugins == other.ShowPlugins ||
                     ShowPlugins != null &&
                     ShowPlugins.Equals(other.ShowPlugins)
                 ) &&
                 (
                     ShowRawbg == other.ShowRawbg ||
                     ShowRawbg != null &&
                     ShowRawbg.Equals(other.ShowRawbg)
                 ) &&
                 (
                     AlarmTypes == other.AlarmTypes ||
                     AlarmTypes != null &&
                     AlarmTypes.SequenceEqual(other.AlarmTypes)
                 ) &&
                 (
                     AlarmUrgentHigh == other.AlarmUrgentHigh ||
                     AlarmUrgentHigh != null &&
                     AlarmUrgentHigh.Equals(other.AlarmUrgentHigh)
                 ) &&
                 (
                     AlarmHigh == other.AlarmHigh ||
                     AlarmHigh != null &&
                     AlarmHigh.Equals(other.AlarmHigh)
                 ) &&
                 (
                     AlarmLow == other.AlarmLow ||
                     AlarmLow != null &&
                     AlarmLow.Equals(other.AlarmLow)
                 ) &&
                 (
                     AlarmUrgentLow == other.AlarmUrgentLow ||
                     AlarmUrgentLow != null &&
                     AlarmUrgentLow.Equals(other.AlarmUrgentLow)
                 ) &&
                 (
                     AlarmTimeagoWarn == other.AlarmTimeagoWarn ||
                     AlarmTimeagoWarn != null &&
                     AlarmTimeagoWarn.Equals(other.AlarmTimeagoWarn)
                 ) &&
                 (
                     AlarmTimeagoWarnMins == other.AlarmTimeagoWarnMins ||
                     AlarmTimeagoWarnMins != null &&
                     AlarmTimeagoWarnMins.Equals(other.AlarmTimeagoWarnMins)
                 ) &&
                 (
                     AlarmTimeagoUrgent == other.AlarmTimeagoUrgent ||
                     AlarmTimeagoUrgent != null &&
                     AlarmTimeagoUrgent.Equals(other.AlarmTimeagoUrgent)
                 ) &&
                 (
                     AlarmTimeagoUrgentMins == other.AlarmTimeagoUrgentMins ||
                     AlarmTimeagoUrgentMins != null &&
                     AlarmTimeagoUrgentMins.Equals(other.AlarmTimeagoUrgentMins)
                 ) &&
                 (
                     Enable == other.Enable ||
                     Enable != null &&
                     Enable.SequenceEqual(other.Enable)
                 ) &&
                 (
                     Thresholds == other.Thresholds ||
                     Thresholds != null &&
                     Thresholds.Equals(other.Thresholds)
                 ));
        }
        /// <summary>
        /// Returns true if Treatment instances are equal
        /// </summary>
        /// <param name="other">Instance of Treatment to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(Treatment other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Id == other.Id ||
                     Id != null &&
                     Id.Equals(other.Id)
                     ) &&
                 (
                     EventType == other.EventType ||
                     EventType != null &&
                     EventType.Equals(other.EventType)
                 ) &&
                 (
                     CreatedAt == other.CreatedAt ||
                     CreatedAt != null &&
                     CreatedAt.Equals(other.CreatedAt)
                 ) &&
                 (
                     Glucose == other.Glucose ||
                     Glucose != null &&
                     Glucose.Equals(other.Glucose)
                 ) &&
                 (
                     GlucoseType == other.GlucoseType ||
                     GlucoseType != null &&
                     GlucoseType.Equals(other.GlucoseType)
                 ) &&
                 (
                     Carbs == other.Carbs ||
                     Carbs != null &&
                     Carbs.Equals(other.Carbs)
                 ) &&
                 (
                     Insulin == other.Insulin ||
                     Insulin != null &&
                     Insulin.Equals(other.Insulin)
                 ) &&
                 (
                     Units == other.Units ||
                     Units != null &&
                     Units.Equals(other.Units)
                 ) &&
                 (
                     Notes == other.Notes ||
                     Notes != null &&
                     Notes.Equals(other.Notes)
                 ) &&
                 (
                     EnteredBy == other.EnteredBy ||
                     EnteredBy != null &&
                     EnteredBy.Equals(other.EnteredBy)
                 ));
        }