| 1 | |
package org.apache.maven.project; |
| 2 | |
|
| 3 | |
import org.apache.maven.artifact.repository.ArtifactRepository; |
| 4 | |
import org.apache.maven.profiles.ProfileManager; |
| 5 | |
|
| 6 | |
import java.util.Date; |
| 7 | |
import java.util.Properties; |
| 8 | |
|
| 9 | |
public class DefaultProjectBuilderConfiguration |
| 10 | |
implements ProjectBuilderConfiguration |
| 11 | |
{ |
| 12 | |
|
| 13 | |
private ProfileManager globalProfileManager; |
| 14 | |
|
| 15 | |
private ArtifactRepository localRepository; |
| 16 | |
|
| 17 | |
private Properties userProperties; |
| 18 | |
|
| 19 | 161 | private Properties executionProperties = System.getProperties(); |
| 20 | |
|
| 21 | |
private Date buildStartTime; |
| 22 | |
|
| 23 | |
public DefaultProjectBuilderConfiguration() |
| 24 | 161 | { |
| 25 | 161 | } |
| 26 | |
|
| 27 | |
public ProjectBuilderConfiguration setGlobalProfileManager( ProfileManager globalProfileManager ) |
| 28 | |
{ |
| 29 | 52 | this.globalProfileManager = globalProfileManager; |
| 30 | 52 | return this; |
| 31 | |
} |
| 32 | |
|
| 33 | |
public ProfileManager getGlobalProfileManager() |
| 34 | |
{ |
| 35 | 362 | return globalProfileManager; |
| 36 | |
} |
| 37 | |
|
| 38 | |
public ProjectBuilderConfiguration setLocalRepository( ArtifactRepository localRepository ) |
| 39 | |
{ |
| 40 | 89 | this.localRepository = localRepository; |
| 41 | 89 | return this; |
| 42 | |
} |
| 43 | |
|
| 44 | |
public ArtifactRepository getLocalRepository() |
| 45 | |
{ |
| 46 | 101 | return localRepository; |
| 47 | |
} |
| 48 | |
|
| 49 | |
public ProjectBuilderConfiguration setUserProperties( Properties userProperties ) |
| 50 | |
{ |
| 51 | 0 | this.userProperties = userProperties; |
| 52 | 0 | return this; |
| 53 | |
} |
| 54 | |
|
| 55 | |
public Properties getUserProperties() |
| 56 | |
{ |
| 57 | 523 | if ( userProperties == null ) |
| 58 | |
{ |
| 59 | 161 | userProperties = new Properties(); |
| 60 | |
} |
| 61 | |
|
| 62 | 523 | return userProperties; |
| 63 | |
} |
| 64 | |
|
| 65 | |
public Properties getExecutionProperties() |
| 66 | |
{ |
| 67 | 990 | return executionProperties; |
| 68 | |
} |
| 69 | |
|
| 70 | |
public ProjectBuilderConfiguration setExecutionProperties( Properties executionProperties ) |
| 71 | |
{ |
| 72 | 36 | this.executionProperties = executionProperties; |
| 73 | 36 | return this; |
| 74 | |
} |
| 75 | |
|
| 76 | |
public Date getBuildStartTime() |
| 77 | |
{ |
| 78 | 523 | return buildStartTime; |
| 79 | |
} |
| 80 | |
|
| 81 | |
public ProjectBuilderConfiguration setBuildStartTime( Date buildStartTime ) |
| 82 | |
{ |
| 83 | 0 | this.buildStartTime = buildStartTime; |
| 84 | 0 | return this; |
| 85 | |
} |
| 86 | |
|
| 87 | |
} |