This project has retired. For details please refer to its
Attic page.
RedbackRuntimeConfiguration xref
1 package org.apache.archiva.admin.model.beans;
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21 import javax.xml.bind.annotation.XmlRootElement;
22 import java.io.Serializable;
23 import java.util.ArrayList;
24 import java.util.Collections;
25 import java.util.HashMap;
26 import java.util.List;
27 import java.util.Map;
28
29
30
31
32
33 @XmlRootElement(name = "redbackRuntimeConfiguration")
34 public class RedbackRuntimeConfiguration
35 implements Serializable
36 {
37
38
39
40
41 private List<String> userManagerImpls = new ArrayList<>();
42
43
44
45
46 private java.util.List<String> rbacManagerImpls = new ArrayList<>();
47
48 private LdapConfiguration ldapConfiguration;
49
50
51
52
53 private boolean migratedFromRedbackConfiguration = false;
54
55 private Map<String, String> configurationProperties;
56
57
58
59
60 private List<PropertyEntry> configurationPropertiesEntries;
61
62
63
64
65
66 private boolean useUsersCache = true;
67
68 private CacheConfiguration usersCacheConfiguration;
69
70
71
72
73 private List<LdapGroupMapping> ldapGroupMappings;
74
75 public RedbackRuntimeConfiguration()
76 {
77
78 }
79
80 public List<String> getUserManagerImpls()
81 {
82 return userManagerImpls;
83 }
84
85 public void setUserManagerImpls( List<String> userManagerImpls )
86 {
87 this.userManagerImpls = userManagerImpls;
88 }
89
90 public LdapConfiguration getLdapConfiguration()
91 {
92 return ldapConfiguration;
93 }
94
95 public void setLdapConfiguration( LdapConfiguration ldapConfiguration )
96 {
97 this.ldapConfiguration = ldapConfiguration;
98 }
99
100 public boolean isMigratedFromRedbackConfiguration()
101 {
102 return migratedFromRedbackConfiguration;
103 }
104
105 public void setMigratedFromRedbackConfiguration( boolean migratedFromRedbackConfiguration )
106 {
107 this.migratedFromRedbackConfiguration = migratedFromRedbackConfiguration;
108 }
109
110 public Map<String, String> getConfigurationProperties()
111 {
112 if ( this.configurationProperties == null )
113 {
114 this.configurationProperties = new HashMap<>();
115 }
116 return configurationProperties;
117 }
118
119 public void setConfigurationProperties( Map<String, String> configurationProperties )
120 {
121 this.configurationProperties = configurationProperties;
122 }
123
124 public List<PropertyEntry> getConfigurationPropertiesEntries()
125 {
126 configurationPropertiesEntries = new ArrayList<PropertyEntry>( getConfigurationProperties().size() );
127 for ( Map.Entry<String, String> entry : getConfigurationProperties().entrySet() )
128 {
129 configurationPropertiesEntries.add( new PropertyEntry( entry.getKey(), entry.getValue() ) );
130 }
131 Collections.sort( configurationPropertiesEntries );
132 return configurationPropertiesEntries;
133 }
134
135 public void setConfigurationPropertiesEntries( List<PropertyEntry> configurationPropertiesEntries )
136 {
137 this.configurationPropertiesEntries = configurationPropertiesEntries;
138 if ( configurationPropertiesEntries != null )
139 {
140 this.configurationProperties = new HashMap<>( configurationPropertiesEntries.size() );
141 for ( PropertyEntry propertyEntry : configurationPropertiesEntries )
142 {
143 this.configurationProperties.put( propertyEntry.getKey(), propertyEntry.getValue() );
144 }
145 }
146 }
147
148 public boolean isUseUsersCache()
149 {
150 return useUsersCache;
151 }
152
153 public void setUseUsersCache( boolean useUsersCache )
154 {
155 this.useUsersCache = useUsersCache;
156 }
157
158 public CacheConfiguration getUsersCacheConfiguration()
159 {
160 return usersCacheConfiguration;
161 }
162
163 public void setUsersCacheConfiguration( CacheConfiguration usersCacheConfiguration )
164 {
165 this.usersCacheConfiguration = usersCacheConfiguration;
166 }
167
168 public List<String> getRbacManagerImpls()
169 {
170 return rbacManagerImpls;
171 }
172
173 public void setRbacManagerImpls( List<String> rbacManagerImpls )
174 {
175 this.rbacManagerImpls = rbacManagerImpls;
176 }
177
178 public List<LdapGroupMapping> getLdapGroupMappings()
179 {
180 return ldapGroupMappings;
181 }
182
183 public void setLdapGroupMappings( List<LdapGroupMapping> ldapGroupMappings )
184 {
185 this.ldapGroupMappings = ldapGroupMappings;
186 }
187
188 @Override
189 public String toString()
190 {
191 final StringBuilder sb = new StringBuilder();
192 sb.append( "RedbackRuntimeConfiguration" );
193 sb.append( "{userManagerImpls=" ).append( userManagerImpls );
194 sb.append( ", rbacManagerImpls=" ).append( rbacManagerImpls );
195 sb.append( ", ldapConfiguration=" ).append( ldapConfiguration );
196 sb.append( ", migratedFromRedbackConfiguration=" ).append( migratedFromRedbackConfiguration );
197 sb.append( ", configurationProperties=" ).append( configurationProperties );
198 sb.append( ", configurationPropertiesEntries=" ).append( configurationPropertiesEntries );
199 sb.append( ", useUsersCache=" ).append( useUsersCache );
200 sb.append( ", usersCacheConfiguration=" ).append( usersCacheConfiguration );
201 sb.append( '}' );
202 return sb.toString();
203 }
204 }