00001 /* 00002 * Copyright 2003-2004 The Apache Software Foundation. 00003 * 00004 * Licensed under the Apache License, Version 2.0 (the "License"); 00005 * you may not use this file except in compliance with the License. 00006 * You may obtain a copy of the License at 00007 * 00008 * http://www.apache.org/licenses/LICENSE-2.0 00009 * 00010 * Unless required by applicable law or agreed to in writing, software 00011 * distributed under the License is distributed on an "AS IS" BASIS, 00012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00013 * See the License for the specific language governing permissions and 00014 * limitations under the License. 00015 */ 00016 00017 00018 #if !defined(_IHANDLERSOAPDESERIALIZER_H____OF_AXIS_INCLUDED_) 00019 #define _IHANDLERSOAPDESERIALIZER_H____OF_AXIS_INCLUDED_ 00020 00021 #include "IWrapperSoapDeSerializer.h" 00022 #include "IHeaderBlock.h" 00023 #include "AxisUserAPI.h" 00024 /* 00025 * @class IHandlerSoapDeSerializer 00026 * @brief interface for the IHandlerSoapDeSerializer class. 00027 * 00028 * 00029 * @author Roshan Weerasuriya (roshan@opensource.lk, roshanw@jkcsworld.com) 00030 */ 00031 00032 /* 00033 * Revision 1.1 2004/06/14 roshan 00034 * Removed virtual int AXISCALL addHeaderBlock(IHeaderBlock* pBlk)=0; method 00035 * from this interface, because a user should not be able to add any thing 00036 * to the DeSerialzer. 00037 */ 00038 00039 #ifdef __cplusplus 00040 00041 AXIS_CPP_NAMESPACE_START 00042 00043 class IHandlerSoapDeSerializer : public IWrapperSoapDeSerializer 00044 { 00045 public: 00046 virtual ~IHandlerSoapDeSerializer() {}; 00047 00048 /* 00049 * The soap body may be encrypted/compressed and a 00050 * handler in the request message 00051 * path may decode and then decrypt and/or decompress 00052 * whole soap body and set the 00053 * XML to the Deserializer. In such a case a handler 00054 * will use following functions 00055 * to get soap body and set back the XML. 00056 * If this process goes throgh several 00057 * handlers the intermediate binary data 00058 * (unencrypted/uncompressed body) may be kept 00059 * in the IMessageData until it is converted to XML. 00060 * A handler usually converts it 00061 * to XML and use SetNewSoapBody(..) function to set 00062 * the new SoapBody back to the 00063 * Deserializer. 00064 */ 00065 virtual xsd__hexBinary AXISCALL getBodyAsHexBinary()=0; 00066 virtual xsd__base64Binary AXISCALL getBodyAsBase64Binary()=0; 00067 virtual int AXISCALL setNewSoapBody(AxisChar* pNewSoapBody)=0; 00068 00076 virtual IHeaderBlock* getHeaderBlock(const AxisChar* pName, 00077 const AxisChar* pNamespace) = 0; 00078 }; 00079 00080 AXIS_CPP_NAMESPACE_END 00081 00082 #else 00083 00084 typedef struct 00085 { 00086 void* unused; 00087 /* this corresponds to C++ virtual function 00088 * pointer which is ignored in C 00089 */ 00090 void* unused_; 00091 /* this corresponds to IWrapperSoapDeSerializerFunctions pointer */ 00092 IHandlerSoapDeSerializerFunctions* __vfptr; 00093 } IHandlerSoapDeSerializer; 00094 00095 #endif 00096 00097 #endif 00098 00099