Author: dkulp
Date: Thu Jul 11 16:20:49 2013
New Revision: 1502272

URL: http://svn.apache.org/r1502272
Log:
Remove a bunch of unreferreneced methods

Modified:
    
cxf/trunk/api/src/main/java/org/apache/cxf/common/xmlschema/XmlSchemaUtils.java

Modified: 
cxf/trunk/api/src/main/java/org/apache/cxf/common/xmlschema/XmlSchemaUtils.java
URL: 
http://svn.apache.org/viewvc/cxf/trunk/api/src/main/java/org/apache/cxf/common/xmlschema/XmlSchemaUtils.java?rev=1502272&r1=1502271&r2=1502272&view=diff
==============================================================================
--- 
cxf/trunk/api/src/main/java/org/apache/cxf/common/xmlschema/XmlSchemaUtils.java 
(original)
+++ 
cxf/trunk/api/src/main/java/org/apache/cxf/common/xmlschema/XmlSchemaUtils.java 
Thu Jul 11 16:20:49 2013
@@ -63,8 +63,7 @@ public final class XmlSchemaUtils {
     public static final String XSI_NIL = "xsi:nil='true'";
     public static final String XSI_NS_ATTR = WSDLConstants.NP_XMLNS + ":"
         + WSDLConstants.NP_SCHEMA_XSI + "='" + WSDLConstants.NS_SCHEMA_XSI + 
"'";
-    public static final String XSI_NIL_WITH_PREFIX = XSI_NS_ATTR + " 
xsi:nil='true'";
-
+    
     private static final Logger LOG = 
LogUtils.getL7dLogger(XmlSchemaUtils.class);
     private static final XmlSchemaSequence EMPTY_SEQUENCE = new 
XmlSchemaSequence();
     private static final XmlSchemaChoice EMPTY_CHOICE = new XmlSchemaChoice();
@@ -74,25 +73,6 @@ public final class XmlSchemaUtils {
     }
 
     /**
-     * Wrapper around XmlSchemaElement.setName that checks for inconsistency 
with
-     * refName.
-     * @param element
-     * @param name
-     */
-    public static void setElementName(XmlSchemaElement element, String name) {
-        if (name != null
-            && element.isRef()
-            && !element.getRef().getTargetQName().getLocalPart().equals(name)
-            && (element.getQName() == null || 
element.getQName().getLocalPart().equals(name))) {
-            LOG.severe("Attempt to set the name of an element with a reference 
name.");
-            throw new
-                XmlSchemaInvalidOperation("Attempt to set the name of an 
element "
-                                          + "with a reference name.");
-        }
-        element.setName(name);
-    }
-
-    /**
      * Wrapper around XmlSchemaElement.setRefName that checks for 
inconsistency with
      * name and QName.
      * @param element
@@ -461,21 +441,6 @@ public final class XmlSchemaUtils {
         return (XmlSchemaParticle) object;
     }
 
-    public static XmlSchemaElement getReferredElement(XmlSchemaElement element,
-                                                      SchemaCollection 
xmlSchemaCollection) {
-        if (element.isRef()) {
-            /*
-             * Calling getTarget works if everything is in the collection 
already.
-             */
-            XmlSchemaElement refElement = element.getRef().getTarget();
-            if (refElement == null) {
-                throw new RuntimeException("Dangling reference");
-            }
-            return refElement;
-        }
-        return null;
-    }
-
     public static XmlSchemaSequence getSequence(XmlSchemaComplexType type) {
         XmlSchemaParticle particle = type.getParticle();
         XmlSchemaSequence sequence = null;
@@ -582,10 +547,6 @@ public final class XmlSchemaUtils {
         }
     }
 
-    public static boolean isComplexType(XmlSchemaType type) {
-        return type instanceof XmlSchemaComplexType;
-    }
-
     public static boolean isElementNameQualified(XmlSchemaElement element, 
XmlSchema schema) {
         if (element.isRef()) {
             throw new RuntimeException("isElementNameQualified on element with 
ref=");


Reply via email to