PyContentFilterBuilder
class PyContentFilterBuilder(content_filters_builder)
Bases: object
Default IContentFilterBuilder implementation.
- Parameters: content_filters_builder (IContentFilterBuilder)
__init__(content_filters_builder)
Default init.
Args: : content_filters_builder: Interface for a builder of filters that use a common content type
Returns: None.
- Parameters: content_filters_builder (IContentFilterBuilder)
- Return type: None
Methods
__init__ (content_filters_builder) |
Default init. |
---|---|
add (input_0[, input_1]) |
Adds an object or function to execute filters. |
build () |
Builds an immutable collection from the currently added filters. |
by_content_type () |
Gets the currently registered hook factories by their content types. |
clear () |
Removes all currently registered filters. |
add(input_0, input_1=None)
Adds an object or function to execute filters.
Args:
: input_0: Either:
: 1. The filter type to execute, or
2. The content type for a callback function
input_1: Either:
: 1. The callback function to execute, or
2. None
Returns: : The same mapping builder object for fluent API calls.
- Parameters:
- input_0 (type)
- input_1 (Callable | None)
- Return type: Self
build()
Builds an immutable collection from the currently added filters.
Returns: : The created collection.
- Return type: Self
by_content_type()
Gets the currently registered hook factories by their content types.
Returns: : The hook factories by their content types.
clear()
Removes all currently registered filters.
Returns: : The same filter builder object for fluent API calls
- Return type: Self