]>
Commit | Line | Data |
---|---|---|
a29c47e0 | 1 | package org.tianocore.build.id;\r |
2 | import java.io.File;\r | |
3 | \r | |
4 | import org.tianocore.build.global.GlobalData;\r | |
5 | \r | |
6 | public class PlatformIdentification extends Identification{\r | |
7 | \r | |
8 | private File fpdFile;\r | |
9 | \r | |
10 | public PlatformIdentification(String guid, String version){\r | |
11 | super(guid, version);\r | |
12 | }\r | |
13 | \r | |
14 | public PlatformIdentification(String name, String guid, String version){\r | |
15 | super(name, guid, version);\r | |
16 | }\r | |
17 | \r | |
18 | public PlatformIdentification(String name, String guid, String version, String fpdFilename){\r | |
19 | super(name, guid, version);\r | |
20 | this.fpdFile = new File(fpdFilename);\r | |
21 | }\r | |
22 | \r | |
23 | public PlatformIdentification(String name, String guid, String version, File fpdFile){\r | |
24 | super(name, guid, version);\r | |
25 | this.fpdFile = fpdFile;\r | |
26 | }\r | |
27 | \r | |
28 | public String toString(){\r | |
29 | return "Platform " + name + "["+guid+"]";\r | |
30 | }\r | |
31 | \r | |
32 | public void setFpdFile(File fpdFile) {\r | |
33 | this.fpdFile = fpdFile;\r | |
34 | }\r | |
35 | \r | |
36 | public File getFpdFile() {\r | |
37 | return fpdFile;\r | |
38 | }\r | |
39 | \r | |
40 | public String getPlatformRelativeDir(){\r | |
41 | return fpdFile.getParent().substring(GlobalData.getWorkspacePath().length());\r | |
42 | }\r | |
43 | } |