directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pamarce...@apache.org
Subject svn commit: r963768 - in /directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers: LdapServersManager.java LdapServersManagerIO.java messages.properties messages_de.properties messages_fr.properties
Date Tue, 13 Jul 2010 15:53:42 GMT
Author: pamarcelot
Date: Tue Jul 13 15:53:41 2010
New Revision: 963768

URL: http://svn.apache.org/viewvc?rev=963768&view=rev
Log:
Added externalized strings.

Modified:
    directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManager.java
    directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManagerIO.java
    directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages.properties
    directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_de.properties
    directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_fr.properties

Modified: directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManager.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManager.java?rev=963768&r1=963767&r2=963768&view=diff
==============================================================================
--- directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManager.java
(original)
+++ directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManager.java
Tue Jul 13 15:53:41 2010
@@ -272,23 +272,15 @@ public class LdapServersManager
                         }
                         return;
                     }
-                    catch ( FileNotFoundException e )
+                    catch ( Exception e )
                     {
-                        // TODO Add error messages
-                        CommonUiUtils.reportError( Messages.getString( "ServersHandler.ErrorLoadingServer"
) //$NON-NLS-1$
-                            + e.getMessage() );
-                    }
-                    catch ( LdapServersManagerIOException e )
-                    {
-                        // TODO Add error messages
-                        CommonUiUtils.reportError( Messages.getString( "ServersHandler.ErrorLoadingServer"
) //$NON-NLS-1$
+                        CommonUiUtils.reportError( Messages.getString( "LdapServersManager.ErrorLoadingServer"
) //$NON-NLS-1$
                             + e.getMessage() );
                     }
                 }
                 else
                 {
-                    // TODO Add error messages
-                    CommonUiUtils.reportError( Messages.getString( "ServersHandler.ErrorLoadingServer"
) //$NON-NLS-1$
+                    CommonUiUtils.reportError( Messages.getString( "LdapServersManager.ErrorLoadingServer"
) //$NON-NLS-1$
                         + exceptionMessage );
                 }
             }
@@ -336,15 +328,9 @@ public class LdapServersManager
                 LdapServersManagerIO.write( serversList, outputStream );
                 outputStream.close();
             }
-            catch ( FileNotFoundException e )
-            {
-                // TODO Add error messages
-                CommonUiUtils.reportError( Messages.getString( "ServersHandler.ErrorLoadingServer"
) + e.getMessage() ); //$NON-NLS-1$
-            }
-            catch ( IOException e )
+            catch ( Exception e )
             {
-                // TODO Add error messages
-                CommonUiUtils.reportError( Messages.getString( "ServersHandler.ErrorLoadingServer"
) + e.getMessage() ); //$NON-NLS-1$
+                CommonUiUtils.reportError( Messages.getString( "LdapServersManager.ErrorLoadingServer"
) + e.getMessage() ); //$NON-NLS-1$
             }
         }
     }

Modified: directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManagerIO.java
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManagerIO.java?rev=963768&r1=963767&r2=963768&view=diff
==============================================================================
--- directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManagerIO.java
(original)
+++ directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/LdapServersManagerIO.java
Tue Jul 13 15:53:41 2010
@@ -86,7 +86,8 @@ public class LdapServersManagerIO
         Element rootElement = document.getRootElement();
         if ( !rootElement.getName().equals( LDAP_SERVERS_TAG ) )
         {
-            throw new LdapServersManagerIOException( Messages.getString( "ServersHandlerIO.ErrorNotValidServersFile"
) ); //$NON-NLS-1$ // TODO
+            throw new LdapServersManagerIOException(
+                Messages.getString( "LdapServersManagerIO.ErrorNotValidServersFile" ) );
//$NON-NLS-1$
         }
 
         for ( Iterator<?> i = rootElement.elementIterator( LDAP_SERVER_TAG ); i.hasNext();
)

Modified: directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages.properties
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages.properties?rev=963768&r1=963767&r2=963768&view=diff
==============================================================================
--- directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages.properties
(original)
+++ directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages.properties
Tue Jul 13 15:53:41 2010
@@ -16,3 +16,7 @@
 # under the License.
 
 LdapServersPlugin.UnableGetPluginProperties=Unable to get the plugin properties.
+
+LdapServersManager.ErrorLoadingServer=An error occurred when loading the servers.\n\n
+
+LdapServersManagerIO.ErrorNotValidServersFile=The file does not seem to be a valid servers
file.

Modified: directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_de.properties
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_de.properties?rev=963768&r1=963767&r2=963768&view=diff
==============================================================================
--- directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_de.properties
(original)
+++ directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_de.properties
Tue Jul 13 15:53:41 2010
@@ -16,3 +16,7 @@
 # under the License.
 
 LdapServersPlugin.UnableGetPluginProperties=Die Plugin Eigenschaften k\u00F6nnen nicht geladen
werden.
+
+LdapServersManager.ErrorLoadingServer=Beim Laden des Servers ist ein Fehler aufgetreten.\n\n
+
+LdapServersManagerIO.ErrorNotValidServersFile=Die Datei scheint keine g\u00FCltige Server-Datei
zu sein.

Modified: directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_fr.properties
URL: http://svn.apache.org/viewvc/directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_fr.properties?rev=963768&r1=963767&r2=963768&view=diff
==============================================================================
--- directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_fr.properties
(original)
+++ directory/studio/trunk/ldapservers/src/main/java/org/apache/directory/studio/ldapservers/messages_fr.properties
Tue Jul 13 15:53:41 2010
@@ -16,3 +16,7 @@
 # under the License.
 
 LdapServersPlugin.UnableGetPluginProperties=Impossible de r\u00E9cup\u00E9rer les propri\u00E9t\u00E9s
de ce plugin
+
+LdapServersManager.ErrorLoadingServer=Une erreur est survenue lors du chargement des serveurs.\n\n
+
+LdapServersManagerIO.ErrorNotValidServersFile=Le fichier de configuration ne semble pas \u00EAtre
valide.



Mime
View raw message