public override int GetHashCode()
        {
            int hashcode = 157;

            unchecked {
                if (__isset.trace_id)
                {
                    hashcode = (hashcode * 397) + Trace_id.GetHashCode();
                }
                if (__isset.name)
                {
                    hashcode = (hashcode * 397) + Name.GetHashCode();
                }
                if (__isset.id)
                {
                    hashcode = (hashcode * 397) + Id.GetHashCode();
                }
                if (__isset.parent_id)
                {
                    hashcode = (hashcode * 397) + Parent_id.GetHashCode();
                }
                if (__isset.annotations)
                {
                    hashcode = (hashcode * 397) + TCollections.GetHashCode(Annotations);
                }
                if (__isset.binary_annotations)
                {
                    hashcode = (hashcode * 397) + TCollections.GetHashCode(Binary_annotations);
                }
                if (__isset.debug)
                {
                    hashcode = (hashcode * 397) + Debug.GetHashCode();
                }
                if (__isset.timestamp)
                {
                    hashcode = (hashcode * 397) + Timestamp.GetHashCode();
                }
                if (__isset.duration)
                {
                    hashcode = (hashcode * 397) + Duration.GetHashCode();
                }
                if (__isset.trace_id_high)
                {
                    hashcode = (hashcode * 397) + Trace_id_high.GetHashCode();
                }
            }
            return(hashcode);
        }
Exemple #2
0
        public override int GetHashCode()
        {
            int hashcode = 0;

            unchecked {
                hashcode = (hashcode * 397) ^ (Trace_id == null ? 0 : (Trace_id.GetHashCode()));
                hashcode = (hashcode * 397) ^ (Name == null ? 0 : (Name.GetHashCode()));
                hashcode = (hashcode * 397) ^ (Id == null ? 0 : (Id.GetHashCode()));
                hashcode = (hashcode * 397) ^ (Parent_id == null ? 0 : (Parent_id.GetHashCode()));
                hashcode = (hashcode * 397) ^ (Annotations == null ? 0 : (TCollections.GetHashCode(Annotations)));
                hashcode = (hashcode * 397) ^ (Binary_annotations == null ? 0 : (TCollections.GetHashCode(Binary_annotations)));
                hashcode = (hashcode * 397) ^ (Debug == null ? 0 : (Debug.GetHashCode()));
                hashcode = (hashcode * 397) ^ (Timestamp == null ? 0 : (Timestamp.GetHashCode()));
                hashcode = (hashcode * 397) ^ (Duration == null ? 0 : (Duration.GetHashCode()));
            }
            return(hashcode);
        }
Exemple #3
0
        public override string ToString()
        {
            var sb    = new StringBuilder("Span(");
            int tmp15 = 0;

            if (__isset.trace_id)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Trace_id: ");
                Trace_id.ToString(sb);
            }
            if ((Name != null) && __isset.name)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Name: ");
                Name.ToString(sb);
            }
            if (__isset.id)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Id: ");
                Id.ToString(sb);
            }
            if (__isset.parent_id)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Parent_id: ");
                Parent_id.ToString(sb);
            }
            if ((Annotations != null) && __isset.annotations)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Annotations: ");
                Annotations.ToString(sb);
            }
            if ((Binary_annotations != null) && __isset.binary_annotations)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Binary_annotations: ");
                Binary_annotations.ToString(sb);
            }
            if (__isset.debug)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Debug: ");
                Debug.ToString(sb);
            }
            if (__isset.timestamp)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Timestamp: ");
                Timestamp.ToString(sb);
            }
            if (__isset.duration)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Duration: ");
                Duration.ToString(sb);
            }
            if (__isset.trace_id_high)
            {
                if (0 < tmp15++)
                {
                    sb.Append(", ");
                }
                sb.Append("Trace_id_high: ");
                Trace_id_high.ToString(sb);
            }
            sb.Append(')');
            return(sb.ToString());
        }