You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by el...@apache.org on 2015/04/07 11:40:18 UTC
svn commit: r1671775 - in
/directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model:
OlcBackendConfig.java OlcIncludeFile.java OlcLDAPConfig.java
OlcModuleList.java OlcOverlayConfig.java
Author: elecharny
Date: Tue Apr 7 09:40:17 2015
New Revision: 1671775
URL: http://svn.apache.org/r1671775
Log:
o Added the missing OlcBackendConfig and OlcIncludeFile classes
o Used the copyListString method to avoid a modification by the caller
o Added the olcDisabled attribute in the OlcOverlayConfig class
Added:
directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcBackendConfig.java
directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcIncludeFile.java
Modified:
directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcLDAPConfig.java
directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcModuleList.java
directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcOverlayConfig.java
Added: directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcBackendConfig.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcBackendConfig.java?rev=1671775&view=auto
==============================================================================
--- directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcBackendConfig.java (added)
+++ directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcBackendConfig.java Tue Apr 7 09:40:17 2015
@@ -0,0 +1,83 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+package org.apache.directory.studio.openldap.config.model;
+
+
+/**
+ * Java bean for the 'olcBackendConfig' object class.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public class OlcBackendConfig extends OlcConfig
+{
+ /**
+ * Field for the 'olcBackend' attribute.
+ */
+ @ConfigurationElement(attributeType = "olcBackend", isOptional = false)
+ private String olcBackend;
+
+
+ /**
+ * Creates a new instance of olcBackendConfig.
+ */
+ public OlcBackendConfig()
+ {
+ }
+
+
+ /**
+ * Creates a copy instance of olcBackendConfig.
+ *
+ * @param o the initial object
+ */
+ public OlcBackendConfig( OlcBackendConfig o )
+ {
+ olcBackend = o.olcBackend;
+ }
+
+
+ /**
+ * @return the olcBackend
+ */
+ public String getOlcBackend()
+ {
+ return olcBackend;
+ }
+
+
+ /**
+ * @param olcBackend the olcBackend to set
+ */
+ public void setOlcBackend( String olcBackend )
+ {
+ this.olcBackend = olcBackend;
+ }
+
+
+ /**
+ * Gets a copy of this object.
+ *
+ * @return a copy of this object
+ */
+ public OlcBackendConfig copy()
+ {
+ return new OlcBackendConfig( this );
+ }
+}
Added: directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcIncludeFile.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcIncludeFile.java?rev=1671775&view=auto
==============================================================================
--- directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcIncludeFile.java (added)
+++ directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcIncludeFile.java Tue Apr 7 09:40:17 2015
@@ -0,0 +1,191 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+package org.apache.directory.studio.openldap.config.model;
+
+
+import java.util.ArrayList;
+import java.util.List;
+
+
+/**
+ * Java bean for the 'olcIncludeFile' object class.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public class OlcIncludeFile extends OlcConfig
+{
+ /**
+ * Field for the 'cn' attribute.
+ */
+ @ConfigurationElement(attributeType = "cn", isRdn = true)
+ private List<String> cn = new ArrayList<String>();
+
+ /**
+ * Field for the 'olcInclude' attribute.
+ */
+ @ConfigurationElement(attributeType = "olcInclude", isOptional = false)
+ private List<String> olcInclude = new ArrayList<String>();
+
+ /**
+ * Field for the 'olcRootDSE' attribute.
+ */
+ @ConfigurationElement(attributeType = "olcRootDSE")
+ private List<String> olcRootDSE = new ArrayList<String>();
+
+
+ /**
+ * Creates a new instance of olcBackendConfig.
+ */
+ public OlcIncludeFile()
+ {
+ }
+
+
+ /**
+ * Creates a copy instance of olcInclude.
+ *
+ * @param o the initial object
+ */
+ public OlcIncludeFile( OlcIncludeFile o )
+ {
+ olcInclude = copyListString( o.olcInclude );
+ }
+
+
+ /**
+ * @param strings
+ */
+ public void addCn( String... strings )
+ {
+ for ( String string : strings )
+ {
+ cn.add( string );
+ }
+ }
+
+
+ /**
+ * @param strings
+ */
+ public void addOlcInclude( String... strings )
+ {
+ for ( String string : strings )
+ {
+ olcInclude.add( string );
+ }
+ }
+
+
+ /**
+ * @param strings
+ */
+ public void addOlcRootDSE( String... strings )
+ {
+ for ( String string : strings )
+ {
+ olcRootDSE.add( string );
+ }
+ }
+
+
+ public void clearCn()
+ {
+ cn.clear();
+ }
+
+
+ /**
+ */
+ public void clearOlcInclude()
+ {
+ olcInclude.clear();
+ }
+
+
+ public void clearOlcRootDSE()
+ {
+ olcRootDSE.clear();
+ }
+
+
+ /**
+ * @return the cn
+ */
+ public List<String> getCn()
+ {
+ return copyListString( cn );
+ }
+
+
+ /**
+ * @return the olcInclude
+ */
+ public List<String> getOlcInclude()
+ {
+ return copyListString( olcInclude );
+ }
+
+
+ /**
+ * @return the olcRootDSE
+ */
+ public List<String> getOlcRootDSE()
+ {
+ return copyListString( olcRootDSE );
+ }
+
+
+ /**
+ * @param cn the cn to set
+ */
+ public void setCn( List<String> cn )
+ {
+ this.cn = copyListString( cn );
+ }
+
+
+ /**
+ * @param olcInclude the olcInclude to set
+ */
+ public void setOlcInclude( List<String> olcInclude )
+ {
+ this.olcInclude = copyListString( olcInclude );
+ }
+
+
+ /**
+ * @param olcRootDSE the olcRootDSE to set
+ */
+ public void setOlcRootDSE( List<String> olcRootDSE )
+ {
+ this.olcRootDSE = copyListString( olcRootDSE );
+ }
+
+
+ /**
+ * Gets a copy of this object.
+ *
+ * @return a copy of this object
+ */
+ public OlcIncludeFile copy()
+ {
+ return new OlcIncludeFile( this );
+ }
+}
Modified: directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcLDAPConfig.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcLDAPConfig.java?rev=1671775&r1=1671774&r2=1671775&view=diff
==============================================================================
--- directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcLDAPConfig.java (original)
+++ directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcLDAPConfig.java Tue Apr 7 09:40:17 2015
@@ -118,7 +118,7 @@ public class OlcLDAPConfig extends OlcDa
private String olcDbIdleTimeout;
/**
- * Field for the 'olcDbKeepalive' attribute.
+ * Field for the 'olcDbKeepalive' attribute. (Added in OpenLDAP 2.4.34)
*/
@ConfigurationElement(attributeType = "olcDbKeepalive")
private String olcDbKeepalive;
@@ -142,7 +142,7 @@ public class OlcLDAPConfig extends OlcDa
private Boolean olcDbNoUndefFilter;
/**
- * Field for the 'olcDbOnErr' attribute.
+ * Field for the 'olcDbOnErr' attribute. (Added in OpenLDAP 2.4.34)
*/
@ConfigurationElement(attributeType = "olcDbOnErr")
private String olcDbOnErr;
Modified: directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcModuleList.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcModuleList.java?rev=1671775&r1=1671774&r2=1671775&view=diff
==============================================================================
--- directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcModuleList.java (original)
+++ directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcModuleList.java Tue Apr 7 09:40:17 2015
@@ -91,7 +91,7 @@ public class OlcModuleList extends OlcCo
*/
public List<String> getCn()
{
- return cn;
+ return copyListString( cn );
}
@@ -100,7 +100,7 @@ public class OlcModuleList extends OlcCo
*/
public List<String> getOlcModuleLoad()
{
- return olcModuleLoad;
+ return copyListString( olcModuleLoad );
}
@@ -118,7 +118,7 @@ public class OlcModuleList extends OlcCo
*/
public void setCn( List<String> cn )
{
- this.cn = cn;
+ this.cn = copyListString( cn );
}
@@ -127,7 +127,7 @@ public class OlcModuleList extends OlcCo
*/
public void setOlcModuleLoad( List<String> olcModuleLoad )
{
- this.olcModuleLoad = olcModuleLoad;
+ this.olcModuleLoad = copyListString( olcModuleLoad );
}
Modified: directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcOverlayConfig.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcOverlayConfig.java?rev=1671775&r1=1671774&r2=1671775&view=diff
==============================================================================
--- directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcOverlayConfig.java (original)
+++ directory/studio/trunk/plugins/openldap.config.editor/src/main/java/org/apache/directory/studio/openldap/config/model/OlcOverlayConfig.java Tue Apr 7 09:40:17 2015
@@ -28,6 +28,12 @@ package org.apache.directory.studio.open
public class OlcOverlayConfig extends OlcConfig
{
/**
+ * Field for the 'olcDisabled' attribute. (Added in OpenLDAP 2.4.36)
+ */
+ @ConfigurationElement(attributeType = "olcDisabled")
+ private Boolean olcDisabled;
+
+ /**
* Field for the 'olcOverlay' attribute.
*/
@ConfigurationElement(attributeType = "olcOverlay", isOptional = false, isRdn = true)
@@ -54,6 +60,15 @@ public class OlcOverlayConfig extends Ol
/**
+ * @return the olcDisabled
+ */
+ public Boolean getOlcDisabled()
+ {
+ return olcDisabled;
+ }
+
+
+ /**
* @return the olcOverlay
*/
public String getOlcOverlay()
@@ -62,6 +77,15 @@ public class OlcOverlayConfig extends Ol
}
+ /**
+ * @param oldDisabled the olcDisabled to set
+ */
+ public void setOlcDisabled( Boolean olcDisabled )
+ {
+ this.olcDisabled = olcDisabled;
+ }
+
+
/**
* @param olcOverlay the olcOverlay to set
*/