Example #1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (provenance_ != null)
            {
                hash ^= Provenance.GetHashCode();
            }
            if (ProvenanceBytes.Length != 0)
            {
                hash ^= ProvenanceBytes.GetHashCode();
            }
            if (intotoProvenance_ != null)
            {
                hash ^= IntotoProvenance.GetHashCode();
            }
            if (intotoStatement_ != null)
            {
                hash ^= IntotoStatement.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
Example #2
0
 public void MergeFrom(BuildOccurrence other)
 {
     if (other == null)
     {
         return;
     }
     if (other.provenance_ != null)
     {
         if (provenance_ == null)
         {
             Provenance = new global::Grafeas.V1.BuildProvenance();
         }
         Provenance.MergeFrom(other.Provenance);
     }
     if (other.ProvenanceBytes.Length != 0)
     {
         ProvenanceBytes = other.ProvenanceBytes;
     }
     if (other.intotoProvenance_ != null)
     {
         if (intotoProvenance_ == null)
         {
             IntotoProvenance = new global::Grafeas.V1.InTotoProvenance();
         }
         IntotoProvenance.MergeFrom(other.IntotoProvenance);
     }
     if (other.intotoStatement_ != null)
     {
         if (intotoStatement_ == null)
         {
             IntotoStatement = new global::Grafeas.V1.InTotoStatement();
         }
         IntotoStatement.MergeFrom(other.IntotoStatement);
     }
     _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
 }