This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Regular expression for valid namespaces?

David O'Meara
Posts: 13459
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We have some code which parses incomming SOAP requests before deserialisation so that some data can be extracted in case the deserialisation process fails. The only problem is that the soap namespace is hardcoded so the code fails if the client uses a different value, as some of them do.

What we actually do is find the <soapns:Body ... > tag so we can look at he one directly after it, but rather than hardcode I was going to use the RE to match the desired entry and then find the index location, which utilises existing code.

Is this likely to work or cause issues if the message has its own Body element in another ns?

I agree. Here's the link:
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic