systemc-clang 2.0.0
Parsing SystemC constructs
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
systemc_clang::PortDecl Class Reference

#include <PortDecl.h>

Inheritance diagram for systemc_clang::PortDecl:
Inheritance graph
[legend]
Collaboration diagram for systemc_clang::PortDecl:
Collaboration graph
[legend]

Public Member Functions

 PortDecl ()
 
 PortDecl (const std::string &, FindTemplateTypes *)
 
 PortDecl (const std::string &, const clang::Decl *, FindTemplateTypes *)
 
 PortDecl (const PortDecl &)
 
virtual ~PortDecl ()
 
void setModuleName (const std::string &)
 Set parameters.
 
void setBinding (clang::VarDecl *vd)
 
void setArrayType ()
 
void setPointertype ()
 
void addArraySize (llvm::APInt size)
 
bool getArrayType () const
 Get parameters.
 
bool isPointerType () const
 
std::vector< llvm::APInt > getArraySizes () const
 
std::string getName () const
 
clang::FieldDecl * getAsFieldDecl () const
 
clang::VarDecl * getAsVarDecl () const
 
FindTemplateTypesgetTemplateType ()
 
std::string asString () const
 Produce dump.
 

Private Attributes

std::string port_name_
 Name of the port.
 
FindTemplateTypestemplate_type_
 This holds the types for the port declaration.
 
clang::Decl * field_decl_
 
bool is_array_
 Is it an array type.
 
std::vector< llvm::APInt > array_sizes_
 

Detailed Description

This class holds the member declarations of a SystemC module class. These can be ports, signals or submodules (instances of other SystemC modules).

Definition at line 21 of file PortDecl.h.

Constructor & Destructor Documentation

◆ PortDecl() [1/4]

PortDecl::PortDecl ( )

Definition at line 22 of file PortDecl.cpp.

◆ PortDecl() [2/4]

PortDecl::PortDecl ( const std::string & name,
FindTemplateTypes * tt )

Definition at line 28 of file PortDecl.cpp.

◆ PortDecl() [3/4]

PortDecl::PortDecl ( const std::string & name,
const clang::Decl * fd,
FindTemplateTypes * tt )

Definition at line 34 of file PortDecl.cpp.

◆ PortDecl() [4/4]

PortDecl::PortDecl ( const PortDecl & from)

This is necessary to allow FindPorts to go out of scope.

Definition at line 41 of file PortDecl.cpp.

◆ ~PortDecl()

PortDecl::~PortDecl ( )
virtual

Definition at line 11 of file PortDecl.cpp.

Member Function Documentation

◆ addArraySize()

void PortDecl::addArraySize ( llvm::APInt size)

Definition at line 50 of file PortDecl.cpp.

◆ asString()

std::string PortDecl::asString ( ) const

Produce dump.

Definition at line 89 of file PortDecl.cpp.

◆ getArraySizes()

std::vector< llvm::APInt > PortDecl::getArraySizes ( ) const

Definition at line 73 of file PortDecl.cpp.

◆ getArrayType()

bool PortDecl::getArrayType ( ) const

Get parameters.

Definition at line 54 of file PortDecl.cpp.

◆ getAsFieldDecl()

clang::FieldDecl * PortDecl::getAsFieldDecl ( ) const

Definition at line 79 of file PortDecl.cpp.

◆ getAsVarDecl()

clang::VarDecl * PortDecl::getAsVarDecl ( ) const

Definition at line 83 of file PortDecl.cpp.

◆ getName()

std::string PortDecl::getName ( ) const

Definition at line 77 of file PortDecl.cpp.

◆ getTemplateType()

FindTemplateTypes * PortDecl::getTemplateType ( )

Definition at line 87 of file PortDecl.cpp.

◆ isPointerType()

bool PortDecl::isPointerType ( ) const

Definition at line 56 of file PortDecl.cpp.

◆ setArrayType()

void PortDecl::setArrayType ( )

Definition at line 52 of file PortDecl.cpp.

◆ setBinding()

void systemc_clang::PortDecl::setBinding ( clang::VarDecl * vd)

◆ setModuleName()

void PortDecl::setModuleName ( const std::string & name)

Set parameters.

Definition at line 71 of file PortDecl.cpp.

◆ setPointertype()

void systemc_clang::PortDecl::setPointertype ( )

Member Data Documentation

◆ array_sizes_

std::vector<llvm::APInt> systemc_clang::PortDecl::array_sizes_
private

Definition at line 61 of file PortDecl.h.

◆ field_decl_

clang::Decl* systemc_clang::PortDecl::field_decl_
private

This is the clang::Decl pointer to the FieldDecl found for the declaration.

Definition at line 57 of file PortDecl.h.

◆ is_array_

bool systemc_clang::PortDecl::is_array_
private

Is it an array type.

Definition at line 60 of file PortDecl.h.

◆ port_name_

std::string systemc_clang::PortDecl::port_name_
private

Name of the port.

Definition at line 52 of file PortDecl.h.

◆ template_type_

FindTemplateTypes* systemc_clang::PortDecl::template_type_
private

This holds the types for the port declaration.

Definition at line 54 of file PortDecl.h.


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