|
Peano
|
Functions | |
| write_file (overwrite, overwrite_is_default, full_qualified_filename) | |
| overwrite is of type Overwrite and is what the user passes in overwrite_is_default is a boolean | |
| shortened_class_name (class_name, max_length=MAX_CLASS_NAME_LENGTH) | |
| Class name of a generated observer or action set which is short enough to serve as file name. | |
Variables | |
| str | WARNING_BANNER |
| int | MAX_CLASS_NAME_LENGTH = 200 |
| dict | _shortened_class_names = {} |
| peano4.api.output.Helper.shortened_class_name | ( | class_name, | |
max_length = MAX_CLASS_NAME_LENGTH |
|||
| ) |
Class name of a generated observer or action set which is short enough to serve as file name.
Names up to max_length characters are returned unchanged. Longer names are cut off and get a consecutive number appended, e.g. ..._1, ..._2. The cut-off names carry no meaning anymore, but every call with the same long name and the same max_length yields the same short name, so the generated files can refer to each other.
| class_name | str The full class name. |
| max_length | int Longest admissible class name. |
| peano4.api.output.Helper.write_file | ( | overwrite, | |
| overwrite_is_default, | |||
| full_qualified_filename | |||
| ) |
|
protected |
| str peano4.api.output.Helper.WARNING_BANNER |