This content has been marked as final.
Show 6 replies
-
1. Re: about JBMETA 198/199
aloubyansky May 18, 2009 6:32 AM (in response to jeff.zhang)1. extend the JCA15MetaData and JBossRAMetaData classes and create 2 wrap classes. in which I define the namespace in the class by using annotation @JBossXmlSchema, is it correct?
Yes.
For the binding, your intent is to bind to an XML w/o schema information. So, you just need to specify the root element name in the key. -
2. Re: about JBMETA 198/199
jeff.zhang Jun 1, 2009 9:23 AM (in response to jeff.zhang)I still meet parser issue for default namespace, the JCA15DefaultNSMetadata class has annotation like this.
@XmlRootElement(name="connector", namespace=JavaEEMetaDataConstants.JAVAEE_NS) @JBossXmlSchema( xmlns={@XmlNs(namespaceURI = JavaEEMetaDataConstants.JAVAEE_NS}, ignoreUnresolvedFieldOrClass=true, namespace=JavaEEMetaDataConstants.JAVAEE_NS, elementFormDefault=XmlNsForm.QUALIFIED, normalizeSpace=true, strict=false)
I don't know where I can add xsd definition in the JBossXmlSchema annotation.
Thanks. -
3. Re: about JBMETA 198/199
aloubyansky Jun 1, 2009 11:47 AM (in response to jeff.zhang)The namespace should be "" or not used at all.
-
4. Re: about JBMETA 198/199
jeff.zhang Jun 3, 2009 5:54 AM (in response to jeff.zhang)I still meet problem about default namespace parser. The test can't pass when it parser xml file like
<connector> <vendor-name>Red Hat Middleware LLC</vendor-name> <eis-type>JMS 1.1 Server</eis-type> <resourceadapter-version>6.0</resourceadapter-version> <resourceadapter> </resourceadapter> </connector>
I had commit some minimal codes about this test (r89720), currently I ignore the test ignoretestDefaultNS in RA16EverythingUnitTestCase
could you help me to check what is wrong and give me some point about this?
Thanks a lot -
5. Re: about JBMETA 198/199
aloubyansky Jun 3, 2009 8:34 AM (in response to jeff.zhang)So, what's not clear about the error?
The error is "Failed to resolve schema nsURI= location=connector".
Which comes from resolver.
Which means "connector" has not been mapped to any class.+ public static SchemaBindingResolver initResolver() + { + MutableSchemaResolver resolver = MetaDataSchemaResolverFactory.createSchemaResolver(); + resolver.mapLocationToClass("connector", JCA16DefaultNSMetaData.class); + return resolver; + }
-
6. Re: about JBMETA 198/199
jeff.zhang Jun 4, 2009 12:15 AM (in response to jeff.zhang)OK, got it. Thanks for youe help :)