]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Tools/Java/Source/FrameworkWizard/src/org/tianocore/frameworkwizard/packaging/PackageIdentification.java
1. Fix EDKT457 Multiple FPD, MSA or SPD files in a directory is prohibited
[mirror_edk2.git] / Tools / Java / Source / FrameworkWizard / src / org / tianocore / frameworkwizard / packaging / PackageIdentification.java
index 23b6ff0290f53c4a48bcafd464f9ccbf31778cd9..e986f55baf7033d5d2c7b76a99521ca0e89d84d3 100644 (file)
@@ -43,4 +43,22 @@ public class PackageIdentification extends Identification{
     public String toString() {\r
       return getName() + " " + getVersion() + " [" + Tools.getRelativePath(getSpdFile().getPath(), Workspace.getCurrentWorkspace()) + "]";\r
     }\r
+    \r
+    public boolean equals(String packageGuid, String packageVersion) {\r
+        boolean b = false;\r
+        if (this.getGuid().equals(packageGuid)) {\r
+            b = true;\r
+            //\r
+            // Check Version\r
+            //\r
+            if (packageVersion != null) {\r
+                if (!Tools.isEmpty(packageVersion)) {\r
+                    if (!packageVersion.equals(this.getVersion())) {\r
+                        b = false;\r
+                    }\r
+                }\r
+            }\r
+        }\r
+        return b;\r
+    }\r
 }\r