]>
Commit | Line | Data |
---|---|---|
4de92764 | 1 | /** @file |
2 | Tool Definition Class for translating the tools_def.txt entries | |
3 | ||
4 | Copyright (c) 2006, Intel Corporation | |
5 | All rights reserved. This program and the accompanying materials | |
6 | are licensed and made available under the terms and conditions of the BSD License | |
7 | which accompanies this distribution. The full text of the license may be found at | |
8 | http://opensource.org/licenses/bsd-license.php | |
9 | ||
10 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, | |
11 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. | |
12 | ||
13 | **/ | |
14 | ||
15 | /** | |
16 | * This section should complete array values | |
17 | * this.TagName | |
18 | * this.Family | |
19 | * this.Valid | |
20 | * this.Arch | |
21 | * this.Targets[] | |
22 | * this.CmdCode[] | |
23 | * this.Path[] | |
24 | * this.Arguments[] | |
25 | * | |
26 | */ | |
27 | ||
28 | package org.tianocore.CheckTools; | |
29 | ||
30 | import java.util.*; | |
31 | ||
32 | public class ToolInfo extends ArrayList { | |
33 | ||
34 | /// | |
35 | /// Define Class Serial Version UID | |
36 | /// | |
37 | private static final long serialVersionUID = 2513613555731096258L; | |
38 | ||
39 | private String sTagName; | |
40 | ||
41 | private String sFamily; | |
42 | ||
43 | private boolean bValid; | |
44 | ||
45 | private String sArch; | |
46 | ||
47 | private ArrayList<String> aTargetName = null; | |
48 | ||
49 | private ArrayList<String> aCmdCode = null; | |
50 | ||
51 | private ArrayList<String> aCmdName = null; | |
52 | ||
53 | private ArrayList<String> aPath = null; | |
54 | ||
55 | private ArrayList<String> aBadPath = null; | |
56 | ||
57 | private ArrayList<String> aArguments = null; | |
58 | ||
59 | public ToolInfo() { | |
60 | super(); | |
61 | init(); | |
62 | } | |
63 | ||
64 | private void init() { | |
65 | sTagName = ""; | |
66 | sFamily = ""; | |
67 | bValid = false; | |
68 | sArch = ""; | |
69 | aTargetName = new ArrayList<String>(); | |
70 | aCmdCode = new ArrayList<String>(); | |
71 | aCmdName = new ArrayList<String>(); | |
72 | aPath = new ArrayList<String>(); | |
73 | aArguments = new ArrayList<String>(); | |
74 | aBadPath = new ArrayList<String>(); | |
75 | } | |
76 | ||
77 | public String getTagName() { | |
78 | return this.sTagName.trim(); | |
79 | } | |
80 | ||
81 | public String getFamily() { | |
82 | return this.sFamily.trim(); | |
83 | } | |
84 | ||
85 | public boolean isValid() { | |
86 | return this.bValid; | |
87 | } | |
88 | ||
89 | public String getArch() { | |
90 | return this.sArch.trim(); | |
91 | } | |
92 | ||
93 | public ArrayList<String> getTargetName() { | |
94 | return this.aTargetName; | |
95 | } | |
96 | ||
97 | public String getTargetName(int id) { | |
98 | return this.aTargetName.get(id).trim(); | |
99 | } | |
100 | ||
101 | public ArrayList<String> getCmdCode() { | |
102 | return this.aCmdCode; | |
103 | } | |
104 | ||
105 | public String getCmdCode(int id) { | |
106 | return this.aCmdCode.get(id).trim(); | |
107 | } | |
108 | ||
109 | public ArrayList<String> getCmdName() { | |
110 | return this.aCmdName; | |
111 | } | |
112 | ||
113 | public String getCmdName(int id) { | |
114 | return this.aCmdName.get(id).trim(); | |
115 | } | |
116 | ||
117 | public ArrayList<String> getPath() { | |
118 | return this.aPath; | |
119 | } | |
120 | ||
121 | public String getPath(int id) { | |
122 | return this.aPath.get(id).trim(); | |
123 | } | |
124 | ||
125 | public ArrayList<String> getArguments() { | |
126 | return this.aArguments; | |
127 | } | |
128 | ||
129 | public String getArguments(int id) { | |
130 | return this.aArguments.get(id).trim(); | |
131 | } | |
132 | ||
133 | public ArrayList<String> getBadPath() { | |
134 | return this.aBadPath; | |
135 | } | |
136 | ||
137 | public String getBadPath(int id) { | |
138 | return this.aBadPath.get(id).trim(); | |
139 | } | |
140 | ||
141 | public void setTagName(String val) { | |
142 | this.sTagName = val.trim(); | |
143 | } | |
144 | ||
145 | public void setFamily(String val) { | |
146 | this.sFamily = val.trim(); | |
147 | } | |
148 | ||
149 | public void setValid() { | |
150 | this.bValid = true; | |
151 | } | |
152 | ||
153 | public void setInvalid() { | |
154 | this.bValid = false; | |
155 | } | |
156 | ||
157 | public void setArch(String val) { | |
158 | this.sArch = val.trim(); | |
159 | } | |
160 | ||
161 | public void addTargetName(String val) { | |
162 | this.aTargetName.add(val.trim()); | |
163 | } | |
164 | ||
165 | public void addCmdCode(String val) { | |
166 | this.aCmdCode.add(val.trim()); | |
167 | } | |
168 | ||
169 | public void addCmdName(String val) { | |
170 | this.aCmdName.add(val.trim()); | |
171 | } | |
172 | ||
173 | public void addPath(String val) { | |
174 | this.aPath.add(val.trim()); | |
175 | } | |
176 | ||
177 | public void addArguments(String val) { | |
178 | this.aArguments.add(val.trim()); | |
179 | } | |
180 | ||
181 | public void addBadPath(String val) { | |
182 | this.aBadPath.add(val.trim()); | |
183 | } | |
184 | ||
185 | } |