directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pamarce...@apache.org
Subject svn commit: r561023 - in /directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards: NewAttributeTypeGeneralWizardPage.java NewObjectClassGeneralPageWizardPage.java
Date Mon, 30 Jul 2007 15:51:04 GMT
Author: pamarcelot
Date: Mon Jul 30 08:51:03 2007
New Revision: 561023

URL: http://svn.apache.org/viewvc?view=rev&rev=561023
Log:
Added a verification when specifying the OID, to see if another object already exists with
this OID.

Modified:
    directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
    directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java

Modified: directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java?view=diff&rev=561023&r1=561022&r2=561023
==============================================================================
--- directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
(original)
+++ directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewAttributeTypeGeneralWizardPage.java
Mon Jul 30 08:51:03 2007
@@ -288,6 +288,12 @@
             displayErrorMessage( "Incorrect OID." );
             return;
         }
+        else if ( ( !oidText.getText().equals( "" ) ) && ( OID.isOID( oidText.getText()
) )
+            && ( schemaHandler.isAliasOrOidAlreadyTaken( oidText.getText() ) ) )
+        {
+            displayErrorMessage( "An object with this OID already exists." );
+            return;
+        }
         else if ( aliases.length == 0 )
         {
             displayWarningMessage( "The attribute type does not have any name. It is recommanded
to add at least one name." );

Modified: directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java?view=diff&rev=561023&r1=561022&r2=561023
==============================================================================
--- directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java
(original)
+++ directory/studio/trunk/studio-apacheds-schemaeditor/src/main/java/org/apache/directory/studio/apacheds/schemaeditor/view/wizards/NewObjectClassGeneralPageWizardPage.java
Mon Jul 30 08:51:03 2007
@@ -288,6 +288,12 @@
             displayErrorMessage( "Incorrect OID." );
             return;
         }
+        else if ( ( !oidText.getText().equals( "" ) ) && ( OID.isOID( oidText.getText()
) )
+            && ( schemaHandler.isAliasOrOidAlreadyTaken( oidText.getText() ) ) )
+        {
+            displayErrorMessage( "An object with this OID already exists." );
+            return;
+        }
         else if ( aliases.length == 0 )
         {
             displayWarningMessage( "The attribute type does not have any name. It is recommanded
to add at least one name." );



Mime
View raw message