[NUI] Fix build warning CA1720
authorSunghyun Kim <scholb.kim@samsung.com>
Thu, 10 Dec 2020 10:18:22 +0000 (19:18 +0900)
committerdongsug-song <35130733+dongsug-song@users.noreply.github.com>
Tue, 15 Dec 2020 06:33:59 +0000 (15:33 +0900)
https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1720
CA1720: Identifiers should not contain type names

These warnings need to suppress.
because it is very common name and it's already published.
According to the document described about the rule, we can suppress warnings.

src/Tizen.NUI/src/public/NUIConstants.cs
src/Tizen.NUI/src/public/PropertyKey.cs

index 0a779ce..4d20b1a 100755 (executable)
@@ -14,6 +14,7 @@
 
 using System;
 using System.ComponentModel;
+using System.Diagnostics.CodeAnalysis;
 
 namespace Tizen.NUI
 {
@@ -312,6 +313,8 @@ namespace Tizen.NUI
     /// An enum of Device Class types.
     /// </summary>
     /// <since_tizen> 3 </since_tizen>
+    /// Can't fix because it's already used by other GBM.
+    [SuppressMessage("Microsoft.Naming", "CA1720: Identifiers should not contain type names")]
     public enum DeviceClassType
     {
         /// <summary>
@@ -434,6 +437,8 @@ namespace Tizen.NUI
     /// Enumeration for the property types supported.
     /// </summary>
     /// <since_tizen> 3 </since_tizen>
+    /// Can't fix because it's already used by other GBM.
+    [SuppressMessage("Microsoft.Naming", "CA1720: Identifiers should not contain type names")]
     public enum PropertyType
     {
         /// <summary>
index 224090d..4156894 100755 (executable)
@@ -16,6 +16,7 @@
  */
 using System;
 using System.ComponentModel;
+using System.Diagnostics.CodeAnalysis;
 
 namespace Tizen.NUI
 {
@@ -53,6 +54,8 @@ namespace Tizen.NUI
         /// The type of key.
         /// </summary>
         /// <since_tizen> 3 </since_tizen>
+        /// Can't fix because it's already used by other GBM.
+        [SuppressMessage("Microsoft.Naming", "CA1720:Identifiers should not contain type names")]
         public enum KeyType
         {
             /// <summary>