| | |
| | | */ |
| | | protected Backend() |
| | | { |
| | | |
| | | backendID = null; |
| | | parentBackend = null; |
| | | subordinateBackends = new Backend[0]; |
| | |
| | | public boolean entryExists(DN entryDN) |
| | | throws DirectoryException |
| | | { |
| | | |
| | | Lock lock = null; |
| | | for (int i=0; i < 3; i++) |
| | | { |
| | |
| | | */ |
| | | public final boolean supportsControl(String controlOID) |
| | | { |
| | | |
| | | Set<String> supportedControls = getSupportedControls(); |
| | | return ((supportedControls != null) && |
| | | supportedControls.contains(controlOID)); |
| | |
| | | */ |
| | | public final boolean supportsFeature(String featureOID) |
| | | { |
| | | |
| | | Set<String> supportedFeatures = getSupportedFeatures(); |
| | | return ((supportedFeatures != null) && |
| | | supportedFeatures.contains(featureOID)); |
| | |
| | | */ |
| | | public String getBackendID() |
| | | { |
| | | |
| | | return backendID; |
| | | } |
| | | |
| | |
| | | */ |
| | | public void setBackendID(String backendID) |
| | | { |
| | | |
| | | this.backendID = backendID; |
| | | } |
| | | |
| | |
| | | */ |
| | | public boolean isPrivateBackend() |
| | | { |
| | | |
| | | return isPrivateBackend; |
| | | } |
| | | |
| | |
| | | */ |
| | | public WritabilityMode getWritabilityMode() |
| | | { |
| | | |
| | | return writabilityMode; |
| | | } |
| | | |
| | |
| | | */ |
| | | public void setWritabilityMode(WritabilityMode writabilityMode) |
| | | { |
| | | |
| | | if (writabilityMode == null) |
| | | { |
| | | this.writabilityMode = WritabilityMode.ENABLED; |
| | |
| | | */ |
| | | public BackendMonitor getBackendMonitor() |
| | | { |
| | | |
| | | return backendMonitor; |
| | | } |
| | | |
| | |
| | | */ |
| | | public void setBackendMonitor(BackendMonitor backendMonitor) |
| | | { |
| | | |
| | | this.backendMonitor = backendMonitor; |
| | | } |
| | | |
| | |
| | | */ |
| | | public Backend getParentBackend() |
| | | { |
| | | |
| | | return parentBackend; |
| | | } |
| | | |
| | |
| | | */ |
| | | public void setParentBackend(Backend parentBackend) |
| | | { |
| | | |
| | | synchronized (this) |
| | | { |
| | | this.parentBackend = parentBackend; |
| | |
| | | */ |
| | | public Backend[] getSubordinateBackends() |
| | | { |
| | | |
| | | return subordinateBackends; |
| | | } |
| | | |
| | |
| | | */ |
| | | public void setSubordinateBackends(Backend[] subordinateBackends) |
| | | { |
| | | |
| | | synchronized (this) |
| | | { |
| | | this.subordinateBackends = subordinateBackends; |
| | |
| | | */ |
| | | public boolean hasSubSuffix(DN subSuffixDN) |
| | | { |
| | | |
| | | Backend[] subBackends = subordinateBackends; |
| | | for (Backend b : subBackends) |
| | | { |
| | |
| | | public void removeSubSuffix(DN subSuffixDN, DN parentDN) |
| | | throws ConfigException |
| | | { |
| | | |
| | | synchronized (this) |
| | | { |
| | | boolean matchFound = false; |
| | |
| | | */ |
| | | public void addSubordinateBackend(Backend subordinateBackend) |
| | | { |
| | | |
| | | synchronized (this) |
| | | { |
| | | LinkedHashSet<Backend> backendSet = |
| | |
| | | */ |
| | | public void removeSubordinateBackend(Backend subordinateBackend) |
| | | { |
| | | |
| | | synchronized (this) |
| | | { |
| | | ArrayList<Backend> backendList = |
| | |
| | | */ |
| | | public boolean handlesEntry(DN entryDN) |
| | | { |
| | | |
| | | DN[] baseDNs = getBaseDNs(); |
| | | for (int i=0; i < baseDNs.length; i++) |
| | | { |
| | |
| | | List<DN> baseDNs, |
| | | List<DN> excludeDNs) |
| | | { |
| | | |
| | | for (DN baseDN : baseDNs) |
| | | { |
| | | if (entryDN.isDescendantOf(baseDN)) |