Mixe for Privacy and Anonymity in the Internet
Public Member Functions | Protected Attributes | List of all members
CAAbstractXMLSignable Class Reference

An abstract base class for signable XML structures. More...

#include <CAAbstractXMLSignable.hpp>

Inheritance diagram for CAAbstractXMLSignable:
Collaboration diagram for CAAbstractXMLSignable:

Public Member Functions

 CAAbstractXMLSignable ()
 
virtual ~CAAbstractXMLSignable ()
 
SINT32 sign (CASignature &)
 TODO: implement. More...
 
SINT32 setSignature (DOMElement *elemSig)
 Verifies the signature. More...
 
SINT32 isSigned ()
 returns nonzero, if this structure is already signed More...
 
- Public Member Functions inherited from CAAbstractXMLEncodable
 CAAbstractXMLEncodable ()
 
virtual ~CAAbstractXMLEncodable ()
 pure virtual destructor. More...
 
virtual SINT32 toXmlElement (XERCES_CPP_NAMESPACE::DOMDocument *a_pDoc, DOMElement *&pElemRoot)=0
 Creates the XML structure inside an existing DOM_Document, but does not append it to any node. More...
 
SINT32 toXmlDocument (XERCES_CPP_NAMESPACE::DOMDocument *&pDoc)
 returns a pointer to the tagname of this XML structure's top level element. More...
 
UINT8toXmlString (UINT32 *pSize)
 Converts the XML structure to a null-terminated C-String representation. More...
 

Protected Attributes

XERCES_CPP_NAMESPACE::DOMDocument * m_pSignature
 

Detailed Description

An abstract base class for signable XML structures.

Author
Bastian Voigt

Definition at line 17 of file CAAbstractXMLSignable.hpp.

Constructor & Destructor Documentation

◆ CAAbstractXMLSignable()

CAAbstractXMLSignable::CAAbstractXMLSignable ( )
inline

Definition at line 20 of file CAAbstractXMLSignable.hpp.

21  {
22  m_pSignature = NULL;
23  }
XERCES_CPP_NAMESPACE::DOMDocument * m_pSignature

References m_pSignature.

◆ ~CAAbstractXMLSignable()

virtual CAAbstractXMLSignable::~CAAbstractXMLSignable ( )
inlinevirtual

Definition at line 25 of file CAAbstractXMLSignable.hpp.

26  {
27  if(m_pSignature!=NULL)
28  {
29  m_pSignature->release();
30  m_pSignature = NULL;
31  }
32  }

References m_pSignature.

Member Function Documentation

◆ isSigned()

SINT32 CAAbstractXMLSignable::isSigned ( )
inline

returns nonzero, if this structure is already signed

Definition at line 70 of file CAAbstractXMLSignable.hpp.

71  {
72  if(m_pSignature!=NULL)
73  {
74  return true;
75  }
76  else
77  {
78  return false;
79  }
80  }

References m_pSignature.

◆ setSignature()

SINT32 CAAbstractXMLSignable::setSignature ( DOMElement *  elemSig)
inline

Verifies the signature.

Returns E_SUCCESS if the signature is valid. sets the internal signature representation. Should be called from derived class constructors.

Definition at line 61 of file CAAbstractXMLSignable.hpp.

62  {
63  ASSERT(elemSig!=NULL, "Signature element is NULL")
65  m_pSignature->appendChild(m_pSignature->importNode(elemSig, true));
66  return E_SUCCESS;
67  }
XERCES_CPP_NAMESPACE::DOMDocument * createDOMDocument()
Parses a timestamp in JDBC timestamp escape format (as it comes from the BI) and outputs the value in...
Definition: CAUtil.cpp:1568
#define ASSERT(cond, msg)
Definition: StdAfx.h:546
const SINT32 E_SUCCESS
Definition: errorcodes.hpp:2

References ASSERT, createDOMDocument(), E_SUCCESS, and m_pSignature.

Here is the call graph for this function:

◆ sign()

SINT32 CAAbstractXMLSignable::sign ( CASignature )
inline

TODO: implement.

Definition at line 35 of file CAAbstractXMLSignable.hpp.

36  {
37  return E_UNKNOWN;
38  }
#define E_UNKNOWN
Definition: errorcodes.hpp:3

References E_UNKNOWN.

Member Data Documentation

◆ m_pSignature

XERCES_CPP_NAMESPACE::DOMDocument* CAAbstractXMLSignable::m_pSignature
protected

The documentation for this class was generated from the following file: