You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@avro.apache.org by mg...@apache.org on 2022/04/21 18:17:48 UTC
[avro] branch branch-1.11 updated: AVRO-3498 Deprecate NameCtorKey (#1657)
This is an automated email from the ASF dual-hosted git repository.
mgrigorov pushed a commit to branch branch-1.11
in repository https://gitbox.apache.org/repos/asf/avro.git
The following commit(s) were added to refs/heads/branch-1.11 by this push:
new ee2911785 AVRO-3498 Deprecate NameCtorKey (#1657)
ee2911785 is described below
commit ee2911785823f26fa6cc4ed1bf285838405e3dd8
Author: Kyle Schoonover <ky...@minmaxcorp.com>
AuthorDate: Thu Apr 21 11:17:27 2022 -0700
AVRO-3498 Deprecate NameCtorKey (#1657)
(cherry picked from commit c0463d0c376b260b4095106935855c938e80105b)
---
.../src/apache/main/Specific/ObjectCreator.cs | 58 ----------------------
1 file changed, 58 deletions(-)
diff --git a/lang/csharp/src/apache/main/Specific/ObjectCreator.cs b/lang/csharp/src/apache/main/Specific/ObjectCreator.cs
index e69a49028..073b10795 100644
--- a/lang/csharp/src/apache/main/Specific/ObjectCreator.cs
+++ b/lang/csharp/src/apache/main/Specific/ObjectCreator.cs
@@ -58,13 +58,6 @@ namespace Avro.Specific
private readonly Assembly entryAssembly;
private readonly bool diffAssembly;
- /// <summary>
- /// Obsolete: This will be removed from the public API in a future version.
- /// </summary>
- /// <returns>Obsolete</returns>
- [Obsolete("This will be removed from the public API in a future version.")]
- public delegate object CtorDelegate();
-
/// <summary>
/// Initializes a new instance of the <see cref="ObjectCreator"/> class.
/// </summary>
@@ -78,57 +71,6 @@ namespace Avro.Specific
diffAssembly = entryAssembly != null && execAssembly != entryAssembly;
}
-#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member
-#pragma warning disable CA1034 // Nested types should not be visible
-#pragma warning disable SA1600 // Elements should be documented
- /// <summary>
- /// Obsolete: This will be removed from the public API in a future version.
- /// </summary>
- [Obsolete("This will be removed from the public API in a future version.")]
- public struct NameCtorKey : IEquatable<NameCtorKey>
- {
- public string name { get; private set; }
- public Schema.Type type { get; private set; }
- public NameCtorKey(string value1, Schema.Type value2)
- : this()
- {
- name = value1;
- type = value2;
- }
- public bool Equals(NameCtorKey other)
- {
- return Equals(other.name, name) && other.type == type;
- }
- public override bool Equals(object obj)
- {
- if (ReferenceEquals(null, obj))
- return false;
- if (obj.GetType() != typeof(NameCtorKey))
- return false;
- return Equals((NameCtorKey)obj);
- }
- public override int GetHashCode()
- {
- unchecked
- {
-#pragma warning disable CA1307 // Specify StringComparison
- return ((name != null ? name.GetHashCode() : 0) * 397) ^ type.GetHashCode();
-#pragma warning restore CA1307 // Specify StringComparison
- }
- }
- public static bool operator ==(NameCtorKey left, NameCtorKey right)
- {
- return left.Equals(right);
- }
- public static bool operator !=(NameCtorKey left, NameCtorKey right)
- {
- return !left.Equals(right);
- }
- }
-#pragma warning restore SA1600 // Elements should be documented
-#pragma warning restore CA1034 // Nested types should not be visible
-#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member
-
/// <summary>
/// Find the type with the given name
/// </summary>