001    /**
002     * Copyright 2010-2013 The Kuali Foundation
003     *
004     * Licensed under the Educational Community License, Version 2.0 (the "License");
005     * you may not use this file except in compliance with the License.
006     * You may obtain a copy of the License at
007     *
008     * http://www.opensource.org/licenses/ecl2.php
009     *
010     * Unless required by applicable law or agreed to in writing, software
011     * distributed under the License is distributed on an "AS IS" BASIS,
012     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013     * See the License for the specific language governing permissions and
014     * limitations under the License.
015     */
016    package org.kuali.common.util.service;
017    
018    import java.io.File;
019    import java.util.List;
020    import java.util.Properties;
021    
022    public class MavenContext {
023    
024            public static final String DEFAULT_EXECUTABLE = "mvn";
025            public static final String MAVEN_OPTS = "MAVEN_OPTS";
026    
027            String executable = DEFAULT_EXECUTABLE;
028            boolean inheritMavenOpts = true;
029            File workingDir;
030            File pom;
031            boolean debug;
032            boolean errors;
033            boolean batchMode;
034            boolean quiet;
035            boolean offline;
036            List<String> profiles;
037            List<String> options;
038            List<String> goals;
039            List<String> phases;
040            List<String> passThroughPropertyKeys;
041            Properties properties;
042    
043            public String getExecutable() {
044                    return executable;
045            }
046    
047            public void setExecutable(String executable) {
048                    this.executable = executable;
049            }
050    
051            public File getWorkingDir() {
052                    return workingDir;
053            }
054    
055            public void setWorkingDir(File workingDir) {
056                    this.workingDir = workingDir;
057            }
058    
059            public File getPom() {
060                    return pom;
061            }
062    
063            public void setPom(File pom) {
064                    this.pom = pom;
065            }
066    
067            public boolean isDebug() {
068                    return debug;
069            }
070    
071            public void setDebug(boolean debug) {
072                    this.debug = debug;
073            }
074    
075            public boolean isErrors() {
076                    return errors;
077            }
078    
079            public void setErrors(boolean errors) {
080                    this.errors = errors;
081            }
082    
083            public boolean isBatchMode() {
084                    return batchMode;
085            }
086    
087            public void setBatchMode(boolean batchMode) {
088                    this.batchMode = batchMode;
089            }
090    
091            public boolean isQuiet() {
092                    return quiet;
093            }
094    
095            public void setQuiet(boolean quiet) {
096                    this.quiet = quiet;
097            }
098    
099            public boolean isOffline() {
100                    return offline;
101            }
102    
103            public void setOffline(boolean offline) {
104                    this.offline = offline;
105            }
106    
107            public List<String> getOptions() {
108                    return options;
109            }
110    
111            public void setOptions(List<String> options) {
112                    this.options = options;
113            }
114    
115            public List<String> getGoals() {
116                    return goals;
117            }
118    
119            public void setGoals(List<String> goals) {
120                    this.goals = goals;
121            }
122    
123            public List<String> getPhases() {
124                    return phases;
125            }
126    
127            public void setPhases(List<String> phases) {
128                    this.phases = phases;
129            }
130    
131            public boolean isInheritMavenOpts() {
132                    return inheritMavenOpts;
133            }
134    
135            public void setInheritMavenOpts(boolean inheritMavenOpts) {
136                    this.inheritMavenOpts = inheritMavenOpts;
137            }
138    
139            public List<String> getProfiles() {
140                    return profiles;
141            }
142    
143            public void setProfiles(List<String> profiles) {
144                    this.profiles = profiles;
145            }
146    
147            public List<String> getPassThroughPropertyKeys() {
148                    return passThroughPropertyKeys;
149            }
150    
151            public void setPassThroughPropertyKeys(List<String> passThroughPropertyKeys) {
152                    this.passThroughPropertyKeys = passThroughPropertyKeys;
153            }
154    
155            public Properties getProperties() {
156                    return properties;
157            }
158    
159            public void setProperties(Properties properties) {
160                    this.properties = properties;
161            }
162    
163    }