You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by ak...@apache.org on 2011/03/20 19:55:09 UTC
svn commit: r1083535 - in /directory/studio/branches/akarasulu/plugins:
ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/actions/
ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/
sche...
Author: akarasulu
Date: Sun Mar 20 18:55:08 2011
New Revision: 1083535
URL: http://svn.apache.org/viewvc?rev=1083535&view=rev
Log:
fixing build for use of interfaces instead of implementation objects
Modified:
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/actions/OpenSchemaBrowserAction.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/AttributeTypeDescriptionDetailsPage.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleDescriptionDetailsPage.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleUseDescriptionDetailsPage.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowser.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserInput.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserManager.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserNavigationLocation.java
directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaDetailsPage.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaHandler.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/DependenciesComputer.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/Schema.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/GenericSchemaConnector.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/XMLSchemaFileExporter.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoader.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoaderUtils.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboContentProvider.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATESyntaxComboContentProvider.java
directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/AttributeTypeEditorOverviewPage.java
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/actions/OpenSchemaBrowserAction.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/actions/OpenSchemaBrowserAction.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/actions/OpenSchemaBrowserAction.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/actions/OpenSchemaBrowserAction.java Sun Mar 20 18:55:08 2011
@@ -17,13 +17,12 @@
* under the License.
*
*/
-
package org.apache.directory.studio.ldapbrowser.ui.actions;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.studio.connection.core.Connection;
import org.apache.directory.studio.ldapbrowser.common.actions.BrowserAction;
@@ -281,7 +280,7 @@ public class OpenSchemaBrowserAction ext
* @return
* the LDAP Syntax Description
*/
- private MutableLdapSyntaxImpl getLsd()
+ private LdapSyntax getLsd()
{
if ( getConnection() != null )
{
@@ -414,7 +413,7 @@ public class OpenSchemaBrowserAction ext
* @return
* the Equality Matching Rule Description
*/
- private MutableMatchingRuleImpl getEmrd()
+ private MatchingRule getEmrd()
{
if ( getConnection() != null )
{
@@ -439,7 +438,7 @@ public class OpenSchemaBrowserAction ext
* @return
* the Substring Matching Rule Description
*/
- private MutableMatchingRuleImpl getSmrd()
+ private MatchingRule getSmrd()
{
if ( getConnection() != null )
{
@@ -464,7 +463,7 @@ public class OpenSchemaBrowserAction ext
* @return
* the Ordering Matching Rule Description
*/
- private MutableMatchingRuleImpl getOmrd()
+ private MatchingRule getOmrd()
{
if ( getConnection() != null )
{
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/AttributeTypeDescriptionDetailsPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/AttributeTypeDescriptionDetailsPage.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/AttributeTypeDescriptionDetailsPage.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/AttributeTypeDescriptionDetailsPage.java Sun Mar 20 18:55:08 2011
@@ -24,8 +24,8 @@ package org.apache.directory.studio.ldap
import java.util.Collection;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.UsageEnum;
import org.apache.directory.studio.ldapbrowser.core.model.schema.SchemaUtils;
@@ -362,7 +362,7 @@ public class AttributeTypeDescriptionDet
// set syntax content
String lsdOid = null;
- MutableLdapSyntaxImpl lsd = null;
+ LdapSyntax lsd = null;
long lsdLength = 0;
if ( atd != null )
{
@@ -383,7 +383,7 @@ public class AttributeTypeDescriptionDet
// set matching rules content
String emrOid = null;
- MutableMatchingRuleImpl emr = null;
+ MatchingRule emr = null;
if ( atd != null )
{
emrOid = SchemaUtils.getEqualityMatchingRuleNameOrNumericOidTransitive( atd, getSchema() );
@@ -398,7 +398,7 @@ public class AttributeTypeDescriptionDet
equalityLink.setEnabled( emr != null );
String smrOid = null;
- MutableMatchingRuleImpl smr = null;
+ MatchingRule smr = null;
if ( atd != null )
{
smrOid = SchemaUtils.getSubstringMatchingRuleNameOrNumericOidTransitive( atd, getSchema() );
@@ -413,7 +413,7 @@ public class AttributeTypeDescriptionDet
substringLink.setEnabled( smr != null );
String omrOid = null;
- MutableMatchingRuleImpl omr = null;
+ MatchingRule omr = null;
if ( atd != null )
{
omrOid = SchemaUtils.getOrderingMatchingRuleNameOrNumericOidTransitive( atd, getSchema() );
@@ -532,7 +532,7 @@ public class AttributeTypeDescriptionDet
{
if ( getSchema().hasMatchingRuleDescription( mrdName ) )
{
- MutableMatchingRuleImpl mrd = getSchema().getMatchingRuleDescription( mrdName );
+ MatchingRule mrd = getSchema().getMatchingRuleDescription( mrdName );
Hyperlink otherMatchLink = toolkit.createHyperlink( otherMatchClient, SchemaUtils
.toString( mrd ), SWT.WRAP );
otherMatchLink.setHref( mrd );
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleDescriptionDetailsPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleDescriptionDetailsPage.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleDescriptionDetailsPage.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleDescriptionDetailsPage.java Sun Mar 20 18:55:08 2011
@@ -17,16 +17,14 @@
* under the License.
*
*/
-
package org.apache.directory.studio.ldapbrowser.ui.editors.schemabrowser;
import java.util.Collection;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
import org.apache.directory.shared.ldap.model.schema.MatchingRule;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
import org.apache.directory.studio.ldapbrowser.core.model.schema.Schema;
import org.apache.directory.studio.ldapbrowser.core.model.schema.SchemaUtils;
import org.eclipse.osgi.util.NLS;
@@ -188,10 +186,10 @@ public class MatchingRuleDescriptionDeta
*/
public void setInput( Object input )
{
- MutableMatchingRuleImpl mrd = null;
+ MatchingRule mrd = null;
if ( input instanceof MatchingRule )
{
- mrd = ( MutableMatchingRuleImpl ) input;
+ mrd = ( MatchingRule ) input;
}
// create main content
@@ -202,7 +200,7 @@ public class MatchingRuleDescriptionDeta
// set syntax content
String lsdOid = null;
- MutableLdapSyntaxImpl lsd = null;
+ LdapSyntax lsd = null;
if ( mrd != null )
{
Schema schema = getSchema();
@@ -234,7 +232,7 @@ public class MatchingRuleDescriptionDeta
*
* @param mrd the matching rule description
*/
- private void createMainContent( MutableMatchingRuleImpl mrd )
+ private void createMainContent( MatchingRule mrd )
{
// dispose old content
if ( mainSection.getClient() != null )
@@ -283,7 +281,7 @@ public class MatchingRuleDescriptionDeta
*
* @param mrd the matching rule description
*/
- private void createUsedFromContents( MutableMatchingRuleImpl mrd )
+ private void createUsedFromContents( MatchingRule mrd )
{
// dispose old content
if ( usedFromSection.getClient() != null )
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleUseDescriptionDetailsPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleUseDescriptionDetailsPage.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleUseDescriptionDetailsPage.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/MatchingRuleUseDescriptionDetailsPage.java Sun Mar 20 18:55:08 2011
@@ -17,14 +17,13 @@
* under the License.
*
*/
-
package org.apache.directory.studio.ldapbrowser.ui.editors.schemabrowser;
import java.util.List;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
import org.apache.directory.shared.ldap.model.schema.MatchingRuleUse;
import org.apache.directory.studio.ldapbrowser.core.model.schema.Schema;
import org.apache.directory.studio.ldapbrowser.core.model.schema.SchemaUtils;
@@ -201,7 +200,7 @@ public class MatchingRuleUseDescriptionD
nameLink.addHyperlinkListener( this );
Schema schema = getSchema();
- MutableMatchingRuleImpl mrd = schema.hasMatchingRuleDescription( mrud.getOid() ) ? schema
+ MatchingRule mrd = schema.hasMatchingRuleDescription( mrud.getOid() ) ? schema
.getMatchingRuleDescription( mrud.getOid() ) : null;
nameLink
.setText( getNonNullString( mrd != null ? SchemaUtils.toString( mrd ) : SchemaUtils.toString( mrud ) ) );
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowser.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowser.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowser.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowser.java Sun Mar 20 18:55:08 2011
@@ -21,12 +21,12 @@
package org.apache.directory.studio.ldapbrowser.ui.editors.schemabrowser;
-import org.apache.directory.shared.ldap.model.schema.AbstractSchemaObject;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
import org.apache.directory.shared.ldap.model.schema.MatchingRule;
import org.apache.directory.shared.ldap.model.schema.MatchingRuleUse;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
+import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.studio.ldapbrowser.core.model.IBrowserConnection;
import org.apache.directory.studio.ldapbrowser.ui.BrowserUIConstants;
import org.apache.directory.studio.ldapbrowser.ui.BrowserUIPlugin;
@@ -203,7 +203,7 @@ public class SchemaBrowser extends Edito
setConnection( connection );
// set schema element and activate tab
- AbstractSchemaObject schemaElement = sbi.getSchemaElement();
+ SchemaObject schemaElement = sbi.getSchemaElement();
if ( schemaElement instanceof ObjectClass )
{
ocdPage.select( schemaElement );
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserInput.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserInput.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserInput.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserInput.java Sun Mar 20 18:55:08 2011
@@ -17,11 +17,10 @@
* under the License.
*
*/
-
package org.apache.directory.studio.ldapbrowser.ui.editors.schemabrowser;
-import org.apache.directory.shared.ldap.model.schema.AbstractSchemaObject;
+import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.studio.ldapbrowser.core.model.IBrowserConnection;
import org.apache.directory.studio.ldapbrowser.ui.BrowserUIConstants;
import org.apache.directory.studio.ldapbrowser.ui.BrowserUIPlugin;
@@ -54,7 +53,7 @@ public class SchemaBrowserInput implemen
private IBrowserConnection connection;
/** The schema element */
- private AbstractSchemaObject schemaElement;
+ private SchemaObject schemaElement;
/** One instance hack flag */
private static boolean oneInstanceHackEnabled = true;
@@ -66,7 +65,7 @@ public class SchemaBrowserInput implemen
* @param connection the connection
* @param schemaElement the schema element input
*/
- public SchemaBrowserInput( IBrowserConnection connection, AbstractSchemaObject schemaElement )
+ public SchemaBrowserInput( IBrowserConnection connection, SchemaObject schemaElement )
{
this.connection = connection;
this.schemaElement = schemaElement;
@@ -139,7 +138,7 @@ public class SchemaBrowserInput implemen
/**
* {@inheritDoc}
*/
- public Object getAdapter( Class adapter )
+ public Object getAdapter( @SuppressWarnings("rawtypes") Class adapter )
{
return null;
}
@@ -162,7 +161,7 @@ public class SchemaBrowserInput implemen
*
* @return the schema element or null
*/
- public AbstractSchemaObject getSchemaElement()
+ public SchemaObject getSchemaElement()
{
return schemaElement;
}
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserManager.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserManager.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserManager.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserManager.java Sun Mar 20 18:55:08 2011
@@ -17,11 +17,10 @@
* under the License.
*
*/
-
package org.apache.directory.studio.ldapbrowser.ui.editors.schemabrowser;
-import org.apache.directory.shared.ldap.model.schema.AbstractSchemaObject;
+import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.studio.ldapbrowser.core.model.IBrowserConnection;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
@@ -46,7 +45,7 @@ public class SchemaBrowserManager
* @param connection the connection
* @param schemaElement the schema element
*/
- public static void setInput( IBrowserConnection connection, AbstractSchemaObject schemaElement )
+ public static void setInput( IBrowserConnection connection, SchemaObject schemaElement )
{
SchemaBrowserInput input = new SchemaBrowserInput( connection, schemaElement );
setInput( input );
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserNavigationLocation.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserNavigationLocation.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserNavigationLocation.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaBrowserNavigationLocation.java Sun Mar 20 18:55:08 2011
@@ -17,18 +17,15 @@
* under the License.
*
*/
-
package org.apache.directory.studio.ldapbrowser.ui.editors.schemabrowser;
-import org.apache.directory.shared.ldap.model.schema.AbstractSchemaObject;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
import org.apache.directory.shared.ldap.model.schema.MatchingRule;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
import org.apache.directory.shared.ldap.model.schema.MatchingRuleUse;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
+import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.studio.ldapbrowser.core.BrowserCorePlugin;
import org.apache.directory.studio.ldapbrowser.core.model.IBrowserConnection;
import org.apache.directory.studio.ldapbrowser.core.model.schema.SchemaUtils;
@@ -62,7 +59,7 @@ public class SchemaBrowserNavigationLoca
*/
public String getText()
{
- AbstractSchemaObject schemaElement = getSchemaElement();
+ SchemaObject schemaElement = getSchemaElement();
if ( schemaElement != null )
{
if ( schemaElement instanceof ObjectClass )
@@ -104,7 +101,7 @@ public class SchemaBrowserNavigationLoca
public void saveState( IMemento memento )
{
IBrowserConnection connection = getConnection();
- AbstractSchemaObject schemaElement = getSchemaElement();
+ SchemaObject schemaElement = getSchemaElement();
memento.putString( "CONNECTION", connection.getConnection().getId() ); //$NON-NLS-1$
memento.putString( "SCHEMAELEMENTYPE", schemaElement.getClass().getName() ); //$NON-NLS-1$
memento.putString( "SCHEMAELEMENTOID", schemaElement.getOid() ); //$NON-NLS-1$
@@ -120,24 +117,25 @@ public class SchemaBrowserNavigationLoca
memento.getString( "CONNECTION" ) ); //$NON-NLS-1$
String schemaElementType = memento.getString( "SCHEMAELEMENTYPE" ); //$NON-NLS-1$
String schemaElementOid = memento.getString( "SCHEMAELEMENTOID" ); //$NON-NLS-1$
- AbstractSchemaObject schemaElement = null;
- if ( ObjectClass.class.getName().equals( schemaElementType ) )
+ SchemaObject schemaElement = null;
+
+ if ( schemaElementType.contains( ObjectClass.class.getName() ) )
{
schemaElement = connection.getSchema().getObjectClassDescription( schemaElementOid );
}
- else if ( AttributeType.class.getName().equals( schemaElementType ) )
+ else if ( schemaElementType.contains( AttributeType.class.getName() ) )
{
schemaElement = connection.getSchema().getAttributeTypeDescription( schemaElementOid );
}
- else if ( MutableLdapSyntaxImpl.class.getName().equals( schemaElementType ) )
+ else if ( schemaElementType.contains( LdapSyntax.class.getName() ) )
{
schemaElement = connection.getSchema().getLdapSyntaxDescription( schemaElementOid );
}
- else if ( MutableMatchingRuleImpl.class.getName().equals( schemaElementType ) )
+ else if ( schemaElementType.contains( MatchingRule.class.getName() ) )
{
schemaElement = connection.getSchema().getMatchingRuleDescription( schemaElementOid );
}
- else if ( MatchingRuleUse.class.getName().equals( schemaElementType ) )
+ else if ( schemaElementType.contains( MatchingRuleUse.class.getName() ) )
{
schemaElement = connection.getSchema().getMatchingRuleUseDescription( schemaElementOid );
}
@@ -184,8 +182,8 @@ public class SchemaBrowserNavigationLoca
}
SchemaBrowserNavigationLocation location = ( SchemaBrowserNavigationLocation ) currentLocation;
- AbstractSchemaObject other = location.getSchemaElement();
- AbstractSchemaObject element = getSchemaElement();
+ SchemaObject other = location.getSchemaElement();
+ SchemaObject element = getSchemaElement();
if ( other == null && element == null )
{
@@ -215,14 +213,14 @@ public class SchemaBrowserNavigationLoca
*
* @return the schema element
*/
- private AbstractSchemaObject getSchemaElement()
+ private SchemaObject getSchemaElement()
{
Object editorInput = getInput();
if ( editorInput != null && editorInput instanceof SchemaBrowserInput )
{
SchemaBrowserInput schemaBrowserInput = ( SchemaBrowserInput ) editorInput;
- AbstractSchemaObject schemaElement = schemaBrowserInput.getSchemaElement();
+ SchemaObject schemaElement = schemaBrowserInput.getSchemaElement();
if ( schemaElement != null )
{
return schemaElement;
Modified: directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaDetailsPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaDetailsPage.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaDetailsPage.java (original)
+++ directory/studio/branches/akarasulu/plugins/ldapbrowser.ui/src/main/java/org/apache/directory/studio/ldapbrowser/ui/editors/schemabrowser/SchemaDetailsPage.java Sun Mar 20 18:55:08 2011
@@ -21,10 +21,7 @@
package org.apache.directory.studio.ldapbrowser.ui.editors.schemabrowser;
-import java.util.List;
-
-import org.apache.directory.shared.ldap.model.schema.AbstractMutableSchemaObject;
-import org.apache.directory.shared.ldap.model.schema.AbstractSchemaObject;
+import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.studio.ldapbrowser.core.model.schema.Schema;
import org.apache.directory.studio.ldapbrowser.core.model.schema.SchemaUtils;
import org.eclipse.swt.SWT;
@@ -92,10 +89,10 @@ public abstract class SchemaDetailsPage
public void linkActivated( HyperlinkEvent e )
{
Object obj = e.getHref();
- if ( obj instanceof AbstractMutableSchemaObject )
+ if ( obj instanceof SchemaObject )
{
schemaPage.getSchemaBrowser().setInput(
- new SchemaBrowserInput( schemaPage.getConnection(), ( AbstractSchemaObject ) obj ) );
+ new SchemaBrowserInput( schemaPage.getConnection(), ( SchemaObject ) obj ) );
}
}
@@ -158,7 +155,7 @@ public abstract class SchemaDetailsPage
*
* @param schemaPart the schema part to display
*/
- protected void createRawContents( AbstractSchemaObject asd )
+ protected void createRawContents( SchemaObject asd )
{
if ( rawSection.getClient() != null && !rawSection.getClient().isDisposed() )
@@ -208,22 +205,4 @@ public abstract class SchemaDetailsPage
{
return s == null ? "-" : s; //$NON-NLS-1$
}
-
-
- /**
- * Helper method, return a dash "-" if the given string is null.
- *
- * @param s the string
- * @return the given string or a dash "-" if the given string is null.
- */
- private String getNonNullString( List<String> s )
- {
- if ( s == null || s.isEmpty() )
- {
- return "-"; //$NON-NLS-1$
- }
-
- return s.get( 0 );
- }
-
}
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaHandler.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaHandler.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaHandler.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/controller/SchemaHandler.java Sun Mar 20 18:55:08 2011
@@ -28,8 +28,8 @@ import org.apache.commons.collections.ma
import org.apache.directory.shared.ldap.model.schema.AttributeType;
import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
import org.apache.directory.shared.ldap.model.schema.MatchingRule;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MutableMatchingRule;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.studio.schemaeditor.model.Schema;
@@ -53,11 +53,11 @@ public class SchemaHandler
/** The attribute types List */
private List<AttributeType> attributeTypesList;
/** The matching rules List */
- private List<MutableMatchingRuleImpl> matchingRulesList;
+ private List<MatchingRule> matchingRulesList;
/** The object classes List */
private List<ObjectClass> objectClassesList;
/** The syntaxes List */
- private List<MutableLdapSyntaxImpl> syntaxesList;
+ private List<LdapSyntax> syntaxesList;
//
// The MultiMap (for fast searching)
@@ -90,9 +90,9 @@ public class SchemaHandler
// Lists
schemasList = new ArrayList<Schema>();
attributeTypesList = new ArrayList<AttributeType>();
- matchingRulesList = new ArrayList<MutableMatchingRuleImpl>();;
+ matchingRulesList = new ArrayList<MatchingRule>();;
objectClassesList = new ArrayList<ObjectClass>();
- syntaxesList = new ArrayList<MutableLdapSyntaxImpl>();
+ syntaxesList = new ArrayList<LdapSyntax>();
// Maps
schemasMap = new MultiValueMap();
@@ -127,7 +127,7 @@ public class SchemaHandler
* @return
* the List of all the matching rules
*/
- public List<MutableMatchingRuleImpl> getMatchingRules()
+ public List<MatchingRule> getMatchingRules()
{
return matchingRulesList;
}
@@ -163,7 +163,7 @@ public class SchemaHandler
* @return
* the List of all the matching rules
*/
- public List<MutableLdapSyntaxImpl> getSyntaxes()
+ public List<LdapSyntax> getSyntaxes()
{
return syntaxesList;
}
@@ -214,13 +214,13 @@ public class SchemaHandler
* @return
* the corresponding matching rule, or null if no one is found
*/
- public MutableMatchingRuleImpl getMatchingRule( String id )
+ public MutableMatchingRule getMatchingRule( String id )
{
List<?> list = getMatchingRuleList( id.toLowerCase() );
if ( ( list != null ) && ( list.size() >= 1 ) )
{
- return ( MutableMatchingRuleImpl ) list.get( 0 );
+ return ( MutableMatchingRule ) list.get( 0 );
}
else
{
@@ -325,13 +325,13 @@ public class SchemaHandler
* @return
* the corresponding syntax, or null if no one is found
*/
- public MutableLdapSyntaxImpl getSyntax( String id )
+ public MutableLdapSyntax getSyntax( String id )
{
List<?> list = getSyntaxList( id.toLowerCase() );
if ( ( list != null ) && ( list.size() >= 1 ) )
{
- return ( MutableLdapSyntaxImpl ) list.get( 0 );
+ return ( MutableLdapSyntax ) list.get( 0 );
}
else
{
@@ -493,7 +493,7 @@ public class SchemaHandler
}
// Adding its matching rules
- for ( MutableMatchingRuleImpl mr : schema.getMatchingRules() )
+ for ( MatchingRule mr : schema.getMatchingRules() )
{
addSchemaObject( mr );
}
@@ -505,7 +505,7 @@ public class SchemaHandler
}
// Adding its syntaxes
- for ( MutableLdapSyntaxImpl syntax : schema.getSyntaxes() )
+ for ( LdapSyntax syntax : schema.getSyntaxes() )
{
addSchemaObject( syntax );
}
@@ -538,7 +538,7 @@ public class SchemaHandler
}
else if ( object instanceof MatchingRule )
{
- MutableMatchingRuleImpl mr = ( MutableMatchingRuleImpl ) object;
+ MutableMatchingRule mr = ( MutableMatchingRule ) object;
matchingRulesList.add( mr );
List<String> names = mr.getNames();
if ( names != null )
@@ -566,7 +566,7 @@ public class SchemaHandler
}
else if ( object instanceof LdapSyntax )
{
- MutableLdapSyntaxImpl syntax = ( MutableLdapSyntaxImpl ) object;
+ MutableLdapSyntax syntax = ( MutableLdapSyntax ) object;
syntaxesList.add( syntax );
List<String> names = syntax.getNames();
if ( names != null )
@@ -600,7 +600,7 @@ public class SchemaHandler
}
// Removing its matching rules
- for ( MutableMatchingRuleImpl mr : schema.getMatchingRules() )
+ for ( MatchingRule mr : schema.getMatchingRules() )
{
removeSchemaObject( mr );
}
@@ -612,7 +612,7 @@ public class SchemaHandler
}
// Removing its syntaxes
- for ( MutableLdapSyntaxImpl syntax : schema.getSyntaxes() )
+ for ( LdapSyntax syntax : schema.getSyntaxes() )
{
removeSchemaObject( syntax );
}
@@ -645,7 +645,7 @@ public class SchemaHandler
}
else if ( object instanceof MatchingRule )
{
- MutableMatchingRuleImpl mr = ( MutableMatchingRuleImpl ) object;
+ MutableMatchingRule mr = ( MutableMatchingRule ) object;
matchingRulesList.remove( mr );
List<String> names = mr.getNames();
if ( names != null )
@@ -673,7 +673,7 @@ public class SchemaHandler
}
else if ( object instanceof LdapSyntax )
{
- MutableLdapSyntaxImpl syntax = ( MutableLdapSyntaxImpl ) object;
+ MutableLdapSyntax syntax = ( MutableLdapSyntax ) object;
syntaxesList.remove( syntax );
List<String> names = syntax.getNames();
if ( names != null )
@@ -1056,162 +1056,6 @@ public class SchemaHandler
/**
- * Notifies the SchemaHandler listeners that a matching rule has been added.
- *
- * @param mr
- * the added matching rule
- */
- private void notifyMatchingRuleAdded( MutableMatchingRuleImpl mr )
- {
- // SchemaHandler Listeners
- for ( SchemaHandlerListener listener : schemaHandlerListeners.toArray( new SchemaHandlerListener[0] ) )
- {
- listener.matchingRuleAdded( mr );
- }
-
- // Schema Listeners
- List<?> listeners = ( List<?> ) schemaListeners.get( getSchema( mr.getSchemaName() ) );
- if ( listeners != null )
- {
- for ( Object object : listeners.toArray() )
- {
- ( ( SchemaListener ) object ).matchingRuleAdded( mr );
- }
- }
- }
-
-
- /**
- * Notifies the SchemaHandler listeners that a matching rule has been modified.
- *
- * @param mr
- * the modified matching rule
- */
- private void notifyMatchingRuleModified( MutableMatchingRuleImpl mr )
- {
- // SchemaHandler Listeners
- for ( SchemaHandlerListener listener : schemaHandlerListeners.toArray( new SchemaHandlerListener[0] ) )
- {
- listener.matchingRuleModified( mr );
- }
-
- // Schema Listeners
- List<?> listeners = ( List<?> ) schemaListeners.get( getSchema( mr.getSchemaName() ) );
- if ( listeners != null )
- {
- for ( Object object : listeners.toArray() )
- {
- ( ( SchemaListener ) object ).matchingRuleModified( mr );
- }
- }
- }
-
-
- /**
- * Notifies the SchemaHandler listeners that a matching rule has been removed.
- *
- * @param mr
- * the removed matching rule
- */
- private void notifyMatchingRuleRemoved( MutableMatchingRuleImpl mr )
- {
- // SchemaHandler Listeners
- for ( SchemaHandlerListener listener : schemaHandlerListeners.toArray( new SchemaHandlerListener[0] ) )
- {
- listener.matchingRuleRemoved( mr );
- }
-
- // Schema Listeners
- List<?> listeners = ( List<?> ) schemaListeners.get( getSchema( mr.getSchemaName() ) );
- if ( listeners != null )
- {
- for ( Object object : listeners.toArray() )
- {
- ( ( SchemaListener ) object ).matchingRuleRemoved( mr );
- }
- }
- }
-
-
- /**
- * Notifies the SchemaHandler listeners that a syntax has been added.
- *
- * @param syntax
- * the added syntax
- */
- private void notifySyntaxRuleAdded( MutableLdapSyntaxImpl syntax )
- {
- // SchemaHandler Listeners
- for ( SchemaHandlerListener listener : schemaHandlerListeners.toArray( new SchemaHandlerListener[0] ) )
- {
- listener.syntaxAdded( syntax );
- }
-
- // Schema Listeners
- List<?> listeners = ( List<?> ) schemaListeners.get( getSchema( syntax.getSchemaName() ) );
- if ( listeners != null )
- {
- for ( Object object : listeners.toArray() )
- {
- ( ( SchemaListener ) object ).syntaxAdded( syntax );
- }
- }
- }
-
-
- /**
- * Notifies the SchemaHandler listeners that a syntax has been modified.
- *
- * @param syntax
- * the modified syntax
- */
- private void notifySyntaxRuleModified( MutableLdapSyntaxImpl syntax )
- {
- // SchemaHandler Listeners
- for ( SchemaHandlerListener listener : schemaHandlerListeners.toArray( new SchemaHandlerListener[0] ) )
- {
- listener.syntaxModified( syntax );
- }
-
- // Schema Listeners
- List<?> listeners = ( List<?> ) schemaListeners.get( getSchema( syntax.getSchemaName() ) );
- if ( listeners != null )
- {
- for ( Object object : listeners.toArray() )
- {
- ( ( SchemaListener ) object ).syntaxModified( syntax );
- }
- }
- }
-
-
- /**
- * Notifies the SchemaHandler listeners that a syntax has been removed.
- *
- * @param syntax
- * the removed syntax
- */
- private void notifySyntaxRemoved( MutableLdapSyntaxImpl syntax )
- {
- // SchemaHandler Listeners
- for ( SchemaHandlerListener listener : schemaHandlerListeners.toArray( new SchemaHandlerListener[0] ) )
- {
- listener.syntaxRemoved( syntax );
- }
-
- // Schema Listeners
- List<?> listeners = ( List<?> ) schemaListeners.get( getSchema( syntax.getSchemaName() ) );
- if ( listeners != null )
- {
- for ( Object object : listeners.toArray() )
- {
- ( ( SchemaListener ) object ).syntaxRemoved( syntax );
- }
- }
- }
-
-
- /**
* Verifies if the given alias or oid is already taken by a schema object
*
* @param id
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/DependenciesComputer.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/DependenciesComputer.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/DependenciesComputer.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/DependenciesComputer.java Sun Mar 20 18:55:08 2011
@@ -28,8 +28,8 @@ import java.util.List;
import org.apache.commons.collections.MultiMap;
import org.apache.commons.collections.map.MultiValueMap;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.studio.schemaeditor.controller.SchemaHandler;
@@ -149,7 +149,7 @@ public class DependenciesComputer
String syntaxOID = attributeType.getSyntaxOid();
if ( syntaxOID != null )
{
- MutableLdapSyntaxImpl syntax = schemaHandler.getSyntax( syntaxOID );
+ LdapSyntax syntax = schemaHandler.getSyntax( syntaxOID );
if ( syntax == null )
{
throw new DependencyComputerException( NLS.bind(
@@ -169,7 +169,7 @@ public class DependenciesComputer
String equalityName = attributeType.getEqualityOid();
if ( equalityName != null )
{
- MutableMatchingRuleImpl equalityMatchingRule = schemaHandler.getMatchingRule( equalityName );
+ MatchingRule equalityMatchingRule = schemaHandler.getMatchingRule( equalityName );
if ( equalityMatchingRule == null )
{
throw new DependencyComputerException( NLS.bind(
@@ -189,7 +189,7 @@ public class DependenciesComputer
String orderingName = attributeType.getOrderingOid();
if ( orderingName != null )
{
- MutableMatchingRuleImpl orderingMatchingRule = schemaHandler.getMatchingRule( orderingName );
+ MatchingRule orderingMatchingRule = schemaHandler.getMatchingRule( orderingName );
if ( orderingMatchingRule == null )
{
throw new DependencyComputerException( NLS.bind(
@@ -209,7 +209,7 @@ public class DependenciesComputer
String substringName = attributeType.getSubstringOid();
if ( substringName != null )
{
- MutableMatchingRuleImpl substringMatchingRule = schemaHandler.getMatchingRule( substringName );
+ MatchingRule substringMatchingRule = schemaHandler.getMatchingRule( substringName );
if ( substringMatchingRule == null )
{
throw new DependencyComputerException( NLS.bind(
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/Schema.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/Schema.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/Schema.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/Schema.java Sun Mar 20 18:55:08 2011
@@ -26,8 +26,8 @@ import java.util.List;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
import org.apache.directory.shared.ldap.model.schema.MatchingRule;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MutableMatchingRule;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.registries.DefaultSchema;
@@ -49,10 +49,10 @@ public class Schema extends DefaultSchem
private List<ObjectClass> objectClasses = new ArrayList<ObjectClass>();
/** The MatchingRule List */
- private List<MutableMatchingRuleImpl> matchingRules = new ArrayList<MutableMatchingRuleImpl>();
+ private List<MatchingRule> matchingRules = new ArrayList<MatchingRule>();
/** The Syntax List */
- private List<MutableLdapSyntaxImpl> syntaxes = new ArrayList<MutableLdapSyntaxImpl>();
+ private List<LdapSyntax> syntaxes = new ArrayList<LdapSyntax>();
/**
@@ -85,7 +85,7 @@ public class Schema extends DefaultSchem
* @param mr
* the MatchingRule
*/
- public boolean addMatchingRule( MutableMatchingRuleImpl mr )
+ public boolean addMatchingRule( MutableMatchingRule mr )
{
return matchingRules.add( mr );
}
@@ -109,7 +109,7 @@ public class Schema extends DefaultSchem
* @param syntax
* the Syntax
*/
- public boolean addSyntax( MutableLdapSyntaxImpl syntax )
+ public boolean addSyntax( MutableLdapSyntax syntax )
{
return syntaxes.add( syntax );
}
@@ -172,7 +172,7 @@ public class Schema extends DefaultSchem
*/
public MatchingRule getMatchingRule( String id )
{
- for ( MutableMatchingRuleImpl mr : matchingRules )
+ for ( MatchingRule mr : matchingRules )
{
List<String> aliases = mr.getNames();
if ( aliases != null )
@@ -201,7 +201,7 @@ public class Schema extends DefaultSchem
* @return
* all the MatchingRule objects contained in the Schema
*/
- public List<MutableMatchingRuleImpl> getMatchingRules()
+ public List<MatchingRule> getMatchingRules()
{
return matchingRules;
}
@@ -276,7 +276,7 @@ public class Schema extends DefaultSchem
*/
public LdapSyntax getSyntax( String id )
{
- for ( MutableLdapSyntaxImpl syntax : syntaxes )
+ for ( LdapSyntax syntax : syntaxes )
{
List<String> aliases = syntax.getNames();
if ( aliases != null )
@@ -305,7 +305,7 @@ public class Schema extends DefaultSchem
* @return
* all the Syntax objects contained in the Schema
*/
- public List<MutableLdapSyntaxImpl> getSyntaxes()
+ public List<LdapSyntax> getSyntaxes()
{
return syntaxes;
}
@@ -329,7 +329,7 @@ public class Schema extends DefaultSchem
* @param mr
* the MatchingRule
*/
- public boolean removeMatchingRule( MutableMatchingRuleImpl mr )
+ public boolean removeMatchingRule( MutableMatchingRule mr )
{
return matchingRules.remove( mr );
}
@@ -353,7 +353,7 @@ public class Schema extends DefaultSchem
* @param syntax
* the Syntax
*/
- public boolean removeSyntax( MutableLdapSyntaxImpl syntax )
+ public boolean removeSyntax( MutableLdapSyntax syntax )
{
return syntaxes.remove( syntax );
}
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/GenericSchemaConnector.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/GenericSchemaConnector.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/GenericSchemaConnector.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/GenericSchemaConnector.java Sun Mar 20 18:55:08 2011
@@ -31,7 +31,10 @@ import javax.naming.directory.SearchCont
import javax.naming.directory.SearchResult;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntax;
import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
+import org.apache.directory.shared.ldap.model.schema.MutableMatchingRule;
import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.parsers.AttributeTypeDescriptionSchemaParser;
@@ -263,9 +266,9 @@ public class GenericSchemaConnector exte
String value = ( String ) ne.nextElement();
LdapSyntaxDescriptionSchemaParser parser = new LdapSyntaxDescriptionSchemaParser();
parser.setQuirksMode( true );
- MutableLdapSyntaxImpl lsd = parser.parseLdapSyntaxDescription( value );
+ LdapSyntax lsd = parser.parseLdapSyntaxDescription( value );
- MutableLdapSyntaxImpl impl = new MutableLdapSyntaxImpl( lsd.getOid() );
+ MutableLdapSyntax impl = new MutableLdapSyntaxImpl( lsd.getOid() );
impl.setDescription( lsd.getDescription() );
impl.setNames( new String[]
{ lsd.getDescription() } );
@@ -304,9 +307,9 @@ public class GenericSchemaConnector exte
String value = ( String ) ne.nextElement();
MatchingRuleDescriptionSchemaParser parser = new MatchingRuleDescriptionSchemaParser();
parser.setQuirksMode( true );
- MutableMatchingRuleImpl mrd = parser.parseMatchingRuleDescription( value );
+ MutableMatchingRule mrd = parser.parseMatchingRuleDescription( value );
- MutableMatchingRuleImpl impl = new MutableMatchingRuleImpl( mrd.getOid() );
+ MutableMatchingRule impl = new MutableMatchingRuleImpl( mrd.getOid() );
impl.setDescription( mrd.getDescription() );
impl.setNames( mrd.getNames().toArray( new String[0] ) );
impl.setObsolete( mrd.isObsolete() );
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/XMLSchemaFileExporter.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/XMLSchemaFileExporter.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/XMLSchemaFileExporter.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/io/XMLSchemaFileExporter.java Sun Mar 20 18:55:08 2011
@@ -26,8 +26,8 @@ import java.io.OutputStream;
import java.util.List;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.ObjectClassTypeEnum;
import org.apache.directory.shared.ldap.model.schema.UsageEnum;
@@ -215,22 +215,22 @@ public class XMLSchemaFileExporter
}
// Matching Rules
- List<MutableMatchingRuleImpl> mrs = schema.getMatchingRules();
+ List<MatchingRule> mrs = schema.getMatchingRules();
if ( ( mrs != null ) && ( mrs.size() >= 1 ) )
{
Element matchingRulesNode = element.addElement( MATCHING_RULES_TAG );
- for ( MutableMatchingRuleImpl mr : mrs )
+ for ( MatchingRule mr : mrs )
{
toXml( mr, matchingRulesNode );
}
}
// Syntaxes
- List<MutableLdapSyntaxImpl> syntaxes = schema.getSyntaxes();
+ List<LdapSyntax> syntaxes = schema.getSyntaxes();
if ( ( syntaxes != null ) && ( syntaxes.size() >= 1 ) )
{
Element syntaxesNode = element.addElement( SYNTAXES_TAG );
- for ( MutableLdapSyntaxImpl syntax : syntaxes )
+ for ( LdapSyntax syntax : syntaxes )
{
toXml( syntax, syntaxesNode );
}
@@ -464,7 +464,7 @@ public class XMLSchemaFileExporter
* @param root
* the root Element
*/
- private static void toXml( MutableMatchingRuleImpl mr, Element root )
+ private static void toXml( MatchingRule mr, Element root )
{
Element mrNode = root.addElement( MATCHING_RULE_TAG );
@@ -523,7 +523,7 @@ public class XMLSchemaFileExporter
* @return
* the corresponding source code representation
*/
- private static void toXml( MutableLdapSyntaxImpl syntax, Element root )
+ private static void toXml( LdapSyntax syntax, Element root )
{
Element syntaxNode = root.addElement( SYNTAX_TAG );
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoader.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoader.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoader.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoader.java Sun Mar 20 18:55:08 2011
@@ -27,8 +27,8 @@ import java.util.List;
import org.apache.directory.shared.ldap.model.entry.Entry;
import org.apache.directory.shared.ldap.model.exception.LdapException;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.registries.AbstractSchemaLoader;
import org.apache.directory.shared.ldap.model.schema.registries.Schema;
@@ -114,9 +114,9 @@ public class SchemaEditorSchemaLoader ex
{
for ( Schema schema : schemas )
{
- List<MutableMatchingRuleImpl> matchingRules = project.getSchemaHandler().getSchema( schema.getSchemaName() )
+ List<MatchingRule> matchingRules = project.getSchemaHandler().getSchema( schema.getSchemaName() )
.getMatchingRules();
- for ( MutableMatchingRuleImpl matchingRule : matchingRules )
+ for ( MatchingRule matchingRule : matchingRules )
{
matchingRuleList.add( SchemaEditorSchemaLoaderUtils.toEntry( matchingRule ) );
}
@@ -138,9 +138,9 @@ public class SchemaEditorSchemaLoader ex
{
for ( Schema schema : schemas )
{
- List<MutableLdapSyntaxImpl> syntaxes = project.getSchemaHandler().getSchema( schema.getSchemaName() )
+ List<LdapSyntax> syntaxes = project.getSchemaHandler().getSchema( schema.getSchemaName() )
.getSyntaxes();
- for ( MutableLdapSyntaxImpl syntax : syntaxes )
+ for ( LdapSyntax syntax : syntaxes )
{
syntaxList.add( SchemaEditorSchemaLoaderUtils.toEntry( syntax ) );
}
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoaderUtils.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoaderUtils.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoaderUtils.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/model/schemamanager/SchemaEditorSchemaLoaderUtils.java Sun Mar 20 18:55:08 2011
@@ -32,11 +32,11 @@ import org.apache.directory.shared.ldap.
import org.apache.directory.shared.ldap.model.name.Dn;
import org.apache.directory.shared.ldap.model.name.Rdn;
import org.apache.directory.shared.ldap.model.schema.AttributeType;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
+import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
+import org.apache.directory.shared.ldap.model.schema.MatchingRule;
+import org.apache.directory.shared.ldap.model.schema.MutableSchemaObject;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.ObjectClassTypeEnum;
-import org.apache.directory.shared.ldap.model.schema.MutableSchemaObject;
import org.apache.directory.shared.ldap.model.schema.SchemaObject;
import org.apache.directory.shared.ldap.model.schema.UsageEnum;
import org.apache.directory.shared.util.Strings;
@@ -130,7 +130,7 @@ public class SchemaEditorSchemaLoaderUti
* the object class converted to an equivalent entry representation
* @throws LdapException
*/
- public static Entry toEntry( MutableMatchingRuleImpl matchingRule ) throws LdapException
+ public static Entry toEntry( MatchingRule matchingRule ) throws LdapException
{
// Creating a blank entry
Entry entry = new DefaultEntry();
@@ -197,7 +197,7 @@ public class SchemaEditorSchemaLoaderUti
* the object class converted to an equivalent entry representation
* @throws LdapException
*/
- public static Entry toEntry( MutableLdapSyntaxImpl syntax ) throws LdapException
+ public static Entry toEntry( LdapSyntax syntax ) throws LdapException
{
// Creating a blank entry
Entry entry = new DefaultEntry();
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboContentProvider.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboContentProvider.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboContentProvider.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATEMatchingRulesComboContentProvider.java Sun Mar 20 18:55:08 2011
@@ -24,7 +24,6 @@ import java.util.Collections;
import java.util.List;
import org.apache.directory.shared.ldap.model.schema.MatchingRule;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
import org.apache.directory.studio.schemaeditor.Activator;
import org.apache.directory.studio.schemaeditor.view.editors.NonExistingMatchingRule;
import org.eclipse.jface.viewers.IStructuredContentProvider;
@@ -53,7 +52,7 @@ public class ATEMatchingRulesComboConten
input.addChild( new NonExistingMatchingRule( NonExistingMatchingRule.NONE ) );
// Creating Children
- List<MutableMatchingRuleImpl> equalityMatchingRules = Activator.getDefault().getSchemaHandler()
+ List<MatchingRule> equalityMatchingRules = Activator.getDefault().getSchemaHandler()
.getMatchingRules();
for ( MatchingRule matchingRule : equalityMatchingRules )
{
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATESyntaxComboContentProvider.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATESyntaxComboContentProvider.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATESyntaxComboContentProvider.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/ATESyntaxComboContentProvider.java Sun Mar 20 18:55:08 2011
@@ -24,7 +24,6 @@ import java.util.Collections;
import java.util.List;
import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
import org.apache.directory.studio.schemaeditor.Activator;
import org.apache.directory.studio.schemaeditor.view.editors.NonExistingSyntax;
import org.eclipse.jface.viewers.IStructuredContentProvider;
@@ -53,7 +52,7 @@ public class ATESyntaxComboContentProvid
input.addChild( new NonExistingSyntax( NonExistingSyntax.NONE ) );
// Creating Children
- List<MutableLdapSyntaxImpl> syntaxes = Activator.getDefault().getSchemaHandler().getSyntaxes();
+ List<LdapSyntax> syntaxes = Activator.getDefault().getSchemaHandler().getSyntaxes();
for ( LdapSyntax syntax : syntaxes )
{
input.addChild( syntax );
Modified: directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/AttributeTypeEditorOverviewPage.java
URL: http://svn.apache.org/viewvc/directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/AttributeTypeEditorOverviewPage.java?rev=1083535&r1=1083534&r2=1083535&view=diff
==============================================================================
--- directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/AttributeTypeEditorOverviewPage.java (original)
+++ directory/studio/branches/akarasulu/plugins/schemaeditor/src/main/java/org/apache/directory/studio/schemaeditor/view/editors/attributetype/AttributeTypeEditorOverviewPage.java Sun Mar 20 18:55:08 2011
@@ -28,8 +28,6 @@ import org.apache.directory.shared.asn1.
import org.apache.directory.shared.ldap.model.schema.AttributeType;
import org.apache.directory.shared.ldap.model.schema.LdapSyntax;
import org.apache.directory.shared.ldap.model.schema.MatchingRule;
-import org.apache.directory.shared.ldap.model.schema.MutableLdapSyntaxImpl;
-import org.apache.directory.shared.ldap.model.schema.MutableMatchingRuleImpl;
import org.apache.directory.shared.ldap.model.schema.ObjectClass;
import org.apache.directory.shared.ldap.model.schema.UsageEnum;
import org.apache.directory.studio.schemaeditor.Activator;
@@ -487,7 +485,7 @@ public class AttributeTypeEditorOverview
if ( selectedItem instanceof LdapSyntax )
{
- modifiedAttributeType.setSyntaxOid( ( ( MutableLdapSyntaxImpl ) selectedItem ).getOid() );
+ modifiedAttributeType.setSyntaxOid( ( ( LdapSyntax ) selectedItem ).getOid() );
}
else if ( selectedItem instanceof NonExistingSyntax )
{
@@ -584,7 +582,7 @@ public class AttributeTypeEditorOverview
if ( selectedItem instanceof MatchingRule )
{
- modifiedAttributeType.setEqualityOid( ( ( MutableMatchingRuleImpl ) selectedItem ).getName() );
+ modifiedAttributeType.setEqualityOid( ( ( MatchingRule ) selectedItem ).getName() );
}
else if ( selectedItem instanceof NonExistingMatchingRule )
{
@@ -612,7 +610,7 @@ public class AttributeTypeEditorOverview
if ( selectedItem instanceof MatchingRule )
{
- modifiedAttributeType.setOrderingOid( ( ( MutableMatchingRuleImpl ) selectedItem ).getName() );
+ modifiedAttributeType.setOrderingOid( ( ( MatchingRule ) selectedItem ).getName() );
}
else if ( selectedItem instanceof NonExistingMatchingRule )
{
@@ -640,7 +638,7 @@ public class AttributeTypeEditorOverview
if ( selectedItem instanceof MatchingRule )
{
- modifiedAttributeType.setSubstringOid( ( ( MutableMatchingRuleImpl ) selectedItem ).getName() );
+ modifiedAttributeType.setSubstringOid( ( ( MatchingRule ) selectedItem ).getName() );
}
else if ( selectedItem instanceof NonExistingMatchingRule )
{
@@ -1052,7 +1050,7 @@ public class AttributeTypeEditorOverview
}
else
{
- MutableLdapSyntaxImpl syntax = schemaHandler.getSyntax( syntaxOID );
+ LdapSyntax syntax = schemaHandler.getSyntax( syntaxOID );
if ( syntax != null )
{
syntaxComboViewer.setSelection( new StructuredSelection( syntax ), true );
@@ -1087,7 +1085,7 @@ public class AttributeTypeEditorOverview
}
else
{
- MutableMatchingRuleImpl matchingRule = schemaHandler.getMatchingRule( equalityName );
+ MatchingRule matchingRule = schemaHandler.getMatchingRule( equalityName );
if ( matchingRule != null )
{
equalityComboViewer.setSelection( new StructuredSelection( matchingRule ), true );
@@ -1122,7 +1120,7 @@ public class AttributeTypeEditorOverview
}
else
{
- MutableMatchingRuleImpl matchingRule = schemaHandler.getMatchingRule( orderingName );
+ MatchingRule matchingRule = schemaHandler.getMatchingRule( orderingName );
if ( matchingRule != null )
{
orderingComboViewer.setSelection( new StructuredSelection( matchingRule ), true );
@@ -1158,7 +1156,7 @@ public class AttributeTypeEditorOverview
}
else
{
- MutableMatchingRuleImpl matchingRule = schemaHandler.getMatchingRule( substringName );
+ MatchingRule matchingRule = schemaHandler.getMatchingRule( substringName );
if ( matchingRule != null )
{
substringComboViewer.setSelection( new StructuredSelection( matchingRule ), true );