harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From telli...@apache.org
Subject svn commit: r550106 [1/16] - in /harmony/enhanced/classlib/branches/java6/modules: beans/src/main/java/java/beans/ jndi/META-INF/ jndi/src/main/java/javax/naming/ jndi/src/main/java/javax/naming/directory/ jndi/src/main/java/javax/naming/event/ jndi/sr...
Date Sat, 23 Jun 2007 20:53:48 GMT
Author: tellison
Date: Sat Jun 23 13:53:42 2007
New Revision: 550106

URL: http://svn.apache.org/viewvc?view=rev&rev=550106
Log:
Merge updates made in classlib trunk@550097 since r549762

Modified:
    harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/BeanInfoWrapper.java
    harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/Introspector.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/META-INF/MANIFEST.MF
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationNotSupportedException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/BinaryRefAddr.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Binding.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CannotProceedException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CommunicationException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CompositeName.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CompoundName.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ConfigurationException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Context.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ContextNotEmptyException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/InitialContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/InsufficientResourcesException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/InterruptedNamingException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/InvalidNameException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/LimitExceededException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/LinkException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/LinkLoopException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/LinkRef.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/MalformedLinkException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Name.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NameAlreadyBoundException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NameClassPair.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NameImpl.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NameNotFoundException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NameParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NamingEnumeration.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NamingException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NamingSecurityException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NoInitialContextException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NoPermissionException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/NotContextException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/OperationNotSupportedException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/PartialResultException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/RefAddr.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Reference.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Referenceable.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ReferralException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ServiceUnavailableException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/SizeLimitExceededException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/StringRefAddr.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/TimeLimitExceededException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/Attribute.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/AttributeInUseException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/AttributeModificationException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/Attributes.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/BasicAttribute.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/BasicAttributes.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/BasicNamingEnumeration.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/DirContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/InitialDirContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/InvalidAttributeIdentifierException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/InvalidAttributeValueException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/InvalidAttributesException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/InvalidSearchControlsException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/InvalidSearchFilterException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/ModificationItem.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/NoSuchAttributeException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/SchemaViolationException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/SearchControls.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/directory/SearchResult.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/event/EventContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/event/EventDirContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/event/NamespaceChangeListener.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/event/NamingEvent.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/event/NamingExceptionEvent.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/event/NamingListener.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/event/ObjectChangeListener.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/BasicControl.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/Control.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/ControlFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/ExtendedRequest.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/ExtendedResponse.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/HasControls.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/InitialLdapContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/LdapContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/LdapName.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/LdapReferralException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/ManageReferralControl.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/PagedResultsControl.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/PagedResultsResponseControl.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/Rdn.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/SortControl.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/SortKey.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/SortResponseControl.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/StartTlsRequest.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/StartTlsResponse.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/UnsolicitedNotification.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/UnsolicitedNotificationEvent.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/ldap/UnsolicitedNotificationListener.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/DirObjectFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/DirStateFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/DirectoryManager.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/InitialContextFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/InitialContextFactoryBuilder.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/NamingManager.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/ObjectFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/ObjectFactoryBuilder.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/ResolveResult.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/Resolver.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/spi/StateFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/EnvironmentReader.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/PagedResultSearchControlValue.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/SortResult.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/UrlParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/Util.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/parser/AttributeTypeAndValuePair.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/parser/LdapNameParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/parser/LdapParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/parser/LdapRdnParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/parser/LdapTypeAndValueList.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/internal/parser/RelaxedDnParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/GenericURLContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/GenericURLContextFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/GenericURLDirContextFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/BasicNamingEnumerator.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/DNSContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/DNSContextFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/DNSName.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/DNSNameParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/DNSPseudoURL.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/DomainProtocolException.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/Message.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/ProviderConstants.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/ProviderMgr.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/QuestionRecord.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/Resolver.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/ResolverCache.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/ResourceRecord.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/SList.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/TransportMgr.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/dnsURLContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/dns/dnsURLContextFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/AtomicNameParser.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/BindingEnumeration.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/NameClassPairEnumeration.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/RegistryContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/RegistryContextFactory.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/RemoteReference.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/RemoteReferenceWrapper.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/RemoteReferenceWrapper_Skel.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/registry/RemoteReferenceWrapper_Stub.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/rmiURLContext.java
    harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/org/apache/harmony/jndi/provider/rmi/rmiURLContextFactory.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/io/ObjectStreamField.java
    harmony/enhanced/classlib/branches/java6/modules/luni/src/test/api/common/tests/api/java/io/ObjectStreamFieldTest.java
    harmony/enhanced/classlib/branches/java6/modules/regex/src/main/java/java/util/regex/Pattern.java
    harmony/enhanced/classlib/branches/java6/modules/regex/src/main/java/org/apache/harmony/regex/internal/nls/messages.properties
    harmony/enhanced/classlib/branches/java6/modules/regex/src/test/java/org/apache/harmony/tests/java/util/regex/PatternErrorTest.java

Modified: harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/BeanInfoWrapper.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/BeanInfoWrapper.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/BeanInfoWrapper.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/BeanInfoWrapper.java Sat Jun 23 13:53:42 2007
@@ -35,6 +35,10 @@
     private BeanInfoImpl impl;
 
     private BeanInfoWrapper parentBeanInfoWrapper;
+    
+    private int defaultEventIndex = -1;
+    
+    private EventSetDescriptor[] events = null;
 
     public BeanInfoWrapper(BeanInfo info, BeanInfoImpl impl) {
         this.info = info;
@@ -151,12 +155,22 @@
     public EventSetDescriptor[] getEventSetDescriptors() {
         EventSetDescriptor[] result = null;
         EventSetDescriptor[] infoResult = null;
+        String defaultEventName = null;
 
+        if (events != null) {
+        	return events;
+        }
+        
         if (info != null) {
             BeanInfo[] infos = info.getAdditionalBeanInfo();
+            int defIndex = info.getDefaultEventIndex();
 
             infoResult = info.getEventSetDescriptors();
 
+            if (defIndex >= 0 && defIndex < infoResult.length) {
+                defaultEventName = infoResult[defIndex].getName();
+            }
+
             if (infos != null) {
                 for (BeanInfo additionalInfo : infos) {
                     if (infoResult == null) {
@@ -171,23 +185,26 @@
 
         if (info == null || infoResult == null) {
             EventSetDescriptor[] implResult = impl.getEventSetDescriptors();
-
+            
             // merge with parent info
             if (parentBeanInfoWrapper != null) {
                 EventSetDescriptor[] parentResult = parentBeanInfoWrapper
                         .getEventSetDescriptors();
-                Map<String, FeatureDescriptor> hm = concatArraysUniqueByName(
-                        implResult, parentResult);
+                Map<String, FeatureDescriptor> hm;
+                Collection<FeatureDescriptor> values;
 
-                Collection<FeatureDescriptor> values = hm.values();
-                int idx = 0;
-
-                result = new EventSetDescriptor[values.size()];
-                
-                for (FeatureDescriptor fd : values) {
-                    result[idx++] = (EventSetDescriptor) fd;
+                if (defaultEventName == null) {
+                	int parentDefaultIdx = parentBeanInfoWrapper.getDefaultEventIndex();
+                	
+                	if (parentDefaultIdx >= 0 &&
+                			parentDefaultIdx < parentResult.length) {
+                		defaultEventName = parentResult[parentDefaultIdx].getName();
+                	}
                 }
 
+                hm = concatArraysUniqueByName(implResult, parentResult);
+                result = hm.values().toArray(new EventSetDescriptor[hm.size()]);
+                
                 Arrays.sort(result, new Comparator<EventSetDescriptor>() {
                     public int compare(EventSetDescriptor esd1,
                             EventSetDescriptor esd2) {
@@ -206,6 +223,14 @@
             result = infoResult;
         }
 
+        if (defaultEventName != null) {
+            for (int i = 0; i < result.length; i++) {
+                if (result[i].getName().equals(defaultEventName)) {
+                    defaultEventIndex = i;
+                }
+            }
+        }
+        
         return result;
     }
 
@@ -256,15 +281,12 @@
     }
 
     public int getDefaultEventIndex() {
-        int result = -1;
-
-        if (info != null) {
-            result = info.getDefaultEventIndex();
-        } else if (parentBeanInfoWrapper != null) {
-            result = parentBeanInfoWrapper.getDefaultEventIndex();
-        }
 
-        return result;
+    	if (events == null) {
+            events = getEventSetDescriptors();
+    	} 
+    	
+    	return defaultEventIndex;
     }
 
     void setParentToMerge(BeanInfoWrapper parentBeanInfoWrapper) {

Modified: harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/Introspector.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/Introspector.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/Introspector.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/beans/src/main/java/java/beans/Introspector.java Sat Jun 23 13:53:42 2007
@@ -162,7 +162,6 @@
         // ...
 
         wrapper = new BeanInfoWrapper(beanInfo, beanInfoImpl);
-
         parent = beanClass.getSuperclass();
         
         if (parent != null && parent != stopClass) {
@@ -176,7 +175,7 @@
 
         storeBeanInfoClassInCache(wrapper, beanClass, stopClass,
                 ignoreBeanClassBeanInfo, ignoreSuperClassBeanInfo);
-
+        
         return wrapper;
     }
 

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/META-INF/MANIFEST.MF
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/META-INF/MANIFEST.MF?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/META-INF/MANIFEST.MF (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/META-INF/MANIFEST.MF Sat Jun 23 13:53:42 2007
@@ -35,12 +35,10 @@
  javax.net.ssl,
  org.apache.harmony.kernel.vm,
  org.apache.harmony.security.asn1;version="1.0.0",
- org.apache.harmony.security.x509;version="1.0.0"
+ org.apache.harmony.security.x509;version="1.0.0",
+ org.apache.harmony.testframework.serialization;hy_usage=test;resolution:=optional
 Export-Package: javax.naming,
  javax.naming.directory,
  javax.naming.event,
  javax.naming.ldap,
  javax.naming.spi
-Require-Bundle: org.apache.harmony.support
-
-

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationException.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationException.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationException.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationException.java Sat Jun 23 13:53:42 2007
@@ -15,45 +15,37 @@
  * limitations under the License.
  */
 
-
 package javax.naming;
 
 /**
- * An <code>AuthenticationException</code> is the 
+ * An <code>AuthenticationException</code> is the
  * <code>NamingSecurityException</code> used when authentication fails.
  * <p>
- * Multithreaded access to an <code>AuthenticationException</code> instance
- * is only safe when client code locks the object first.</p>
- * 
+ * Multithreaded access to an <code>AuthenticationException</code> instance is
+ * only safe when client code locks the object first.
+ * </p>
  */
 public class AuthenticationException extends NamingSecurityException {
 
     static final long serialVersionUID = 3678497619904568096L;
 
-    /*
-     * -------------------------------------------------------------------
-     * Constructors
-     * -------------------------------------------------------------------
-     */
-
     /**
-     * Constructs an <code>AuthenticationException</code> instance
-     * with all data initialized to null.
+     * Constructs an <code>AuthenticationException</code> instance with all
+     * data initialized to null.
      */
     public AuthenticationException() {
         super();
     }
 
     /**
-     * Constructs an <code>AuthenticationException</code> instance 
-     * using the specified message.
+     * Constructs an <code>AuthenticationException</code> instance using the
+     * specified message.
      * 
-     * @param s The detail message for the exception. It may be null.
+     * @param s
+     *            The detail message for the exception. It may be null.
      */
     public AuthenticationException(String s) {
         super(s);
     }
 
 }
-
-

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationNotSupportedException.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationNotSupportedException.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationNotSupportedException.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/AuthenticationNotSupportedException.java Sat Jun 23 13:53:42 2007
@@ -15,28 +15,22 @@
  * limitations under the License.
  */
 
-
 package javax.naming;
 
 /**
- * An <code>AuthenticationNotSupportedException</code> is the 
- * <code>NamingSecurityException</code> used
- * when the authentication required is not available.
+ * An <code>AuthenticationNotSupportedException</code> is the
+ * <code>NamingSecurityException</code> used when the authentication required
+ * is not available.
  * <p>
- * Multithreaded access to an <code>AuthenticationNotSupportedException</code> 
- * instance is only safe when client code locks the object first.</p>
- * 
+ * Multithreaded access to an <code>AuthenticationNotSupportedException</code>
+ * instance is only safe when client code locks the object first.
+ * </p>
  */
-public class AuthenticationNotSupportedException extends NamingSecurityException {
+public class AuthenticationNotSupportedException extends
+        NamingSecurityException {
 
     static final long serialVersionUID = -7149033933259492300L;
 
-    /*
-     * -------------------------------------------------------------------
-     * Constructors
-     * -------------------------------------------------------------------
-     */
-
     /**
      * Constructs an <code>AuthenticationNotSupportedException</code> instance
      * with all data initialized to null.
@@ -49,12 +43,11 @@
      * Constructs an <code>AuthenticationNotSupportedException</code> instance
      * using the specified message.
      * 
-     * @param s The detail message for the exception. It may be null.
+     * @param s
+     *            The detail message for the exception. It may be null.
      */
     public AuthenticationNotSupportedException(String s) {
         super(s);
     }
 
 }
-
-

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/BinaryRefAddr.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/BinaryRefAddr.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/BinaryRefAddr.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/BinaryRefAddr.java Sat Jun 23 13:53:42 2007
@@ -38,8 +38,10 @@
      * Constructs a <code>BinaryRefAddr</code> using the specified address
      * type and the full details of the supplied byte array.
      * 
-     * @param type the address type which cannot be null
-     * @param address the address itself which cannot be null
+     * @param type
+     *            the address type which cannot be null
+     * @param address
+     *            the address itself which cannot be null
      */
     public BinaryRefAddr(String type, byte[] address) {
         this(type, address, 0, address.length);
@@ -51,16 +53,21 @@
      * is specified by <code>size</code>. Additionally these bytes are taken
      * from a starting point specified by <code>index</code>.
      * 
-     * @param type the address type. It cannot be null.
-     * @param address the address itself. It cannot be null.
-     * @param index the starting point to copy bytes from. It must be greater
-     *        than or equal to zero and must be less than or equal to the size
-     *        of the byte array.
-     * @param size the number of bytes to copy. It must be greater than or equal
-     *        to zero and must be less than or equal to the size of the byte
-     *        array less the starting position.
-     * @throws ArrayIndexOutOfBoundsException If <code>size</code> or
-     *         <code>index</code> does not meet the constraints.
+     * @param type
+     *            the address type. It cannot be null.
+     * @param address
+     *            the address itself. It cannot be null.
+     * @param index
+     *            the starting point to copy bytes from. It must be greater than
+     *            or equal to zero and must be less than or equal to the size of
+     *            the byte array.
+     * @param size
+     *            the number of bytes to copy. It must be greater than or equal
+     *            to zero and must be less than or equal to the size of the byte
+     *            array less the starting position.
+     * @throws ArrayIndexOutOfBoundsException
+     *             If <code>size</code> or <code>index</code> does not meet
+     *             the constraints.
      */
     public BinaryRefAddr(String type, byte[] address, int index, int size) {
         super(type);
@@ -84,7 +91,8 @@
      * equal and the data in the buffers is of the same length and contains the
      * same bytes.
      * 
-     * @param o the object to compare with
+     * @param o
+     *            the object to compare with
      * @return true if this address is equal to <code>o</code>, otherwise
      *         false
      */
@@ -92,7 +100,8 @@
     public boolean equals(Object o) {
         if (o instanceof BinaryRefAddr) {
             BinaryRefAddr a = (BinaryRefAddr) o;
-            return this.addrType.equals(a.addrType) && Arrays.equals(this.buf, a.buf);
+            return this.addrType.equals(a.addrType)
+                    && Arrays.equals(this.buf, a.buf);
         }
         return false;
     }
@@ -133,4 +142,5 @@
 
         return s;
     }
+
 }

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Binding.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Binding.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Binding.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/Binding.java Sat Jun 23 13:53:42 2007
@@ -15,50 +15,32 @@
  * limitations under the License.
  */
 
- 
 package javax.naming;
 
 /**
  * Binding extends <code>NameClassPair</code> to associate an object in a
- * naming service with its name, specified class name and relative flag.
- * As with <code>NameClassPair</code>, a class name is only specified when 
- * it is necessary to override the real class name of the associated object.
+ * naming service with its name, specified class name and relative flag. As with
+ * <code>NameClassPair</code>, a class name is only specified when it is
+ * necessary to override the real class name of the associated object.
  * <p>
- * Multithreaded access to a <code>Binding</code> instance is only safe when 
- * client code locks the object first.</p>
- * 
+ * Multithreaded access to a <code>Binding</code> instance is only safe when
+ * client code locks the object first.
+ * </p>
  */
 public class Binding extends NameClassPair {
 
-    /*
-     * -------------------------------------------------------------------
-     * Constants
-     * -------------------------------------------------------------------
-     */
-
-    // J2SE 1.4.2
     private static final long serialVersionUID = 8839217842691845890L;
 
-    /*
-     * -------------------------------------------------------------------
-     * Instance variables
-     * -------------------------------------------------------------------
-     */
-
     private Object boundObj;
 
-    /*
-     * -------------------------------------------------------------------
-     * Constructors
-     * -------------------------------------------------------------------
-     */
-
     /**
-     * Construct a <code>Binding</code> from a name and a class.
-     * Relative flag is true.
-     *
-     * @param name  a name, may not be <code>null</code>.
-     * @param obj   an object bound with the name, may be <code>null</code>.
+     * Construct a <code>Binding</code> from a name and a class. Relative flag
+     * is true.
+     * 
+     * @param name
+     *            a name, may not be <code>null</code>.
+     * @param obj
+     *            an object bound with the name, may be <code>null</code>.
      */
     public Binding(String name, Object obj) {
         this(name, null, obj, true);
@@ -67,10 +49,13 @@
     /**
      * Construct a <code>Binding</code> from a name, an object and a relative
      * flag.
-     *
-     * @param name      a name, which may not be <code>null</code>.
-     * @param obj       an object bound with the name, may be <code>null</code>.
-     * @param relative  a relative flag
+     * 
+     * @param name
+     *            a name, which may not be <code>null</code>.
+     * @param obj
+     *            an object bound with the name, may be <code>null</code>.
+     * @param relative
+     *            a relative flag
      */
     public Binding(String name, Object obj, boolean relative) {
         this(name, null, obj, relative);
@@ -78,12 +63,14 @@
 
     /**
      * Construct a <code>Binding</code> from a name, a class, and an object.
-     * The class and object parameters may be null.
-     * Relative flag is true.
-     *
-     * @param name      a name, which may not be <code>null</code>.
-     * @param className a class name, may be <code>null</code>.
-     * @param obj       an object bound with the name, may be <code>null</code>.
+     * The class and object parameters may be null. Relative flag is true.
+     * 
+     * @param name
+     *            a name, which may not be <code>null</code>.
+     * @param className
+     *            a class name, may be <code>null</code>.
+     * @param obj
+     *            an object bound with the name, may be <code>null</code>.
      */
     public Binding(String name, String className, Object obj) {
         this(name, className, obj, true);
@@ -92,36 +79,29 @@
     /**
      * Construct a <code>Binding</code> from a name, a class, an object and a
      * relative flag. The class and object parameters may be null.
-     *
-     * @param name      a name, which may not be <code>null</code>.
-     * @param className a class name, may be <code>null</code>.
-     * @param obj       an object bound with the name, may be <code>null</code>.
-     * @param relative  a relative flag
-     */
-    public Binding(
-        String name,
-        String className,
-        Object obj,
-        boolean relative) {
+     * 
+     * @param name
+     *            a name, which may not be <code>null</code>.
+     * @param className
+     *            a class name, may be <code>null</code>.
+     * @param obj
+     *            an object bound with the name, may be <code>null</code>.
+     * @param relative
+     *            a relative flag
+     */
+    public Binding(String name, String className, Object obj, boolean relative) {
         super(name, className, relative);
         this.boundObj = obj;
     }
 
-    /*
-     * -------------------------------------------------------------------
-     * Methods
-     * -------------------------------------------------------------------
-     */
-
     /**
-     * Get the class name of this <code>Binding</code>.
-     * It may have been specified, in which case the class name field is set,
-     * and that is the string returned by this method.
-     * If the class name field has not been specified then the object 
-     * associated with this <code>Binding</code> is interrogated to find its 
-     * actual class name. If there is no class name field specified and no 
-     * associated object then this method returns null.
-     *
+     * Get the class name of this <code>Binding</code>. It may have been
+     * specified, in which case the class name field is set, and that is the
+     * string returned by this method. If the class name field has not been
+     * specified then the object associated with this <code>Binding</code> is
+     * interrogated to find its actual class name. If there is no class name
+     * field specified and no associated object then this method returns null.
+     * 
      * @return the class name
      */
     @Override
@@ -136,11 +116,11 @@
     }
 
     /**
-     * Get the object associated with this <code>Binding</code>. May return 
+     * Get the object associated with this <code>Binding</code>. May return
      * null.
      * 
-     * @return the object associated with this <code>Binding</code>. 
-     *          May return null.
+     * @return the object associated with this <code>Binding</code>. May
+     *         return null.
      */
     public Object getObject() {
         return boundObj;
@@ -150,21 +130,16 @@
      * Set the object o associated with this <code>Binding</code>. The object
      * may be null.
      * 
-     * @param object    an object
+     * @param object
+     *            an object
      */
     public void setObject(Object object) {
         this.boundObj = object;
     }
 
-    /*
-     * -------------------------------------------------------------------
-     * Methods override parent class Object
-     * -------------------------------------------------------------------
-     */
-
     /**
      * Provide a string representation of this object. This is the same as for
-     * <code>NameClassPair</code> but with the string representation of the 
+     * <code>NameClassPair</code> but with the string representation of the
      * <code>Binding</code> object appended to the end.
      * 
      * @return a string representation of this <code>Binding</code>
@@ -175,5 +150,3 @@
     }
 
 }
-
-

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CannotProceedException.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CannotProceedException.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CannotProceedException.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CannotProceedException.java Sat Jun 23 13:53:42 2007
@@ -15,145 +15,124 @@
  * limitations under the License.
  */
 
-
 package javax.naming;
 
 import java.util.Hashtable;
 
 /**
- * Naming operations throw a <code>CannotProceedException</code> when the 
- * service provider context implementation is resolving a name but reaches a 
+ * Naming operations throw a <code>CannotProceedException</code> when the
+ * service provider context implementation is resolving a name but reaches a
  * name component that does not belong to the namespace of the current context.
  * <p>
- * The service provider is able to create a <code>CannotProceedException</code> 
- * object and use methods on that object (including baseclass methods) to 
- * provide full details of how far name resolution had progressed.</p>
+ * The service provider is able to create a <code>CannotProceedException</code>
+ * object and use methods on that object (including baseclass methods) to
+ * provide full details of how far name resolution had progressed.
+ * </p>
  * <p>
  * Typically, the methods used might include:
  * <ul>
- * <li><code>setEnvironment</code> to record the environment from the current 
+ * <li><code>setEnvironment</code> to record the environment from the current
  * context</li>
- * <li>
- * <code>setAltNameCtx</code> to record the current context</li>
- * <li>
- * <code>setResolvedObj</code> to record the resolved object for the next 
+ * <li> <code>setAltNameCtx</code> to record the current context</li>
+ * <li> <code>setResolvedObj</code> to record the resolved object for the next
  * naming system</li>
- * <li>
- * <code>setAltName</code> to record the name of the resolved object</li>
- * <li>
- * <code>setRemainingName</code> to record the remaining unresolved name</li>
- * </ul></p>
+ * <li> <code>setAltName</code> to record the name of the resolved object</li>
+ * <li> <code>setRemainingName</code> to record the remaining unresolved name</li>
+ * </ul>
+ * </p>
  * <p>
- * If the incomplete naming operation is <code>rename</code>, the service 
- * provider should also use the <code>setRemainingNewName</code> method to 
- * record the unresolved part of the new name.</p>
+ * If the incomplete naming operation is <code>rename</code>, the service
+ * provider should also use the <code>setRemainingNewName</code> method to
+ * record the unresolved part of the new name.
+ * </p>
  * <p>
- * The service provider can pass the <code>CannotProceedException</code> as a 
- * parameter to <code>NamingManager</code> methods such as 
- * <code>getContinuationContext</code> to attempt to locate another service 
- * provider for the next naming system. If successful, that service provider 
- * can return a new <code>Context</code> object on which the naming operation
- * can proceed further. If unsuccessful, the <code>CannotProceedException</code>
- * can be thrown by the service provider so that the JNDI application can
- * handle it and take appropriate action.</p>
+ * The service provider can pass the <code>CannotProceedException</code> as a
+ * parameter to <code>NamingManager</code> methods such as
+ * <code>getContinuationContext</code> to attempt to locate another service
+ * provider for the next naming system. If successful, that service provider can
+ * return a new <code>Context</code> object on which the naming operation can
+ * proceed further. If unsuccessful, the <code>CannotProceedException</code>
+ * can be thrown by the service provider so that the JNDI application can handle
+ * it and take appropriate action.
+ * </p>
  * <p>
- * Multithreaded access to a single <code>CannotProceedException</code> 
- * instance is only safe when client code uses appropriate synchronization 
- * and locking.</p>
+ * Multithreaded access to a single <code>CannotProceedException</code>
+ * instance is only safe when client code uses appropriate synchronization and
+ * locking.
+ * </p>
  * 
  */
 public class CannotProceedException extends NamingException {
 
     /*
-     * -----------------------------------------
-     * Constants
-     * -----------------------------------------
-     */
-    
-    /*
-     * This constant is used during deserialization to check the J2SE version
-     * which created the serialized object.
+     * This constant is used during deserialization to check the version which
+     * created the serialized object.
      */
     private final static long serialVersionUID = 1219724816191576813L;
 
-    /*
-     * -------------------------------------------------------------------
-     * Instance variables
-     * -------------------------------------------------------------------
-     */
-
     /**
      * Contains a composite name that is the name of the resolved object which
-     * is relative to the context in <code>altNameCtx</code>. This field may 
-     * be null and is initially null. This field should be accessed and 
-     * modified using only <code>getAltName</code> and <code>setAltName</code>.
+     * is relative to the context in <code>altNameCtx</code>. This field may
+     * be null and is initially null. This field should be accessed and modified
+     * using only <code>getAltName</code> and <code>setAltName</code>.
      */
     protected Name altName = null;
 
     /**
-     * Contains the context to which the <code>altName</code> field is relative.
-     * This field may be null and is initially null. A null value implies the 
-     * default initial context.  This field should be accessed and modified 
-     * using only <code>getAltNameCtx</code> and <code>setAltNameCtx</code>.
+     * Contains the context to which the <code>altName</code> field is
+     * relative. This field may be null and is initially null. A null value
+     * implies the default initial context. This field should be accessed and
+     * modified using only <code>getAltNameCtx</code> and
+     * <code>setAltNameCtx</code>.
      */
     protected Context altNameCtx = null;
 
     /**
      * Contains the environment of the context in which name resolution for the
      * naming operation could not proceed further. Initially null. Should only
-     * be manipulated using <code>getEnvironment</code> 
-     * and <code>setEnvironment methods</code>. 
+     * be manipulated using <code>getEnvironment</code> and
+     * <code>setEnvironment methods</code>.
      */
     protected Hashtable<?, ?> environment = null;
 
     /**
-     * Contains a composite name that is the unresolved part of the new name 
-     * that was specified in a <code>Context.rename</code> operation and may 
-     * be used to continue the <code>rename</code> operation. This field may 
-     * be null and is initially null. This field should be accessed and 
-     * modified using only <code>getRemainingNewName</code> 
-     * and <code>setRemainingNewName</code>.
+     * Contains a composite name that is the unresolved part of the new name
+     * that was specified in a <code>Context.rename</code> operation and may
+     * be used to continue the <code>rename</code> operation. This field may
+     * be null and is initially null. This field should be accessed and modified
+     * using only <code>getRemainingNewName</code> and
+     * <code>setRemainingNewName</code>.
      */
     protected Name remainingNewName = null;
 
-    /*
-     * =======
-     * Constructors
-     * =======
-     */
-
     /**
-     * Constructs a <code>CannotProceedException</code> object. 
-     * All unspecified fields are initialized to null.
+     * Constructs a <code>CannotProceedException</code> object. All
+     * unspecified fields are initialized to null.
      */
     public CannotProceedException() {
         super();
     }
 
     /**
-     * Constructs a <code>CannotProceedException</code> object with an 
-     * optionally specified <code>String</code> parameter containing a 
-     * detailed explanation message. The <code>String</code> parameter may
-     * be null. All unspecified fields are initialized to null.
-     * 
-     * @param s The detailed explanation message for the exception. 
-     * It may be null.
+     * Constructs a <code>CannotProceedException</code> object with an
+     * optionally specified <code>String</code> parameter containing a
+     * detailed explanation message. The <code>String</code> parameter may be
+     * null. All unspecified fields are initialized to null.
+     * 
+     * @param s
+     *            The detailed explanation message for the exception. It may be
+     *            null.
      */
     public CannotProceedException(String s) {
         super(s);
     }
 
-    /*
-     * =======
-     * Methods
-     * =======
-     */
-
     /**
      * Retrieves the value of the <code>altName</code> field.
      * 
      * @return the value of the <code>altName</code> field.
-     * @see javax.naming.spi.ObjectFactory#getObjectInstance(Object, Name, Context, Hashtable)
+     * @see javax.naming.spi.ObjectFactory#getObjectInstance(Object, Name,
+     *      Context, Hashtable)
      */
     public Name getAltName() {
         return altName;
@@ -163,18 +142,19 @@
      * Retrieves the value of the <code>altNameCtx</code> field.
      * 
      * @return the value of the <code>altNameCtx</code> field.
-     * @see javax.naming.spi.ObjectFactory#getObjectInstance(Object, Name, Context, Hashtable)
+     * @see javax.naming.spi.ObjectFactory#getObjectInstance(Object, Name,
+     *      Context, Hashtable)
      */
     public Context getAltNameCtx() {
         return altNameCtx;
     }
 
     /**
-     * Retrieves the value of the protected field <code>environment</code> 
+     * Retrieves the value of the protected field <code>environment</code>
      * which may be null.
      * 
-     * @return the value of the protected field <code>environment</code> 
-     * which may be null.
+     * @return the value of the protected field <code>environment</code> which
+     *         may be null.
      */
     public Hashtable<?, ?> getEnvironment() {
         return environment;
@@ -190,51 +170,55 @@
     }
 
     /**
-     * Modifies the value of the <code>altName</code> field to the specified 
+     * Modifies the value of the <code>altName</code> field to the specified
      * <code>Name</code> parameter which is a composite name and may be null.
      * 
-     * @param name the name to set.
+     * @param name
+     *            the name to set.
      */
     public void setAltName(Name name) {
         altName = name;
     }
 
     /**
-     * Modifies the value of the <code>altNameCtx</code> field to the specified
-     * <code>Context</code> parameter which may be null.
+     * Modifies the value of the <code>altNameCtx</code> field to the
+     * specified <code>Context</code> parameter which may be null.
      * 
-     * @param context the new context to set.
+     * @param context
+     *            the new context to set.
      */
     public void setAltNameCtx(Context context) {
         altNameCtx = context;
     }
 
     /**
-     * Sets the value of the protected field <code>environment</code> from the 
+     * Sets the value of the protected field <code>environment</code> from the
      * <code>environment</code> parameter which may be null.
      * 
-     * @param hashtable the new environment to set.
+     * @param hashtable
+     *            the new environment to set.
      */
     public void setEnvironment(Hashtable<?, ?> hashtable) {
         environment = hashtable;
     }
 
     /**
-     * Modifies the value of the <code>remainingNewName</code> field to the 
-     * specified parameter which may be null. But otherwise is a composite 
-     * name. When needing to specify other names, first convert them into a 
-     * composite name with a single component, and then specify that composite
-     * name when invoking this method.
+     * Modifies the value of the <code>remainingNewName</code> field to the
+     * specified parameter which may be null. But otherwise is a composite name.
+     * When needing to specify other names, first convert them into a composite
+     * name with a single component, and then specify that composite name when
+     * invoking this method.
      * <p>
-     * When a non-null name is specified, a clone of the composite name is 
-     * stored in the <code>remainingNewName</code> field that becomes 
-     * independent of the specified name.</p>
-     *  
-     * @param name the new name to set.
+     * When a non-null name is specified, a clone of the composite name is
+     * stored in the <code>remainingNewName</code> field that becomes
+     * independent of the specified name.
+     * </p>
+     * 
+     * @param name
+     *            the new name to set.
      */
     public void setRemainingNewName(Name name) {
         remainingNewName = (null == name) ? null : (Name) name.clone();
     }
-}
-
 
+}

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CommunicationException.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CommunicationException.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CommunicationException.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CommunicationException.java Sat Jun 23 13:53:42 2007
@@ -15,43 +15,41 @@
  * limitations under the License.
  */
 
-
 package javax.naming;
 
 /**
- * This is the <code>NamingException</code> used when communication with the 
+ * This is the <code>NamingException</code> used when communication with the
  * naming or directory service fails.
  * <p>
  * Multithreaded access to an instance is only safe when client code locks the
- * object first.</p>
- * 
+ * object first.
+ * </p>
  */
 public class CommunicationException extends NamingException {
-    
-	/*
-     * This constant is used during deserialization to check the J2SE version
-     * which created the serialized object.
+
+    /*
+     * This constant is used during deserialization to check the version which
+     * created the serialized object.
      */
-	static final long serialVersionUID = 3618507780299986611L; // J2SE 1.4.2	
+    static final long serialVersionUID = 3618507780299986611L;
 
     /**
-     * Constructs a <code>CommunicationException</code> instance with all 
-     * data initialized to null.
+     * Constructs a <code>CommunicationException</code> instance with all data
+     * initialized to null.
      */
     public CommunicationException() {
         super();
     }
 
     /**
-     * Constructs a <code>CommunicationException</code> instance using the 
+     * Constructs a <code>CommunicationException</code> instance using the
      * specified message.
      * 
-     * @param s The detail message for the exception. It may be null.
+     * @param s
+     *            The detail message for the exception. It may be null.
      */
     public CommunicationException(String s) {
         super(s);
     }
 
 }
-
-

Modified: harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CompositeName.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CompositeName.java?view=diff&rev=550106&r1=550105&r2=550106
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CompositeName.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/jndi/src/main/java/javax/naming/CompositeName.java Sat Jun 23 13:53:42 2007
@@ -28,100 +28,111 @@
 import org.apache.harmony.jndi.internal.nls.Messages;
 
 /**
- * A <code>CompositeName</code> represents a name in a naming service which 
- * spans multiple namespaces. For example the name 
- * "www.eclipse.org/index.html" spans the DNS and file system namespaces.
- * <p>
- * A <code>CompositeName</code> is a series of string elements. A composite 
- * name has a sequence of zero or more elements delimited by the '/' char.
- * Each element can be accessed using its position. The first element is at 
- * position 0.</p>
- * <p>
- * A <code>CompositeName</code> may be empty. An empty composite name has no 
- * elements. Elements may also be empty.</p>
- * <p>
- * <code>CompositeName</code>s are read from left to right unlike 
- * <code>CompoundName</code>s which may have their direction of ordering 
- * specified by properties.</p>
+ * A <code>CompositeName</code> represents a name in a naming service which
+ * spans multiple namespaces. For example the name "www.eclipse.org/index.html"
+ * spans the DNS and file system namespaces.
+ * <p>
+ * A <code>CompositeName</code> is a series of string elements. A composite
+ * name has a sequence of zero or more elements delimited by the '/' char. Each
+ * element can be accessed using its position. The first element is at position
+ * 0.
+ * </p>
+ * <p>
+ * A <code>CompositeName</code> may be empty. An empty composite name has no
+ * elements. Elements may also be empty.
+ * </p>
+ * <p>
+ * <code>CompositeName</code>s are read from left to right unlike
+ * <code>CompoundName</code>s which may have their direction of ordering
+ * specified by properties.
+ * </p>
  * <p>
- * Special characters are as follows:</p>
+ * Special characters are as follows:
+ * </p>
  * <ul>
  * <li>The separator is /</li>
  * <li>The escape character is \</li>
  * <li>Quotes can be used - both single quotes and double quotes are allowed.
- * This allows you to quote strings which contain chars such as / which are
- * part of a <code>CompositeName</code> element to avoid them being read as a 
+ * This allows you to quote strings which contain chars such as / which are part
+ * of a <code>CompositeName</code> element to avoid them being read as a
  * separator.</li>
  * </ul>
  * <p>
- * See the examples for further clarification.</p>
+ * See the examples for further clarification.
+ * </p>
  * <p>
  * Some Examples:<br />
- * ==============</p>
+ * ==============
+ * </p>
  * <p>
  * The composite name "www.eclipse.org/index.html" has 2 elements.
- * "www.eclipse.org" is a name from the DNS namespace.
- * "index.html" is a name from the file system namespace.</p>
+ * "www.eclipse.org" is a name from the DNS namespace. "index.html" is a name
+ * from the file system namespace.
+ * </p>
  * <p>
- * Another example of a composite name is:
- * "www.eclipse.org/org/index.html".
+ * Another example of a composite name is: "www.eclipse.org/org/index.html".
  * This name has 3 elements "www.eclipse.org", "org" and "index.html".
- * www.eclipse.org is a name from the DNS namespace.
- * The last 2 elements are each from the file system namespace.</p>
+ * www.eclipse.org is a name from the DNS namespace. The last 2 elements are
+ * each from the file system namespace.
+ * </p>
  * <p>
- * Some more examples to clarify empty names and elements:</p>
+ * Some more examples to clarify empty names and elements:
+ * </p>
  * <p>
- * An empty CompositeName is the name "" and has no elements.</p>
+ * An empty CompositeName is the name "" and has no elements.
+ * </p>
  * <p>
- * A CompositeName with just one empty element is the name "/".</p>
+ * A CompositeName with just one empty element is the name "/".
+ * </p>
  * <p>
- * The name "/org/" has 3 elements. The first and last are empty.</p>
+ * The name "/org/" has 3 elements. The first and last are empty.
+ * </p>
  * <p>
- * The name "/a" has 2 elements. The first element is empty
- * and the second element is "a".</p>
+ * The name "/a" has 2 elements. The first element is empty and the second
+ * element is "a".
+ * </p>
  * <p>
- * The name "a//a" has 3 elements. The middle element is empty
- * and the first & third elements are both "a".</p>
+ * The name "a//a" has 3 elements. The middle element is empty and the first &
+ * third elements are both "a".
+ * </p>
  * <p>
- * The name "a/'b/a" is invalid as there is no closing quote for the ' 
- * character.</p>
+ * The name "a/'b/a" is invalid as there is no closing quote for the '
+ * character.
+ * </p>
  * <p>
- * The name "a/'a/b/b" is invalid as there is no closing quote for the ' 
- * character.</p>
+ * The name "a/'a/b/b" is invalid as there is no closing quote for the '
+ * character.
+ * </p>
  * <p>
  * The name "a/\"b/a" is interpreted as a/"b/a and is invalid as there is no
- * closing quote for the embedded escaped " character.</p>
+ * closing quote for the embedded escaped " character.
+ * </p>
  * <p>
  * The name "a/'b/c'/a" has 3 elements. The middle element is b/c.
  * <p>
- * The name "a/a'a/b'/b" has 4 elements:
- * Element 0 is "a".
- * Element 1 is "a'a".
- * Element 2 is "b'".
- * Element 3 is "b".</p>
- * <p>
- * Interestingly the name "a/a'a/b/b" is valid and has 4 elements. This is 
- * because the single quote char ' is not a leading quote and is embedded in 
- * an element so is treated as a character.
- * Element 0 is "a".
- * Element 1 is "a'a".
- * Element 2 is "b".
- * Element 3 is "b".</p>
- * <p>
- * The name "\"abcd" gives an <code>InvalidNameException</code> as there is 
- * no closing quote.</p>
- * <p>
- * The name "'\"abcd'" gives one element of value "abcd.</p>
- * <p>
- * The name "\\abcd" gives one element of value \abcd.</p>
- * <p>
- * "" is empty. It has no elements.
- * "/" has one empty element.
- * "//" has 2 empty elements.
- * "/a/" has 3 elements the middle one is set to a.
- * "///" has 3 empty elements.
- * "//a/" has 4 elements, the last but one is set to a.</p>
- *
+ * The name "a/a'a/b'/b" has 4 elements: Element 0 is "a". Element 1 is "a'a".
+ * Element 2 is "b'". Element 3 is "b".
+ * </p>
+ * <p>
+ * Interestingly the name "a/a'a/b/b" is valid and has 4 elements. This is
+ * because the single quote char ' is not a leading quote and is embedded in an
+ * element so is treated as a character. Element 0 is "a". Element 1 is "a'a".
+ * Element 2 is "b". Element 3 is "b".
+ * </p>
+ * <p>
+ * The name "\"abcd" gives an <code>InvalidNameException</code> as there is no
+ * closing quote.
+ * </p>
+ * <p>
+ * The name "'\"abcd'" gives one element of value "abcd.
+ * </p>
+ * <p>
+ * The name "\\abcd" gives one element of value \abcd.
+ * </p>
+ * <p> "" is empty. It has no elements. "/" has one empty element. "//" has 2
+ * empty elements. "/a/" has 3 elements the middle one is set to a. "///" has 3
+ * empty elements. "//a/" has 4 elements, the last but one is set to a.
+ * </p>
  */
 public class CompositeName implements Name {
 
@@ -141,8 +152,9 @@
 
     /**
      * Private copy constructor.
-     *
-     * @param elements  a list of name elements
+     * 
+     * @param elements
+     *            a list of name elements
      */
     private CompositeName(List<String> elements) {
         super();
@@ -151,8 +163,9 @@
 
     /**
      * Construct a composite name with given elements.
-     *
-     * @param elements  an enumeration of name elements
+     * 
+     * @param elements
+     *            an enumeration of name elements
      */
     protected CompositeName(Enumeration<String> elements) {
         super();
@@ -173,9 +186,11 @@
     /**
      * This constructor takes the supplied name and breaks it down into its
      * elements.
-     *
-     * @param name  a string containing the full composite name
-     * @throws InvalidNameException if the supplied name is invalid
+     * 
+     * @param name
+     *            a string containing the full composite name
+     * @throws InvalidNameException
+     *             if the supplied name is invalid
      */
     public CompositeName(String name) throws InvalidNameException {
         super();
@@ -183,10 +198,11 @@
     }
 
     /**
-     * Parse string name elements. Delimiter is "/".
-     * Escape is "\" and both single quote and double quote are supported.
+     * Parse string name elements. Delimiter is "/". Escape is "\" and both
+     * single quote and double quote are supported.
      */
-    private static Vector<String> parseName(String name) throws InvalidNameException {
+    private static Vector<String> parseName(String name)
+            throws InvalidNameException {
 
         Vector<String> l = new Vector<String>();
 
@@ -199,7 +215,8 @@
         }
 
         // general simple case, without escape and quote
-        if (name.indexOf('"') < 0 && name.indexOf('\'') < 0 && name.indexOf('\\') < 0) {
+        if (name.indexOf('"') < 0 && name.indexOf('\'') < 0
+                && name.indexOf('\\') < 0) {
             int i = 0, j = 0;
             while ((j = name.indexOf('/', i)) >= 0) {
                 l.add(name.substring(i, j));
@@ -226,7 +243,7 @@
                     continue;
                 }
                 // jndi.0C=End quote is not at the end of element
-                throw new InvalidNameException(Messages.getString("jndi.0C"));  //$NON-NLS-1$
+                throw new InvalidNameException(Messages.getString("jndi.0C")); //$NON-NLS-1$
             }
 
             if (c == '\\') {
@@ -241,7 +258,8 @@
                     }
                 } catch (ArrayIndexOutOfBoundsException e) {
                     // jndi.0D=Escape cannot be at the end of element
-                    throw new InvalidNameException(Messages.getString("jndi.0D"));  //$NON-NLS-1$
+                    throw new InvalidNameException(Messages
+                            .getString("jndi.0D")); //$NON-NLS-1$
                 }
                 continue;
             }
@@ -272,7 +290,7 @@
         // check end status
         if (status != OUT_OF_QUOTE && status != QUOTE_ENDED) {
             // jndi.0E=Wrong quote usage.
-            throw new InvalidNameException(Messages.getString("jndi.0E"));  //$NON-NLS-1$
+            throw new InvalidNameException(Messages.getString("jndi.0E")); //$NON-NLS-1$
         }
         return l;
     }
@@ -307,8 +325,8 @@
             if (i > 0) {
                 buf.append("/"); //$NON-NLS-1$
             }
-            if (elem.indexOf('/') < 0 && elem.indexOf('\\') < 0 && elem.indexOf('\'') < 0
-                    && elem.indexOf('"') < 0) {
+            if (elem.indexOf('/') < 0 && elem.indexOf('\\') < 0
+                    && elem.indexOf('\'') < 0 && elem.indexOf('"') < 0) {
                 buf.append(elem);
             } else {
                 char chars[] = elem.toCharArray();
@@ -361,7 +379,7 @@
         }
         if (!(name instanceof CompositeName)) {
             // jndi.0F=Must be a CompositeName
-            throw new InvalidNameException(Messages.getString("jndi.0F"));  //$NON-NLS-1$
+            throw new InvalidNameException(Messages.getString("jndi.0F")); //$NON-NLS-1$
         }
 
         Enumeration<String> enumeration = name.getAll();
@@ -377,7 +395,7 @@
         }
         if (!(name instanceof CompositeName)) {
             // jndi.0F=Must be a CompositeName
-            throw new InvalidNameException(Messages.getString("jndi.0F"));  //$NON-NLS-1$
+            throw new InvalidNameException(Messages.getString("jndi.0F")); //$NON-NLS-1$
         }
 
         if (index < 0 || index > elems.size()) {
@@ -467,17 +485,18 @@
     /**
      * Compare this <code>Name</code> with the one supplied as a parameter.
      * The elements of the names are compared in the same way as strings are
-     * compared to determine whether this <code>CompositeName</code> is less 
+     * compared to determine whether this <code>CompositeName</code> is less
      * than, greater than or equal to the supplied object <code>o</code>.
      * 
-     * @param o the object to compare, cannot be null
-     * @return  a negative number means this is less than the supplied object;
-     *          a positive number means this is greater than the supplied 
-     *          object; zero means this CompositeName equals the object as 
-     *          specified in the description for the equals method of 
-     *          <code>CompositeName</code>.
-     * @throws ClassCastException when <code>o</code> is not a 
-     *          <code>CompositeName</code>.
+     * @param o
+     *            the object to compare, cannot be null
+     * @return a negative number means this is less than the supplied object; a
+     *         positive number means this is greater than the supplied object;
+     *         zero means this CompositeName equals the object as specified in
+     *         the description for the equals method of
+     *         <code>CompositeName</code>.
+     * @throws ClassCastException
+     *             when <code>o</code> is not a <code>CompositeName</code>.
      */
     public int compareTo(Object o) {
         if (o instanceof CompositeName) {
@@ -501,8 +520,9 @@
     }
 
     /**
-     * Create a copy of this composite name, a complete (deep) copy of the object.
-     *
+     * Create a copy of this composite name, a complete (deep) copy of the
+     * object.
+     * 
      * @return a complete (deep) copy of the object.
      */
     @Override
@@ -511,13 +531,13 @@
     }
 
     /**
-     * Returns the string representation of this <code>CompositeName</code>. 
-     * This is generated by concatenating the elements together with the '/' 
-     * char added as the separator between each of them. It may be necessary 
-     * to add quotes and escape chars to preserve the meaning. The resulting 
-     * string should produce an equivalent <code>CompositeName</code> when 
-     * used to create a new instance.
-     *
+     * Returns the string representation of this <code>CompositeName</code>.
+     * This is generated by concatenating the elements together with the '/'
+     * char added as the separator between each of them. It may be necessary to
+     * add quotes and escape chars to preserve the meaning. The resulting string
+     * should produce an equivalent <code>CompositeName</code> when used to
+     * create a new instance.
+     * 
      * @return the string representation of this composite name.
      */
     @Override
@@ -526,12 +546,14 @@
     }
 
     /**
-     * Check if this <code>CompositeName</code> is equal to the supplied object.
-     *
-     * @param o the <code>CompositeName</code> to compare - can be null but 
-     *          then returns false.
-     * @return  true if they have the same number of elements all of
-     *          which are equal. false if they are not equal.
+     * Check if this <code>CompositeName</code> is equal to the supplied
+     * object.
+     * 
+     * @param o
+     *            the <code>CompositeName</code> to compare - can be null but
+     *            then returns false.
+     * @return true if they have the same number of elements all of which are
+     *         equal. false if they are not equal.
      */
     @Override
     public boolean equals(Object o) {
@@ -568,7 +590,8 @@
      * String for each element.
      * 
      * @param oos
-     * @throws IOException if an error is encountered writing to the stream.
+     * @throws IOException
+     *             if an error is encountered writing to the stream.
      */
     private void writeObject(ObjectOutputStream oos) throws IOException {
         oos.defaultWriteObject();
@@ -583,11 +606,12 @@
      * Recreate a CompositeName from the data in the supplied stream.
      * 
      * @param ois
-     * @throws IOException if an error is encountered reading from the stream.
+     * @throws IOException
+     *             if an error is encountered reading from the stream.
      * @throws ClassNotFoundException.
      */
-    private void readObject(ObjectInputStream ois) throws OptionalDataException,
-            ClassNotFoundException, IOException {
+    private void readObject(ObjectInputStream ois)
+            throws OptionalDataException, ClassNotFoundException, IOException {
         ois.defaultReadObject();
 
         int size = ois.readInt();
@@ -596,4 +620,5 @@
             elems.add((String) ois.readObject());
         }
     }
+
 }



Mime
View raw message