After reverting the trunk to use JAXB again on my local machine I was able to retrieve the full NamespaceContext for the tExpression elements. I had to attach the jaxb:dom binding to both the tExpression instances (priority, etc) and the TTask's any declaration. After unmarshalling the WS-HumanTask documentI am able to pull the DOM element from the any property and then I can use the apache commons XMLSchema's NodeNamespaceContext utility to rebuild the NamespaceContext just like how it is done currently.
I used the following example:
<htd:task name="Task1" xmlns:cla2="http://www.insurance.example.com/claims2" >
<htd:priority xmlns:cla3="http://www.insurance.example.com/claims3"> xs:integer(htd:getInput("ClaimApprovalRequest")/cla:prio*(cla2:t2+cla3:t3)) </htd:priority>
and I was able to pull back the prefix mappings for the three cla declarations so I am fairly confident this solution is adequate. Because the DOM content is being attached to the any property instead of the corresponding named property I will need to further enhance the binding customization to compensate for this.
Now that I have concluded that it is technically possible to revert back to JAXB I was wondering if there is any interest in doing so. The change would be quite extensive and due to the amount of work left I would like to get feedback from the project on whether it is worth pursuing before I commit to completing the task.