Can't get it to work.
I tried using a castor-mapping.xml, injecting custom code into an abstract parent class for all generated classes.

"unable to find FieldDescriptor for 'XPath' in ClassDescriptor of TransformType" is the only thing I get.


<ds:Transforms>
<ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature";></ds:Transform> <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#";></ds:Transform>
<ds:Transform Algorithm="http://www.w3.org/2002/06/xmldsig-filter2";>
<dsig-xpath:XPath xmlns:dsig-xpath="http://www.w3.org/2002/06/xmldsig-filter2"; Filter="intersect">License/SignedLicenseInfo[1]</dsig-xpath:XPath>
</ds:Transform>
</ds:Transforms>


The "XPath" element is the problem, and I don't know how to tell Castor that there should be a getXPath/setXPath in the TransformType class.




Mike Haller schrieb:
Yes, this seems to be the problem.

Sorry for bothering, this seems to be the same as bug #1003 (Open, Blocker): "Unmarshalling of sequence of <any> fails"
http://jira.codehaus.org/browse/CASTOR-1003

I was using castor-0.9.6-xml.jar, and updated to 0.9.7M1, but to no avail. I am not using any mapping file. Is it possible to workaround using mappings?

kind regards
Mike


Andrew Fawcett schrieb:

So it looks like the Xpath element isn't being picked up by the Source
Generator tool yes?
-----Original Message-----
From: Mike Haller [mailto:[EMAIL PROTECTED] Sent: 31 May 2005 15:59
To: [email protected]
Subject: Re: [castor-user] Castor and XML-Security

So, here's my first problem :-)

<complexType name="TransformType" mixed="true"> <choice minOccurs="0"
maxOccurs="unbounded"> <any namespace="##other" processContents="lax"/>
<element name="XPath" type="string"/> </choice> <attribute
name="Algorithm" type="anyURI" use="required"/> </complexType>

the element "XPath" is not created as Java class, hence cannot be
Unmarshalled. The class TransformType has getter and setter for "String
getContent()" and "setContent(String)"

Is it possible to use some sort of mapping? How?

kind regards
Mike


Mike Haller schrieb:

Hi all,

i'm pretty new to Castor, currently writing my diploma thesis.

I have my own business model as XML Schema, and I use Apache Axis to transmit the objects between clients and server. The source code is generated by Castor, and all this works like a charm.

Now I wanted them (the business objects) to be digitally signed using XML-Security. But after being signed, they cannot be Unmarshalled by Castor anymore.

Is it the right way to import the XML-Security Schema into my own business schema, and thus creating lots of additional Java classes of the XML-Security package, or should I use another way?

My Plan is:
- Import xmldsig-core-schema.xsd into my-business.xsd
- Generate business-classes and xmldsig-classes

If anyone can push me in the right direction, i'll appreciate it :-)

kind regards
Mike



-------------------------------------------------
If you wish to unsubscribe from this list, please send an empty message to the following address:

[EMAIL PROTECTED]
-------------------------------------------------




-------------------------------------------------
If you wish to unsubscribe from this list, please send an empty message
to the following address:

[EMAIL PROTECTED]
-------------------------------------------------



The information in this message is confidential and may be legally privileged. It may not be disclosed to, or used by, anyone other than the addressee. If you receive this message in error, please advise us immediately. Internet emails are not necessarily secure. CODA does not accept responsibility for changes to any email which occur after the email has been sent. Attachments to this email may contain software viruses, which could damage your systems. CODA has checked the attachments for viruses before sending, but you should virus-check them before opening.

-------------------------------------------------
If you wish to unsubscribe from this list, please send an empty message to the following address:

[EMAIL PROTECTED]
-------------------------------------------------



-------------------------------------------------
If you wish to unsubscribe from this list, please send an empty message to the following address:

[EMAIL PROTECTED]
-------------------------------------------------



-------------------------------------------------
If you wish to unsubscribe from this list, please send an empty message to the following address:

[EMAIL PROTECTED]
-------------------------------------------------

Reply via email to