1 //
2 // ========================================================================
3 // Copyright (c) 1995-2013 Mort Bay Consulting Pty. Ltd.
4 // ------------------------------------------------------------------------
5 // All rights reserved. This program and the accompanying materials
6 // are made available under the terms of the Eclipse Public License v1.0
7 // and Apache License v2.0 which accompanies this distribution.
8 //
9 // The Eclipse Public License is available at
10 // http://www.eclipse.org/legal/epl-v10.html
11 //
12 // The Apache License v2.0 is available at
13 // http://www.opensource.org/licenses/apache2.0.php
14 //
15 // You may elect to redistribute this code under either of these licenses.
16 // ========================================================================
17 //
18
19 package org.eclipse.jetty.maven.plugin;
20
21 import java.io.File;
22 import java.util.Collections;
23 import java.util.List;
24
25 /**
26 * ScanTargetPattern
27 *
28 * Utility class to provide the ability for the mvn jetty:run
29 * mojo to be able to specify filesets of extra files to
30 * regularly scan for changes in order to redeploy the webapp.
31 *
32 * For example:
33 *
34 * <scanTargetPattern>
35 * <directory>/some/place</directory>
36 * <includes>
37 * <include>some ant pattern here </include>
38 * <include>some ant pattern here </include>
39 * </includes>
40 * <excludes>
41 * <exclude>some ant pattern here </exclude>
42 * <exclude>some ant pattern here </exclude>
43 * </excludes>
44 * </scanTargetPattern>
45 */
46 public class ScanTargetPattern
47 {
48 private File _directory;
49 private List _includes = Collections.EMPTY_LIST;
50 private List _excludes = Collections.EMPTY_LIST;
51
52 /**
53 * @return the _directory
54 */
55 public File getDirectory()
56 {
57 return _directory;
58 }
59
60 /**
61 * @param directory the directory to set
62 */
63 public void setDirectory(File directory)
64 {
65 this._directory = directory;
66 }
67
68 public void setIncludes (List includes)
69 {
70 _includes= includes;
71 }
72
73 public void setExcludes(List excludes)
74 {
75 _excludes = excludes;
76 }
77
78 public List getIncludes()
79 {
80 return _includes;
81 }
82
83 public List getExcludes()
84 {
85 return _excludes;
86 }
87
88 }