CPP-TOOLBOX
Loading...
Searching...
No Matches
cpp_utils.main.CppClass Class Reference

Public Member Functions

 __init__ (self, str name)
 
None add_include (self, str include)
 
 add_member (self, CppMember member)
 
 add_method (self, CppMethod method)
 
 add_constructor (self, List[CppParameter] parameters, str initializer_list="", str body="")
 
 generate_header_content (self)
 
 generate_source_content (self)
 
 __str__ (self)
 

Public Attributes

 name = name
 
list members = []
 
list methods = []
 
list includes = []
 

Detailed Description

Represents a C++ class.

Constructor & Destructor Documentation

◆ __init__()

cpp_utils.main.CppClass.__init__ ( self,
str name )

Member Function Documentation

◆ __str__()

cpp_utils.main.CppClass.__str__ ( self)
Return the string representation of the class.

◆ add_constructor()

cpp_utils.main.CppClass.add_constructor ( self,
List[CppParameter] parameters,
str initializer_list = "",
str body = "" )
Add a constructor to the class with an optional initializer list.

◆ add_include()

None cpp_utils.main.CppClass.add_include ( self,
str include )

◆ add_member()

cpp_utils.main.CppClass.add_member ( self,
CppMember member )
Add a member to the class.

◆ add_method()

cpp_utils.main.CppClass.add_method ( self,
CppMethod method )
Add a method to the class.

◆ generate_header_content()

cpp_utils.main.CppClass.generate_header_content ( self)
Generate the header file content.

◆ generate_source_content()

cpp_utils.main.CppClass.generate_source_content ( self)
Generate the source file content.

Member Data Documentation

◆ includes

list cpp_utils.main.CppClass.includes = []

◆ members

cpp_utils.main.CppClass.members = []

◆ methods

cpp_utils.main.CppClass.methods = []

◆ name

cpp_utils.main.CppClass.name = name

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