Classes
FormatterSpec
3
▼
Specification for lazy-loading a formatter.
FormatterSpec
3
▼
Specification for lazy-loading a formatter.
Attributes
| Name | Type | Description |
|---|---|---|
module |
str
|
Full module path (e.g., 'rosettes.formatters.html'). |
class_name |
str
|
Name of the formatter class in the module. |
aliases |
tuple[str, ...]
|
Alternative names for lookup. |
Functions
get_formatter
1
Formatter
▼
Get a formatter instance by name or alias.
get_formatter
1
Formatter
▼
def get_formatter(name: str) -> Formatter
Parameters
| Name | Type | Description |
|---|---|---|
name |
str |
Formatter name or alias (e.g., 'html', 'terminal'). |
Returns
Formatter
_get_formatter_by_canonical
1
Formatter
▼
Internal cached loader.
_get_formatter_by_canonical
1
Formatter
▼
def _get_formatter_by_canonical(canonical: str) -> Formatter
Parameters
| Name | Type | Description |
|---|---|---|
canonical |
str |
Returns
Formatter
list_formatters
0
list[str]
▼
List all supported formatter names.
list_formatters
0
list[str]
▼
def list_formatters() -> list[str]
Returns
list[str]
supports_formatter
1
bool
▼
Check if a formatter is supported.
supports_formatter
1
bool
▼
def supports_formatter(name: str) -> bool
Parameters
| Name | Type | Description |
|---|---|---|
name |
str |
Returns
bool