ws-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From veit...@apache.org
Subject svn commit: r1728384 - /webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/common/builder/StAXOMBuilder.java
Date Wed, 03 Feb 2016 22:33:49 GMT
Author: veithen
Date: Wed Feb  3 22:33:49 2016
New Revision: 1728384

URL: http://svn.apache.org/viewvc?rev=1728384&view=rev
Log:
Code simplification.

Modified:
    webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/common/builder/StAXOMBuilder.java

Modified: webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/common/builder/StAXOMBuilder.java
URL: http://svn.apache.org/viewvc/webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/common/builder/StAXOMBuilder.java?rev=1728384&r1=1728383&r2=1728384&view=diff
==============================================================================
--- webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/common/builder/StAXOMBuilder.java
(original)
+++ webservices/axiom/trunk/aspects/om-aspects/src/main/java/org/apache/axiom/om/impl/common/builder/StAXOMBuilder.java
Wed Feb  3 22:33:49 2016
@@ -515,19 +515,6 @@ public class StAXOMBuilder implements Bu
         return old;
     }
     
-    /**
-     * Return CustomBuilder associated with the namespace/localPart
-     * @param namespace
-     * @param localPart
-     * @return CustomBuilder or null
-     */ 
-    protected final CustomBuilder getCustomBuilder(String namespace, String localPart) {
-        if (customBuilders == null) {
-            return null;
-        }
-        return customBuilders.get(namespace, localPart);
-    }
-
     private void createDocumentIfNecessary() {
         if (document == null && parser.getEventType() == XMLStreamReader.START_DOCUMENT)
{
             document = createDocument();
@@ -723,9 +710,7 @@ public class StAXOMBuilder implements Bu
             newElement = createWithCustomBuilder(customBuilderForPayload);
         }
         if (newElement == null && customBuilders != null && elementLevel
<= this.maxDepthForCustomBuilders) {
-            String namespace = parser.getNamespaceURI();
-            String localPart = parser.getLocalName();
-            CustomBuilder customBuilder = getCustomBuilder(namespace, localPart);
+            CustomBuilder customBuilder = customBuilders.get(parser.getNamespaceURI(), parser.getLocalName());
             if (customBuilder != null) {
                 newElement = createWithCustomBuilder(customBuilder);
             }



Mime
View raw message