You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
1.1 KiB
Python
37 lines
1.1 KiB
Python
"""
|
|
Basic post processor
|
|
"""
|
|
# -----------------------------------------------------------------------------
|
|
# Copyright (c) 2013, the IPython Development Team.
|
|
#
|
|
# Distributed under the terms of the Modified BSD License.
|
|
#
|
|
# The full license is in the file COPYING.txt, distributed with this software.
|
|
# -----------------------------------------------------------------------------
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Imports
|
|
# -----------------------------------------------------------------------------
|
|
|
|
from nbconvert.utils.base import NbConvertBase
|
|
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# Classes
|
|
# -----------------------------------------------------------------------------
|
|
class PostProcessorBase(NbConvertBase):
|
|
"""The base class for post processors."""
|
|
|
|
def __call__(self, input_):
|
|
"""
|
|
See def postprocess() ...
|
|
"""
|
|
self.postprocess(input_)
|
|
|
|
def postprocess(self, input_):
|
|
"""
|
|
Post-process output from a writer.
|
|
"""
|
|
msg = "postprocess"
|
|
raise NotImplementedError(msg)
|