axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brian Reinhold" <brianreinh...@lampreynetworks.com>
Subject RE: No headers in response
Date Tue, 02 Oct 2012 22:53:03 GMT
Okay,

I didn't mean to imply that the behavior was wrong, I just needed to know
what I needed to do. Since the namespace is in the standard I should be able
to hardcode one.

Brian

-----Original Message-----
From: Andreas Veithen [mailto:andreas.veithen@gmail.com] 
Sent: Tuesday, October 02, 2012 8:33 AM
To: java-dev@axis.apache.org
Subject: Re: No headers in response

On Tue, Oct 2, 2012 at 2:01 PM, Brian Reinhold
<brianreinhold@lampreynetworks.com> wrote:
> Martin,
>
>
>
> How do I get an attribute from an OMElement? This OMElement is one of 
> the addressing elements. When I try:
>
>
>
>                 QName qname = new QName("mustUnderstand");
>
>                 String mustUnderstand = 
> soapHeaderBlock.getAttributeValue(qname);
>
>                 if(mustUnderstand != null && 
> (mustUnderstand.contains("1")
> || mustUnderstand.contains("true")))
>
>                 {
>
>
> messageContext.setProperty(ADD_MUST_UNDERSTAND_TO_ADDRESSING_HEADERS,
> "true");
>
>                 }
>
>
>
> Just gives me null for the String 'mustUnderstand' from 
> soapHeaderBlock.getAttributeValue(qname). Yet debugging shows the 
> 'mustUnderstand' attribute as a local name. How can this be so 
> absurdly difficult?

The result is correct because the mustUnderstand attribute has a namespace,
but you are querying for an attribute with local name mustUnderstand and no
namespace.

Andreas

---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: java-dev-help@axis.apache.org



-----
No virus found in this message.
Checked by AVG - www.avg.com
Version: 2012.0.2221 / Virus Database: 2441/5305 - Release Date: 10/02/12


-----
No virus found in this message.
Checked by AVG - www.avg.com
Version: 2012.0.2221 / Virus Database: 2441/5305 - Release Date: 10/02/12


---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: java-dev-help@axis.apache.org


Mime
View raw message