williamr@2: /* williamr@2: * Copyright (c) 2002-2005 Nokia Corporation and/or its subsidiary(-ies). williamr@2: * All rights reserved. williamr@2: * This component and the accompanying materials are made available williamr@4: * under the terms of "Eclipse Public License v1.0" williamr@2: * which accompanies this distribution, and is available williamr@4: * at the URL "http://www.eclipse.org/legal/epl-v10.html". williamr@2: * williamr@2: * Initial Contributors: williamr@2: * Nokia Corporation - initial contribution. williamr@2: * williamr@2: * Contributors: williamr@2: * williamr@2: * Description: This utility class represents SOAP fault element according to williamr@2: * SOAP fault specification. williamr@2: * williamr@2: */ williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: #ifndef SEN_SOAP_FAULT_H williamr@2: #define SEN_SOAP_FAULT_H williamr@2: williamr@2: // INCLUDES williamr@2: #include williamr@2: #include williamr@2: williamr@2: // CLASS DECLARATION williamr@2: williamr@2: /** williamr@2: * This utility class represents SOAP fault element according to SOAP fault williamr@2: * specification. williamr@2: * SOAP fault element has following child elements: williamr@2: * faultcode, williamr@2: * faultstring, williamr@2: * faultactor williamr@2: * detail williamr@2: * williamr@2: * @lib SenUtils.lib williamr@2: * @since Series60 3.0 williamr@2: */ williamr@2: class CSenSoapFault2 : public CSenDomFragmentBase williamr@2: { williamr@2: public: // Constructors and destructor williamr@2: williamr@2: /** williamr@2: * Copy constructor, making a copy of the original source element. williamr@2: * @since Series60 3.0 williamr@2: * @param aElement Element which is copied into SoapFault. williamr@2: */ williamr@2: IMPORT_C static CSenSoapFault2* NewL(TXmlEngElement& aElement); williamr@2: williamr@2: /** williamr@2: * Constructor which, takes williamr@2: * 1) TXmlEngElement which is already owned by other Fragment and williamr@2: * 2) RSenDocument which is owned by that same other Fragment. williamr@2: * Constructor takes a copy of RSenDocument => given element williamr@2: * will be destructed when both original Fragment and williamr@2: * CSenSoapFault2 have been destructed. Given element will williamr@2: * be root element of CSenSoapFault2. williamr@2: * williamr@2: * @since Series60 3.0 williamr@2: * @param aElement Soap Fault element. williamr@2: * @param aDocument Original document holding given Soap Fault williamr@2: * element. williamr@2: */ williamr@2: IMPORT_C static CSenSoapFault2* NewL(TXmlEngElement& aElement, williamr@2: RSenDocument& aDocument); williamr@2: williamr@2: /** williamr@2: * Basic constructor. williamr@2: * @since Series60 3.0 williamr@2: * @param aNsUri is the XML namespace of this SOAP fault williamr@2: * @param aLocalName is the localname for this SOAP fault williamr@2: * @param aQName is the qualifiedname for this SOAP fault williamr@2: * @param aAttributes are the XML attributes for this SOAP fault williamr@2: * Parameters are used to construct the soap fault. williamr@2: */ williamr@2: IMPORT_C static CSenSoapFault2* NewL(const TDesC8& aNsUri, williamr@2: const TDesC8& aLocalName, williamr@2: const TDesC8& aPrefix, williamr@2: const RAttributeArray& aAttributes, williamr@2: TXmlEngElement& aElement, williamr@2: RSenDocument& aDocument); williamr@2: williamr@2: /** williamr@2: * Destructor. williamr@2: */ williamr@2: IMPORT_C virtual ~CSenSoapFault2(); williamr@2: williamr@2: // New functions williamr@2: williamr@2: /** williamr@2: * @since Series60 3.0 williamr@2: * @return the content of element as UTF-8 form string williamr@2: * or KNullDesC8, if element is not available williamr@2: */ williamr@2: IMPORT_C TPtrC8 FaultCode(); williamr@2: williamr@2: /** williamr@2: * @since Series60 4.0 williamr@2: * @return the content of element as UTF-8 form string williamr@2: * or KNullDesC8, if element is not available williamr@2: */ williamr@2: IMPORT_C TPtrC8 FaultSubcode(); williamr@2: williamr@2: /** williamr@2: * @since Series60 3.0 williamr@2: * @return the content of element as UTF-8 form string williamr@2: * or KNullDesC8, if element is not available williamr@2: */ williamr@2: IMPORT_C TPtrC8 FaultString(); williamr@2: williamr@2: /** williamr@2: * @since Series60 3.0 williamr@2: * @return the content of element as UTF-8 form string williamr@2: * or KNullDesC8, if element is not available williamr@2: */ williamr@2: IMPORT_C TPtrC8 FaultActor(); williamr@2: williamr@2: /** williamr@2: * @since Series60 3.0 williamr@2: * @return the content of element as UTF-8 form string williamr@2: * or KNullDesC8, if element is not available williamr@2: */ williamr@2: IMPORT_C TPtrC8 Detail(); williamr@2: williamr@2: protected: williamr@2: williamr@2: /** williamr@2: * C++ default constructor williamr@2: */ williamr@2: IMPORT_C CSenSoapFault2(); williamr@2: williamr@2: /** williamr@2: * Basic ConstructL function williamr@2: * @since Series60 3.0 williamr@2: * @param aElement is the TXmlEngElement from which data to this williamr@2: * SOAP fault object is to be copied. williamr@2: */ williamr@2: IMPORT_C void ConstructL(TXmlEngElement& aElement); williamr@2: williamr@2: /** williamr@2: * ConstructL method which takes williamr@2: * 1) TXmlEngElement which is already owned by other Fragment and williamr@2: * 2) RSenDocument which is owned by that same other Fragment. williamr@2: * Constructor takes a copy of RSenDocument => given element williamr@2: * will be destructed when both original Fragment and williamr@2: * CSenSoapFault2 have been destructed. Given element will williamr@2: * be root element of CSenSoapFault2. williamr@2: * williamr@2: * @since Series60 3.0 williamr@2: * @param aElement Soap Fault element. williamr@2: * @param aDocument Original document holding given Soap Fault williamr@2: * element. williamr@2: */ williamr@2: IMPORT_C void ConstructL(TXmlEngElement& aElement, RSenDocument& aDocument); williamr@2: williamr@2: /** williamr@2: * Basic ConstructL function williamr@2: * @since Series60 3.0 williamr@2: * @param aNsUri is the XML namespace URI of this SOAP fault williamr@2: * @param aLocalName is the XML localname URI of this SOAP fault williamr@2: * @param aQName is the XML qualifiedname URI of this SOAP fault williamr@2: * @param aAttributes are the XML attributes for this SOAP fault williamr@2: */ williamr@2: IMPORT_C void ConstructL(const TDesC8& aNsUri, williamr@2: const TDesC8& aLocalName, williamr@2: const TDesC8& aPrefix, williamr@2: const RAttributeArray& aAttributes, williamr@2: TXmlEngElement& aElement, williamr@2: RSenDocument& aDocument); williamr@2: }; williamr@2: williamr@2: #endif // SEN_SOAP_ENVELOPE_H williamr@2: williamr@2: // End of File