PhoenixGenerator  2.0.0
Set of tools to generate code
class_attribute_utils.h File Reference
#include "PClassAttribute.h"
+ Include dependency graph for class_attribute_utils.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

PClassAttribute createClassAttribute (const PString &type, const PString &name, const PString &documentation="")
 Creates a PClassAttribute. More...
 
PClassAttribute createClassAttribute (const PString &typeName, const PString &name, bool isPointer, bool isReference, const PString &documentation)
 Create an attribute. More...
 

Function Documentation

◆ createClassAttribute() [1/2]

PClassAttribute createClassAttribute ( const PString type,
const PString name,
const PString documentation 
)

Creates a PClassAttribute.

Parameters
type: type of the attribute
name: name of the attribute
documentation: documentation of the attribute

Definition at line 15 of file class_attribute_utils.cpp.

15  {
16  PClassAttribute attr;
17  attr.setType(type);
18  attr.setName(name);
19  attr.setDocumentation(documentation);
20  return attr;
21 }
Describes a class attribute.
void setType(const PString &type)
Sets the type of the PClassAttribute.
void setDocumentation(const PString &documentation)
Sets the documentation of the PClassAttribute.
void setName(const PString &name)
Sets the name of the PClassAttribute.

References PClassAttribute::setDocumentation(), PClassAttribute::setName(), and PClassAttribute::setType().

Referenced by parseClassConfigAttribut(), and parseEnumValue().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ createClassAttribute() [2/2]

PClassAttribute createClassAttribute ( const PString typeName,
const PString name,
bool  isPointer,
bool  isReference,
const PString documentation 
)

Create an attribute.

Parameters
typeName: type of the attribute
name: name of the attribute
isPointer: true if the attribute is a pointer
isReference: true if the attribute is a reference
documentation: documentation of the attribute
Returns
PClassAttribute

Definition at line 31 of file class_attribute_utils.cpp.

31  {
32  PClassAttribute attr;
33  attr.setType(typeName);
34  attr.setName(name);
35  attr.setIsPointer(isPointer);
36  attr.setIsReference(isReference);
37  attr.setDocumentation(documentation);
38 
39  return attr;
40 }
void setIsPointer(bool isPointer)
Sets the isPointer of the PClassAttribute.
void setIsReference(bool isReference)
Sets the isReference of the PClassAttribute.

References PClassAttribute::setDocumentation(), PClassAttribute::setIsPointer(), PClassAttribute::setIsReference(), PClassAttribute::setName(), and PClassAttribute::setType().

+ Here is the call graph for this function: