2 Java class FpdModuleIdentification is used to present a module identification
3 from BaseName, GUID, Version, PackageName, and ARCH.
5 Copyright (c) 2006, Intel Corporation
6 All rights reserved. This program and the accompanying materials
7 are licensed and made available under the terms and conditions of the BSD License
8 which accompanies this distribution. The full text of the license may be found at
9 http://opensource.org/licenses/bsd-license.php
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
14 package org
.tianocore
.build
.id
;
18 This class is used to identify a module with Module Guid, Module Version,
19 Package Guid, Package Version and Arch.
23 public class FpdModuleIdentification
{
27 private String fvBinding
= "NULL"; // Optional
29 private ModuleIdentification module
;
34 @param arch Build Arch
35 @param fvBinding Belong to what FVs
36 @param module ModuleIdentification
38 public FpdModuleIdentification(String arch
, String fvBinding
, ModuleIdentification module
){
40 this.fvBinding
= fvBinding
;
47 @param arch Build Arch
48 @param module ModuleIdentification
50 public FpdModuleIdentification(ModuleIdentification module
, String arch
){
55 Override java.lang.Object#equals.
57 <p>Currently, use BaseName and ARCH to identify a module. It will enhance
58 in the next version. </p>
60 @see java.lang.Object#equals(java.lang.Object)
62 public boolean equals(Object obj
) {
63 if (obj
instanceof FpdModuleIdentification
) {
64 FpdModuleIdentification moduleIdObj
= (FpdModuleIdentification
)obj
;
65 if ( module
.equals(moduleIdObj
.module
) && arch
.equalsIgnoreCase(moduleIdObj
.arch
)) {
78 public void setFvBinding(String fvBinding
) {
79 this.fvBinding
= fvBinding
;
83 @see java.lang.Object#toString()
85 public String
toString(){
86 return arch
+ ":" + module
;
90 @return String fvBinding
92 public String
getFvBinding() {
97 @return ModuleIdentification module ID
99 public ModuleIdentification
getModule() {
104 @param module Module Identification
106 public void setModule(ModuleIdentification module
) {
107 this.module
= module
;
113 public String
getArch() {
118 @param arch build ARCH
120 public void setArch(String arch
) {
125 @see java.lang.Object#hashCode()
127 public int hashCode(){
128 return module
.hashCode();