import org.tianocore.pcd.entity.UsageInstance;\r
import org.tianocore.pcd.exception.BuildActionException;\r
\r
-/** This class is to manage how to generate the PCD information into Autogen.c and\r
- Autogen.h.\r
+/**\r
+ This class is to manage how to generate the PCD information into Autogen.c\r
+ and Autogen.h.\r
**/\r
public class PCDAutoGenAction extends BuildAction {\r
///\r
\r
@return the string of header file for PCD\r
**/\r
- public String OutputH() {\r
+ public String getHAutoGenString() {\r
return hAutoGenString;\r
}\r
\r
\r
@return the string of C code file for PCD\r
**/\r
- public String OutputC() {\r
+ public String getCAutoGenString() {\r
return cAutoGenString;\r
}\r
\r
cAutoGenString += usageInstance.getCAutogenStr();\r
}\r
\r
- //\r
- // Work around code, In furture following code should be modified that get\r
- // these information from Uplevel Autogen tools.\r
- //\r
if (pcdDriverType == CommonDefinition.PCD_DRIVER_TYPE.PEI_PCD_DRIVER) {\r
hAutoGenString += MemoryDatabaseManager.PcdPeimHString;\r
cAutoGenString += MemoryDatabaseManager.PcdPeimCString;\r
cAutoGenString += MemoryDatabaseManager.PcdDxeCString;\r
}\r
}\r
-\r
- /**\r
- Test case function\r
-\r
- @param argv paramter from command line\r
- **/\r
- public static void main(String argv[]) {\r
-\r
- String WorkSpace = "X:/edk2";\r
- String logFilePath = WorkSpace + "/EdkNt32Pkg/Nt32.fpd";\r
-\r
- //\r
- // At first, CollectPCDAction should be invoked to collect\r
- // all PCD information from SPD, MSA, FPD.\r
- //\r
- PlatformPcdPreprocessActionForBuilding collectionAction = new PlatformPcdPreprocessActionForBuilding();\r
- GlobalData.initInfo("Tools" + File.separator + "Conf" + File.separator + "FrameworkDatabase.db",\r
- WorkSpace,null);\r
-\r
- try {\r
- collectionAction.perform(logFilePath, ActionMessage.MAX_MESSAGE_LEVEL);\r
- } catch(Exception e) {\r
- e.printStackTrace();\r
- }\r
- }\r
}\r