Loading ...
Sorry, an error occurred while loading the content.

mustUnderstand once more

Expand Messages
  • piotr248
    hello, is there a possibility to deal with mustUnderstand attributes other than toggling the $SOAP::Constants::DO_NOT_CHECK_MUSTUNDERSTAND flag? (i read the
    Message 1 of 1 , Jul 17, 2006
    • 0 Attachment
      hello,

      is there a possibility to deal with mustUnderstand attributes other
      than toggling the $SOAP::Constants::DO_NOT_CHECK_MUSTUNDERSTAND flag?
      (i read the messages in this list that there were no other
      possibilities, but that referred to version 0.5 or so, i thought maybe
      something has changed in the meantime)
      currently i am doing it like so:

      --- snip ---
      foreach my $h ($req_hdr->value) {
      foreach my $name (keys %$h) {
      $headerData = $envelope->match(SOAP::SOM::header."/$name");
      $mustUnderstandHeaders{$name} = $headerData->valueof
      if($headerData->dataof->mustUnderstand);
      }
      }

      # handle headers and delete them from %mustUnderstandHeaders

      if(keys(%mustUnderstandHeaders)) {
      die SOAP::Fault
      ->faultcode($SOAP::Constants::FAULT_MUST_UNDERSTAND)
      ->faultstring("Unrecognized header has mustUnderstand
      attribute set to 'true'");
      } else {
      # proceed
      --- snap ---

      regards,
      hans
    Your message has been successfully submitted and would be delivered to recipients shortly.