libTriton  version 0.9 build 1502
astRepresentation.hpp
Go to the documentation of this file.
1 /*
3 ** Copyright (C) - Triton
4 **
5 ** This program is under the terms of the Apache License 2.0.
6 */
7 
8 #ifndef TRITON_ASTREPRESENTATION_H
9 #define TRITON_ASTREPRESENTATION_H
10 
11 #include <iostream>
12 #include <memory>
13 
14 #include <triton/ast.hpp>
15 #include <triton/astEnums.hpp>
19 #include <triton/dllexport.hpp>
20 
21 
22 
24 namespace triton {
31  namespace ast {
39  namespace representations {
48  protected:
51 
53  std::unique_ptr<triton::ast::representations::AstRepresentationInterface> representations[triton::ast::representations::LAST_REPRESENTATION];
54 
55  public:
57  TRITON_EXPORT AstRepresentation();
58 
60  TRITON_EXPORT AstRepresentation(const AstRepresentation& other);
61 
63  TRITON_EXPORT AstRepresentation& operator=(const AstRepresentation& other);
64 
66  TRITON_EXPORT triton::uint32 getMode(void) const;
67 
69  TRITON_EXPORT void setMode(triton::uint32 mode);
70 
72  TRITON_EXPORT std::ostream& print(std::ostream& stream, AbstractNode* node);
73  };
74 
76  };
78  };
80 };
81 
82 #endif /* TRITON_ASTREPRESENTATION_H */
Abstract node.
Definition: ast.hpp:66
TRITON_EXPORT std::ostream & print(std::ostream &stream, AbstractNode *node)
Displays the node according to the representation mode.
TRITON_EXPORT AstRepresentation & operator=(const AstRepresentation &other)
Operator.
triton::uint32 mode
The representation mode.
std::unique_ptr< triton::ast::representations::AstRepresentationInterface > representations[triton::ast::representations::LAST_REPRESENTATION]
AstRepresentation interface.
TRITON_EXPORT void setMode(triton::uint32 mode)
Sets the representation mode.
TRITON_EXPORT triton::uint32 getMode(void) const
Returns the representation mode.
std::uint32_t uint32
unisgned 32-bits
Definition: tritonTypes.hpp:31
The Triton namespace.
Definition: api.cpp:227