src/share/jaxws_classes/com/sun/tools/internal/xjc/model/CPropertyInfo.java
Print this page
@@ -27,10 +27,11 @@
import java.lang.annotation.Annotation;
import java.util.Collection;
import java.util.Map;
+import javax.xml.XMLConstants;
import javax.xml.bind.annotation.XmlTransient;
import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import javax.xml.namespace.QName;
import com.sun.codemodel.internal.JClass;
@@ -296,11 +297,11 @@
protected static boolean needsExplicitTypeName(TypeUse type, QName typeName) {
if(typeName==null)
// this is anonymous type. can't have @XmlSchemaType
return false;
- if(!typeName.getNamespaceURI().equals(WellKnownNamespace.XML_SCHEMA))
+ if(!XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(typeName.getNamespaceURI()))
// if we put application-defined type name, it will be undefined
// by the time we generate a schema.
return false;
if(type.isCollection())