Package pyplusplus :: Package code_creators :: Module license :: Class license_t

type license_t

source code

                 object --+    
                          |    
code_creator.code_creator_t --+
                              |
                             license_t

This class allows user to put his license on the top of every generated file. License text will be generated as is.

Instance Methods
 
__init__(self, text)
Constructor.
source code
str
beautify(self, code)
function that returns code without leading and trailing whitespaces.
source code

Inherited from code_creator.code_creator_t: create, get_system_headers

Static Methods

Inherited from code_creator.code_creator_t: indent, is_comment, unindent, unique_headers

Class Variables

Inherited from code_creator.code_creator_t: LINE_LENGTH, PARAM_SEPARATOR, PYPLUSPLUS_NS_NAME

Properties
  text

Inherited from code_creator.code_creator_t: parent, target_configuration, top_parent, works_on_instance

Method Details

__init__(self, text)
(Constructor)

source code 

Constructor.

Parameters:
  • parent - Parent code creator.
Overrides: code_creator.code_creator_t.__init__
(inherited documentation)

beautify(self, code)

source code 

function that returns code without leading and trailing whitespaces.

Parameters:
  • code - A code block with C++ source code.
Returns: str
Overrides: code_creator.code_creator_t.beautify
(inherited documentation)

Property Details

text

Get Method:
_get_text(self)
Set Method:
_set_text(self, new_text)