1. Fix EDKT413: EnumerationData.java should use defined final static string
authorhche10x <hche10x@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 4 Jan 2007 06:10:34 +0000 (06:10 +0000)
committerhche10x <hche10x@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 4 Jan 2007 06:10:34 +0000 (06:10 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2166 6f19259b-4bc3-4df7-8a09-765794883524

Tools/Java/Source/FrameworkWizard/src/org/tianocore/frameworkwizard/common/DataType.java
Tools/Java/Source/FrameworkWizard/src/org/tianocore/frameworkwizard/common/EnumerationData.java

index 9d50d08..03a64a6 100644 (file)
@@ -266,6 +266,10 @@ public class DataType {
     \r
     public final static String USAGE_TYPE_PRIVATE = "PRIVATE";\r
     \r
+    public final static String USAGE_TYPE_TO_START = "TO_START";\r
+    \r
+    public final static String USAGE_TYPE_BY_START = "BY_START";\r
+    \r
     //\r
     // The String for PCD type\r
     //\r
index 5b6c4f6..7eae384 100644 (file)
@@ -395,11 +395,11 @@ public class EnumerationData {
 \r
     private void initLibraryUsage() {\r
         vLibraryUsage.removeAllElements();\r
-        vLibraryUsage.addElement("ALWAYS_CONSUMED");\r
-        vLibraryUsage.addElement("SOMETIMES_CONSUMED");\r
-        vLibraryUsage.addElement("ALWAYS_PRODUCED");\r
-        vLibraryUsage.addElement("SOMETIMES_PRODUCED");\r
-        vLibraryUsage.addElement("PRIVATE");\r
+        vLibraryUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vLibraryUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vLibraryUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vLibraryUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vLibraryUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initFrameworkModuleTypes() {\r
@@ -571,25 +571,25 @@ public class EnumerationData {
 \r
     private void initPackageUsage() {\r
         vPackageUsage.removeAllElements();\r
-        vPackageUsage.addElement("ALWAYS_CONSUMED");\r
-        vPackageUsage.addElement("ALWAYS_PRODUCED");\r
+        vPackageUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vPackageUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
     }\r
 \r
     private void initProtocolUsage() {\r
         vProtocolUsage.removeAllElements();\r
-        vProtocolUsage.addElement("ALWAYS_CONSUMED");\r
-        vProtocolUsage.addElement("SOMETIMES_CONSUMED");\r
-        vProtocolUsage.addElement("ALWAYS_PRODUCED");\r
-        vProtocolUsage.addElement("SOMETIMES_PRODUCED");\r
-        vProtocolUsage.addElement("TO_START");\r
-        vProtocolUsage.addElement("BY_START");\r
-        vProtocolUsage.addElement("PRIVATE");\r
+        vProtocolUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vProtocolUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vProtocolUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vProtocolUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vProtocolUsage.addElement(DataType.USAGE_TYPE_TO_START);\r
+        vProtocolUsage.addElement(DataType.USAGE_TYPE_BY_START);\r
+        vProtocolUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initProtocolType() {\r
         vProtocolType.removeAllElements();\r
-        vProtocolType.addElement("Protocol");\r
-        vProtocolType.addElement("Protocol Notify");\r
+        vProtocolType.addElement(DataType.PROTOCOL_TYPE_PROTOCOL);\r
+        vProtocolType.addElement(DataType.PROTOCOL_TYPE_PROTOCOL_NOTIFY);\r
     }\r
 \r
     private void initEventType() {\r
@@ -600,11 +600,11 @@ public class EnumerationData {
 \r
     private void initEventUsage() {\r
         vEventUsage.removeAllElements();\r
-        vEventUsage.addElement("ALWAYS_CONSUMED");\r
-        vEventUsage.addElement("SOMETIMES_CONSUMED");\r
-        vEventUsage.addElement("ALWAYS_PRODUCED");\r
-        vEventUsage.addElement("SOMETIMES_PRODUCED");\r
-        vEventUsage.addElement("PRIVATE");\r
+        vEventUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vEventUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vEventUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vEventUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vEventUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initEventGroup() {\r
@@ -628,44 +628,44 @@ public class EnumerationData {
 \r
     private void initHobUsage() {\r
         vHobUsage.removeAllElements();\r
-        vHobUsage.addElement("ALWAYS_CONSUMED");\r
-        vHobUsage.addElement("SOMETIMES_CONSUMED");\r
-        vHobUsage.addElement("ALWAYS_PRODUCED");\r
-        vHobUsage.addElement("SOMETIMES_PRODUCED");\r
-        vHobUsage.addElement("PRIVATE");\r
+        vHobUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vHobUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vHobUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vHobUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vHobUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initPpiType() {\r
         vPpiType.removeAllElements();\r
-        vPpiType.addElement("Ppi");\r
-        vPpiType.addElement("Ppi Notify");\r
+        vPpiType.addElement(DataType.PPI_TYPE_PPI);\r
+        vPpiType.addElement(DataType.PPI_TYPE_PPI_NOTIFY);\r
     }\r
 \r
     private void initPpiUsage() {\r
         vPpiUsage.removeAllElements();\r
-        vPpiUsage.addElement("ALWAYS_CONSUMED");\r
-        vPpiUsage.addElement("SOMETIMES_CONSUMED");\r
-        vPpiUsage.addElement("ALWAYS_PRODUCED");\r
-        vPpiUsage.addElement("SOMETIMES_PRODUCED");\r
-        vPpiUsage.addElement("PRIVATE");\r
+        vPpiUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vPpiUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vPpiUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vPpiUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vPpiUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initPpiNotifyUsage() {\r
         vPpiNotifyUsage.removeAllElements();\r
-        vPpiNotifyUsage.addElement("SOMETIMES_CONSUMED");\r
+        vPpiNotifyUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
     }\r
 \r
     private void initProtocolNotifyUsage() {\r
-        vProtocolNotifyUsage.addElement("SOMETIMES_CONSUMED");\r
+        vProtocolNotifyUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
     }\r
 \r
     private void initVariableUsage() {\r
         vVariableUsage.removeAllElements();\r
-        vVariableUsage.addElement("ALWAYS_CONSUMED");\r
-        vVariableUsage.addElement("SOMETIMES_CONSUMED");\r
-        vVariableUsage.addElement("ALWAYS_PRODUCED");\r
-        vVariableUsage.addElement("SOMETIMES_PRODUCED");\r
-        vVariableUsage.addElement("PRIVATE");\r
+        vVariableUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vVariableUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vVariableUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vVariableUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vVariableUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initBootModeNames() {\r
@@ -694,44 +694,44 @@ public class EnumerationData {
 \r
     private void initBootModeUsage() {\r
         vBootModeUsage.removeAllElements();\r
-        vBootModeUsage.addElement("ALWAYS_CONSUMED");\r
-        vBootModeUsage.addElement("SOMETIMES_CONSUMED");\r
-        vBootModeUsage.addElement("ALWAYS_PRODUCED");\r
-        vBootModeUsage.addElement("SOMETIMES_PRODUCED");\r
+        vBootModeUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vBootModeUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vBootModeUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vBootModeUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
     }\r
 \r
     private void initSystemTableUsage() {\r
         vSystemTableUsage.removeAllElements();\r
-        vSystemTableUsage.addElement("ALWAYS_CONSUMED");\r
-        vSystemTableUsage.addElement("SOMETIMES_CONSUMED");\r
-        vSystemTableUsage.addElement("ALWAYS_PRODUCED");\r
-        vSystemTableUsage.addElement("SOMETIMES_PRODUCED");\r
-        vSystemTableUsage.addElement("PRIVATE");\r
+        vSystemTableUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vSystemTableUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vSystemTableUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vSystemTableUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vSystemTableUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initDataHubUsage() {\r
         vDataHubUsage.removeAllElements();\r
-        vDataHubUsage.addElement("ALWAYS_CONSUMED");\r
-        vDataHubUsage.addElement("SOMETIMES_CONSUMED");\r
-        vDataHubUsage.addElement("ALWAYS_PRODUCED");\r
-        vDataHubUsage.addElement("SOMETIMES_PRODUCED");\r
-        vDataHubUsage.addElement("PRIVATE");\r
+        vDataHubUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vDataHubUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vDataHubUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vDataHubUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vDataHubUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initHiiPackages() {\r
         vHiiPackageUsage.removeAllElements();\r
-        vHiiPackageUsage.addElement("ALWAYS_PRODUCED");\r
-        vHiiPackageUsage.addElement("SOMETIMES_PRODUCED");\r
-        vHiiPackageUsage.addElement("PRIVATE");\r
+        vHiiPackageUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vHiiPackageUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vHiiPackageUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initGuidUsage() {\r
         vGuidUsage.removeAllElements();\r
-        vGuidUsage.addElement("ALWAYS_CONSUMED");\r
-        vGuidUsage.addElement("SOMETIMES_CONSUMED");\r
-        vGuidUsage.addElement("ALWAYS_PRODUCED");\r
-        vGuidUsage.addElement("SOMETIMES_PRODUCED");\r
-        vGuidUsage.addElement("PRIVATE");\r
+        vGuidUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vGuidUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vGuidUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vGuidUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
+        vGuidUsage.addElement(DataType.USAGE_TYPE_PRIVATE);\r
     }\r
 \r
     private void initExternTypes() {\r
@@ -761,10 +761,10 @@ public class EnumerationData {
 \r
     private void initPcdUsage() {\r
         vPcdUsage.removeAllElements();\r
-        vPcdUsage.addElement("ALWAYS_CONSUMED");\r
-        vPcdUsage.addElement("SOMETIMES_CONSUMED");\r
-        vPcdUsage.addElement("ALWAYS_PRODUCED");\r
-        vPcdUsage.addElement("SOMETIMES_PRODUCED");\r
+        vPcdUsage.addElement(DataType.USAGE_TYPE_ALWAYS_CONSUMED);\r
+        vPcdUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_CONSUMED);\r
+        vPcdUsage.addElement(DataType.USAGE_TYPE_ALWAYS_PRODUCED);\r
+        vPcdUsage.addElement(DataType.USAGE_TYPE_SOMETIMES_PRODUCED);\r
     }\r
     \r
     private void initBuildTargets() {\r