DOMDocument.h
Go to the documentation of this file.
1 /* -*- C++ -*- */
2 
3 /****************************************************************************
4 ** Copyright (c) 2001-2014
5 **
6 ** This file is part of the QuickFIX FIX Engine
7 **
8 ** This file may be distributed under the terms of the quickfixengine.org
9 ** license as defined by quickfixengine.org and appearing in the file
10 ** LICENSE included in the packaging of this file.
11 **
12 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
13 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
14 **
15 ** See http://www.quickfixengine.org/LICENSE for licensing information.
16 **
17 ** Contact ask@quickfixengine.org if any conditions of this licensing are
18 ** not clear to you.
19 **
20 ****************************************************************************/
21 
22 #ifndef FIX_DOMDOCUMENT_H
23 #define FIX_DOMDOCUMENT_H
24 
25 #include <string>
26 #include <map>
27 #include <iostream>
28 #include <memory>
29 #include "Utility.h"
30 
31 namespace FIX
32 {
33  #include "Utility.h"
36  {
37  public:
38  typedef std::map<std::string, std::string> map;
39 
40  virtual ~DOMAttributes() {}
41 
42  virtual bool get( const std::string&, std::string& ) = 0;
43  virtual map toMap() = 0;
44  };
45  typedef SmartPtr<DOMAttributes> DOMAttributesPtr;
46 
48  class DOMNode
49  {
50  public:
51  virtual ~DOMNode() {}
52 
53  virtual SmartPtr<DOMNode> getFirstChildNode() = 0;
54  virtual SmartPtr<DOMNode> getNextSiblingNode() = 0;
55  virtual SmartPtr<DOMAttributes> getAttributes() = 0;
56  virtual std::string getName() = 0;
57  virtual std::string getText() = 0;
58  };
59  typedef SmartPtr<DOMNode> DOMNodePtr;
60 
63  {
64  public:
65  virtual ~DOMDocument() {}
66 
67  virtual bool load( std::istream& ) = 0;
68  virtual bool load( const std::string& ) = 0;
69  virtual bool xml( std::ostream& ) = 0;
70 
71  virtual SmartPtr<DOMNode> getNode( const std::string& ) = 0;
72  };
73  typedef SmartPtr<DOMDocument> DOMDocumentPtr;
74 }
75 
76 #endif
FIX::DOMAttributes::map
std::map< std::string, std::string > map
Definition: DOMDocument.h:55
FIX::DOMDocument::load
virtual bool load(std::istream &)=0
FIX::DOMAttributesPtr
SmartPtr< DOMAttributes > DOMAttributesPtr
Definition: DOMDocument.h:45
FIX::DOMNode::getName
virtual std::string getName()=0
FIX::DOMNode::getNextSiblingNode
virtual SmartPtr< DOMNode > getNextSiblingNode()=0
FIX::DOMNode::getText
virtual std::string getText()=0
FIX::DOMNode::~DOMNode
virtual ~DOMNode()
Definition: DOMDocument.h:51
FIX::DOMNodePtr
SmartPtr< DOMNode > DOMNodePtr
Definition: DOMDocument.h:59
FIX::DOMNode::getAttributes
virtual SmartPtr< DOMAttributes > getAttributes()=0
FIX::DOMDocument
Interface that represents document of underlying XML parser.
Definition: DOMDocument.h:62
FIX::DOMNode::getFirstChildNode
virtual SmartPtr< DOMNode > getFirstChildNode()=0
FIX::DOMDocument::~DOMDocument
virtual ~DOMDocument()
Definition: DOMDocument.h:65
FIX::DOMDocumentPtr
SmartPtr< DOMDocument > DOMDocumentPtr
Definition: DOMDocument.h:73
FIX::DOMAttributes
Interface that represents attribute from underlying XML parser.
Definition: DOMDocument.h:35
FIX
Definition: Acceptor.cpp:34
FIX::DOMNode
Interface that represents node from underlying XML parser.
Definition: DOMDocument.h:48
FIX::DOMAttributes::toMap
virtual map toMap()=0
FIX::DOMDocument::getNode
virtual SmartPtr< DOMNode > getNode(const std::string &)=0
Utility.h
FIX::DOMAttributes::~DOMAttributes
virtual ~DOMAttributes()
Definition: DOMDocument.h:57
FIX::DOMAttributes::get
virtual bool get(const std::string &, std::string &)=0
FIX::DOMDocument::xml
virtual bool xml(std::ostream &)=0

Generated on Wed Apr 29 2020 19:41:30 for QuickFIX by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2001