コード例 #1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (commonTelemetry_ != null)
            {
                hash ^= CommonTelemetry.GetHashCode();
            }
            if (datapointValueCase_ == DatapointValueOneofCase.LongValue)
            {
                hash ^= LongValue.GetHashCode();
            }
            if (datapointValueCase_ == DatapointValueOneofCase.DoubleValue)
            {
                hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(DoubleValue);
            }
            if (datapointValueCase_ == DatapointValueOneofCase.BooleanValue)
            {
                hash ^= BooleanValue.GetHashCode();
            }
            if (datapointValueCase_ == DatapointValueOneofCase.Distribution)
            {
                hash ^= Distribution.GetHashCode();
            }
            if (MetricKind != 0)
            {
                hash ^= MetricKind.GetHashCode();
            }
            hash ^= (int)datapointValueCase_;
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (commonTelemetry_ != null)
            {
                hash ^= CommonTelemetry.GetHashCode();
            }
            if (LongValue != 0L)
            {
                hash ^= LongValue.GetHashCode();
            }
            if (DoubleValue != 0D)
            {
                hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(DoubleValue);
            }
            if (BooleanValue != false)
            {
                hash ^= BooleanValue.GetHashCode();
            }
            if (distribution_ != null)
            {
                hash ^= Distribution.GetHashCode();
            }
            if (MetricKind != 0)
            {
                hash ^= MetricKind.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #3
0
        public void MergeFrom(PlatformMetricData other)
        {
            if (other == null)
            {
                return;
            }
            if (other.commonTelemetry_ != null)
            {
                if (commonTelemetry_ == null)
                {
                    CommonTelemetry = new global::WUProtos.Data.Telemetry.TelemetryCommon();
                }
                CommonTelemetry.MergeFrom(other.CommonTelemetry);
            }
            if (other.MetricKind != 0)
            {
                MetricKind = other.MetricKind;
            }
            switch (other.DatapointValueCase)
            {
            case DatapointValueOneofCase.LongValue:
                LongValue = other.LongValue;
                break;

            case DatapointValueOneofCase.DoubleValue:
                DoubleValue = other.DoubleValue;
                break;

            case DatapointValueOneofCase.BooleanValue:
                BooleanValue = other.BooleanValue;
                break;

            case DatapointValueOneofCase.Distribution:
                if (Distribution == null)
                {
                    Distribution = new global::WUProtos.Data.Distribution();
                }
                Distribution.MergeFrom(other.Distribution);
                break;
            }

            _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
        }
コード例 #4
0
 public void MergeFrom(PlatformMetricData other)
 {
     if (other == null)
     {
         return;
     }
     if (other.commonTelemetry_ != null)
     {
         if (commonTelemetry_ == null)
         {
             commonTelemetry_ = new global::POGOProtos.Networking.Platform.Telemetry.TelemetryCommon();
         }
         CommonTelemetry.MergeFrom(other.CommonTelemetry);
     }
     if (other.LongValue != 0L)
     {
         LongValue = other.LongValue;
     }
     if (other.DoubleValue != 0D)
     {
         DoubleValue = other.DoubleValue;
     }
     if (other.BooleanValue != false)
     {
         BooleanValue = other.BooleanValue;
     }
     if (other.distribution_ != null)
     {
         if (distribution_ == null)
         {
             distribution_ = new global::POGOProtos.Networking.Platform.Telemetry.Distribution();
         }
         Distribution.MergeFrom(other.Distribution);
     }
     if (other.MetricKind != 0)
     {
         MetricKind = other.MetricKind;
     }
     _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
 }