1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.maven.settings.building;
20
21 import java.io.File;
22 import java.util.Properties;
23
24
25
26
27
28
29 @Deprecated(since = "4.0.0")
30 public class DefaultSettingsBuildingRequest implements SettingsBuildingRequest {
31
32 private File globalSettingsFile;
33
34 private File projectSettingsFile;
35
36 private File userSettingsFile;
37
38 private SettingsSource globalSettingsSource;
39
40 private SettingsSource projectSettingsSource;
41
42 private SettingsSource userSettingsSource;
43
44 private Properties systemProperties;
45
46 private Properties userProperties;
47
48 @Override
49 public File getGlobalSettingsFile() {
50 return globalSettingsFile;
51 }
52
53 @Override
54 public DefaultSettingsBuildingRequest setGlobalSettingsFile(File globalSettingsFile) {
55 this.globalSettingsFile = globalSettingsFile;
56
57 return this;
58 }
59
60 @Override
61 public SettingsSource getGlobalSettingsSource() {
62 return globalSettingsSource;
63 }
64
65 @Override
66 public DefaultSettingsBuildingRequest setGlobalSettingsSource(SettingsSource globalSettingsSource) {
67 this.globalSettingsSource = globalSettingsSource;
68
69 return this;
70 }
71
72 @Override
73 public File getProjectSettingsFile() {
74 return projectSettingsFile;
75 }
76
77 @Override
78 public DefaultSettingsBuildingRequest setProjectSettingsFile(File projectSettingsFile) {
79 this.projectSettingsFile = projectSettingsFile;
80
81 return this;
82 }
83
84 @Override
85 public SettingsSource getProjectSettingsSource() {
86 return projectSettingsSource;
87 }
88
89 @Override
90 public DefaultSettingsBuildingRequest setProjectSettingsSource(SettingsSource projectSettingsSource) {
91 this.projectSettingsSource = projectSettingsSource;
92
93 return this;
94 }
95
96 @Override
97 public File getUserSettingsFile() {
98 return userSettingsFile;
99 }
100
101 @Override
102 public DefaultSettingsBuildingRequest setUserSettingsFile(File userSettingsFile) {
103 this.userSettingsFile = userSettingsFile;
104
105 return this;
106 }
107
108 @Override
109 public SettingsSource getUserSettingsSource() {
110 return userSettingsSource;
111 }
112
113 @Override
114 public DefaultSettingsBuildingRequest setUserSettingsSource(SettingsSource userSettingsSource) {
115 this.userSettingsSource = userSettingsSource;
116
117 return this;
118 }
119
120 @Override
121 public Properties getSystemProperties() {
122 if (systemProperties == null) {
123 systemProperties = new Properties();
124 }
125
126 return systemProperties;
127 }
128
129 @Override
130 public DefaultSettingsBuildingRequest setSystemProperties(Properties systemProperties) {
131 if (systemProperties != null) {
132 this.systemProperties = new Properties();
133 synchronized (systemProperties) {
134
135 this.systemProperties.putAll(systemProperties);
136 }
137 } else {
138 this.systemProperties = null;
139 }
140
141 return this;
142 }
143
144 @Override
145 public Properties getUserProperties() {
146 if (userProperties == null) {
147 userProperties = new Properties();
148 }
149
150 return userProperties;
151 }
152
153 @Override
154 public DefaultSettingsBuildingRequest setUserProperties(Properties userProperties) {
155 if (userProperties != null) {
156 this.userProperties = new Properties();
157 this.userProperties.putAll(userProperties);
158 } else {
159 this.userProperties = null;
160 }
161
162 return this;
163 }
164 }