]> git.proxmox.com Git - mirror_edk2.git/blame - Tools/Source/FrameworkTasks/org/tianocore/framework/tasks/SkipExt.java
Updated PeiRebase to produce a map file of the relocations done by this tool. This...
[mirror_edk2.git] / Tools / Source / FrameworkTasks / org / tianocore / framework / tasks / SkipExt.java
CommitLineData
878ddf1f 1/** @file\r
2This file is to define nested element which is meant for specifying skipped file list\r
3\r
4Copyright (c) 2006, Intel Corporation\r
5All rights reserved. This program and the accompanying materials\r
6are licensed and made available under the terms and conditions of the BSD License\r
7which accompanies this distribution. The full text of the license may be found at\r
8http://opensource.org/licenses/bsd-license.php\r
9\r
10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
12\r
13**/\r
14package org.tianocore.framework.tasks;\r
15\r
16import java.io.File;\r
17import java.util.ArrayList;\r
18import java.util.List;\r
19import java.util.StringTokenizer;\r
20\r
21/**\r
22 SkipExt nested element Class\r
23 class member\r
24 -name : extension name of skiped file \r
25 -file : name of file including ext\r
26 **/\r
27public class SkipExt implements NestElement {\r
28 private String name = "";\r
29 private File file;\r
30 private List<String> nameList = new ArrayList<String>();\r
31 \r
32 /**\r
33 get class member "name"\r
34 @returns name parameter\r
35 **/\r
36 public String getName() {\r
37 return this.name;\r
38 }\r
39 /**\r
40 set class member "name"\r
41 @param name extension name of skiped file \r
42 **/\r
43 public void setName(String name) {\r
44 this.name = " -skipext " + name;\r
45 }\r
46\r
47 public String toString() {\r
48 return getName();\r
49 }\r
50\r
51 /**\r
52 get class member "file"\r
53 @returns file parameter\r
54 **/\r
55 public File getFile() {\r
56 return this.file;\r
57 }\r
58 /**\r
59 set class member "file"\r
60 @param name of file including ext \r
61 **/\r
62 public void setFile(File file) {\r
63 this.file = file;\r
64 }\r
65\r
66 public void setList(String fileNameList) {\r
67 if (fileNameList != null && fileNameList.length() > 0) {\r
68 StringTokenizer tokens = new StringTokenizer(fileNameList, " \t,;", false);\r
69 while (tokens.hasMoreTokens()) {\r
70 String fileName = tokens.nextToken().trim();\r
71 if (fileName.length() > 0) {\r
72 this.nameList.add(fileName);\r
73 }\r
74 }\r
75 }\r
76 }\r
77\r
78 public List<String> getList() {\r
79 return nameList;\r
80 }\r
81 \r
82}\r
83\r