retdec
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
retdec::demangler::borland::PointerTypeNode Class Reference

Representation of pointers. More...

#include <pointer_type.h>

Inheritance diagram for retdec::demangler::borland::PointerTypeNode:
Inheritance graph
[legend]
Collaboration diagram for retdec::demangler::borland::PointerTypeNode:
Collaboration graph
[legend]

Public Member Functions

std::shared_ptr< Nodepointee ()
 
void printLeft (std::ostream &s) const override
 Prints left side of pointer type or whole, depending on pointee. Right side printing is used for arrays and pointers to function types. More...
 
void printRight (std::ostream &s) const override
 Prints right side of pointer type. Used for array and funtion types. More...
 
- Public Member Functions inherited from retdec::demangler::borland::TypeNode
Qualifiers quals ()
 
- Public Member Functions inherited from retdec::demangler::borland::Node
 Node (Kind kind, bool has_right_side=false)
 Abstract constructor for base node. More...
 
virtual ~Node ()=default
 
void print (std::ostream &s) const
 Prints left side of node. More...
 
std::string str () const
 
Kind kind () const
 
bool hasRight ()
 

Static Public Member Functions

static std::shared_ptr< PointerTypeNodecreate (Context &context, const std::shared_ptr< Node > &pointee, const Qualifiers &quals)
 Function for creating pointers. If type the same type was already created, then that instance is returned. More...
 

Private Member Functions

 PointerTypeNode (const std::shared_ptr< Node > &pointee, const Qualifiers &quals)
 

Private Attributes

std::shared_ptr< Node_pointee
 

Additional Inherited Members

- Public Types inherited from retdec::demangler::borland::Node
enum class  Kind {
  KFunction , KFunctionType , KName , KNestedName ,
  KNodeArray , KNodeString , KTypeNode , KBuiltInType ,
  KPointerType , KIntegralType , KCharType , KFloatType ,
  KParentheses , KReferenceType , KRReferenceType , KNamedType ,
  KTemplateNode , KArrayNode , KConversionOperator
}
 
- Protected Member Functions inherited from retdec::demangler::borland::TypeNode
 TypeNode (const Qualifiers &quals)
 
- Protected Attributes inherited from retdec::demangler::borland::TypeNode
Qualifiers _quals
 
- Protected Attributes inherited from retdec::demangler::borland::Node
Kind _kind
 
bool _has_right
 

Detailed Description

Representation of pointers.

Constructor & Destructor Documentation

◆ PointerTypeNode()

retdec::demangler::borland::PointerTypeNode::PointerTypeNode ( const std::shared_ptr< Node > &  pointee,
const Qualifiers quals 
)
private

Private constructor for pointers. Use create().

Member Function Documentation

◆ create()

std::shared_ptr< PointerTypeNode > retdec::demangler::borland::PointerTypeNode::create ( Context context,
const std::shared_ptr< Node > &  pointee,
const Qualifiers quals 
)
static

Function for creating pointers. If type the same type was already created, then that instance is returned.

Parameters
contextStorage for types.
pointeePointed type.
qualsSee BuiltInTypeNode quals.
Returns
Node representing pointer type.

◆ pointee()

std::shared_ptr< Node > retdec::demangler::borland::PointerTypeNode::pointee ( )
Returns
Pointed type.

◆ printLeft()

void retdec::demangler::borland::PointerTypeNode::printLeft ( std::ostream &  s) const
overridevirtual

Prints left side of pointer type or whole, depending on pointee. Right side printing is used for arrays and pointers to function types.

Implements retdec::demangler::borland::Node.

◆ printRight()

void retdec::demangler::borland::PointerTypeNode::printRight ( std::ostream &  s) const
overridevirtual

Prints right side of pointer type. Used for array and funtion types.

Reimplemented from retdec::demangler::borland::Node.

Member Data Documentation

◆ _pointee

std::shared_ptr<Node> retdec::demangler::borland::PointerTypeNode::_pointee
private

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