1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 package installtoolkit;
19
20 /**
21 * Helper class to store a pattern construct from the descriptor file
22 *
23 * @author Christian Elberfeld <elberfeld@web.de>
24 */
25 public class Pattern {
26
27
28 private String pattern;
29 private boolean invert;
30
31 /**
32 * Construct the pattern
33 *
34 * @param pattern the pattern string
35 * @param invert true if this pattern excludes files, false if this pattern includes files
36 */
37 public Pattern(String pattern, boolean invert) {
38
39 this.pattern = pattern;
40 this.invert = invert;
41 }
42
43 /**
44 * @see Object#toString()
45 */
46 @Override
47 public String toString() {
48
49 return "Pattern [pattern: "+this.pattern+" / invert: "+this.invert+"]";
50 }
51
52 public boolean isInvert() {
53 return invert;
54 }
55
56 public String getPattern() {
57 return pattern;
58 }
59
60
61 }