]>
Commit | Line | Data |
---|---|---|
a13899c5 | 1 | /** @file\r |
2 | \r | |
3 | The file is used to save basic information of package\r | |
4 | \r | |
5 | Copyright (c) 2006, Intel Corporation\r | |
6 | All rights reserved. This program and the accompanying materials\r | |
7 | are licensed and made available under the terms and conditions of the BSD License\r | |
8 | which accompanies this distribution. The full text of the license may be found at\r | |
9 | http://opensource.org/licenses/bsd-license.php\r | |
10 | \r | |
11 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
12 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
13 | \r | |
14 | **/\r | |
15 | \r | |
16 | package org.tianocore.frameworkwizard.packaging;\r | |
17 | import java.io.File;\r | |
18 | \r | |
79cb6fdb | 19 | import org.tianocore.frameworkwizard.common.Identifications.Identification;\r |
a13899c5 | 20 | \r |
21 | public class PackageIdentification extends Identification{\r | |
22 | \r | |
23 | //\r | |
24 | // It is optional\r | |
25 | //\r | |
26 | private File spdFile;\r | |
27 | \r | |
28 | public PackageIdentification(String name, String guid, String version){\r | |
29 | super(name, guid, version);\r | |
30 | }\r | |
31 | \r | |
32 | public PackageIdentification(String name, String guid, String version, String path){\r | |
33 | super(name, guid, version, path);\r | |
34 | }\r | |
35 | \r | |
36 | public PackageIdentification(Identification id){\r | |
37 | super(id.getName(), id.getGuid(), id.getVersion(), id.getPath());\r | |
38 | }\r | |
39 | \r | |
40 | public PackageIdentification(String name, String guid, String version, File spdFile){\r | |
41 | super(name, guid, version);\r | |
42 | this.spdFile = spdFile;\r | |
43 | }\r | |
44 | \r | |
45 | public File getSpdFile() {\r | |
46 | return spdFile;\r | |
47 | }\r | |
48 | \r | |
49 | public String toString(){\r | |
50 | return "Package " + this.getName() + "[" + this.getGuid() + "]";\r | |
51 | }\r | |
52 | \r | |
53 | public void setSpdFile(File spdFile) {\r | |
54 | this.spdFile = spdFile;\r | |
55 | }\r | |
56 | \r | |
57 | public String getPackageDir(){\r | |
58 | return spdFile.getParent();\r | |
59 | }\r | |
60 | }\r |