fgen.wrapping_strategies.information_injection#
Information injection functions
inject_wrapping_strategy_information#
- inject_wrapping_strategy_information(rendered_code, value, wrapping_strategy, comment_character, indent='')[source]#
Inject information about the strategy as a comment
- Parameters:
rendered_code (
str
) – Rendered code, into which to inject the informationvalue (
typing.Union
[fgen.data_models.multi_return.MultiReturn
,fgen.data_models.value.Value
]) – Value being wrappedwrapping_strategy (
fgen.wrapping_strategies.interface.WrappingStrategyLike
) – Wrapping strategy usedcomment_character (
str
) – Comment character for this textindent (
str
) – Indent to use when starting a new line
- Returns:
str
– Rendered code, with wrapping strategy information injected