betty.url package¶
Submodules¶
Module contents¶
Provide a URL generation API.
- class betty.url.LocalizedUrlGenerator[source]¶
Bases:
_UrlGeneratorGenerate URLs for localizable resources.
- class betty.url.StaticUrlGenerator[source]¶
Bases:
_UrlGeneratorGenerate URLs for static (non-localizable) resources.
- exception betty.url.UnsupportedResource[source]¶
Bases:
RuntimeErrorRaised when a URL generator cannot generate a URL for a resource.
These are preventable by checking
betty.url.LocalizedUrlGenerator.supports()orbetty.url.StaticUrlGenerator.supports()first.