Issue Details (XML | Word | Printable)

Key: AXISCPP-356
Type: New Feature New Feature
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Roshan Weerasuriya
Reporter: Roshan Weerasuriya
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Axis-C++

Unable to specify the prefix when creating a HeaderBlock throguh Stubs

Created: 06/Jan/05 11:14 AM   Updated: 06/Jan/05 02:32 PM
Return to search
Component/s: Basic Architecture
Affects Version/s: current (nightly)
Fix Version/s: current (nightly)

Time Tracking:
Not Specified

Resolution Date: 06/Jan/05 02:28 PM


 Description  « Hide
IHeaderBlock *AXISCALL createSOAPHeaderBlock(AxisChar *pachLocalName,AxisChar *pachUri) API will create a namespace
declaration by taking prefix like 'ns1'or 'ns2'..

I feel it is better to get this prefix from the user itself.
ie it is better if the API is like IHeaderBlock *AXISCALL createSOAPHeaderBlock(AxisChar *pachLocalName, AxisChar *pachPrefix, AxisChar *pachUri)

Also the document for this API(stub.html) gives an example of this kind. ie creating a header block by giving three arguments but the API doesn't support three parameters. This needs to be looked into.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Repository Revision Date User Message
ASF #260240 Thu Jan 06 05:21:52 UTC 2005 roshan fixed JIRA issue AXISCPP-356
Files Changed
MODIFY /webservices/axis1/trunk/c/src/soap/HeaderBlock.h
MODIFY /webservices/axis1/trunk/c/include/axis/client/Call.hpp
MODIFY /webservices/axis1/trunk/c/src/engine/client/Call.cpp
MODIFY /webservices/axis1/trunk/c/include/axis/client/Stub.hpp
MODIFY /webservices/axis1/trunk/c/src/engine/client/Stub.cpp
MODIFY /webservices/axis1/trunk/c/src/soap/SoapSerializer.cpp
MODIFY /webservices/axis1/trunk/c/src/soap/SoapSerializer.h
MODIFY /webservices/axis1/trunk/c/src/soap/HeaderBlock.cpp

Roshan Weerasuriya made changes - 06/Jan/05 11:15 AM
Field Original Value New Value
Assignee Roshan Weerasuriya [ roshan ]
Roshan Weerasuriya added a comment - 06/Jan/05 02:28 PM
Added this functionality. Now the user can do this through the Stub. Also after adding the namespace (and the prefix prefered by the user), the child elements of the HeaderBlock can use this namespace. This is illustrated below:

IHeaderBlock *phb = ws.createSOAPHeaderBlock("TestHeader",
                "http://ws.apache.org/axisCppTest/", "myprefix");
                                                                                                                                                                            
    //create parent node
    BasicNode *parentNode = phb->createChild(ELEMENT_NODE);
    parentNode->setLocalName("Credentials");
        parentNode->setURI("http://ws.apache.org/axisCppTest/");
        .....
        ..........

The out come is below:

<SOAP-ENV:Header>
<myprefix:TestHeader xmlns:myprefix="http://ws.apache.org/axisCppTest/"><myprefix:Credentials>....</myprefix:Credentials></myprefix:TestHeader>

Roshan Weerasuriya made changes - 06/Jan/05 02:28 PM
Status Open [ 1 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]
Roshan Weerasuriya added a comment - 06/Jan/05 02:30 PM
The "ws" object in the above example code is a instance of the User stub.

Roshan Weerasuriya added a comment - 06/Jan/05 02:32 PM
Fixed this issue

Roshan Weerasuriya made changes - 06/Jan/05 02:32 PM
Status Resolved [ 5 ] Closed [ 6 ]