public void MergeFrom(UserAccount other) { if (other == null) { return; } if (other.Id.Length != 0) { Id = other.Id; } switch (other.UserAccountCase) { case UserAccountOneofCase.YandexPassportUserAccount: if (YandexPassportUserAccount == null) { YandexPassportUserAccount = new global::Yandex.Cloud.Iam.V1.YandexPassportUserAccount(); } YandexPassportUserAccount.MergeFrom(other.YandexPassportUserAccount); break; case UserAccountOneofCase.SamlUserAccount: if (SamlUserAccount == null) { SamlUserAccount = new global::Yandex.Cloud.Iam.V1.SamlUserAccount(); } SamlUserAccount.MergeFrom(other.SamlUserAccount); break; } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); }
public override int GetHashCode() { int hash = 1; if (Id.Length != 0) { hash ^= Id.GetHashCode(); } if (userAccountCase_ == UserAccountOneofCase.YandexPassportUserAccount) { hash ^= YandexPassportUserAccount.GetHashCode(); } if (userAccountCase_ == UserAccountOneofCase.SamlUserAccount) { hash ^= SamlUserAccount.GetHashCode(); } hash ^= (int)userAccountCase_; if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return(hash); }