'Returns a context object for use by job.get_record_context.'

def get_context(self):

    class context(object, ):
        def __init__(self, indenter, indent):
            self._indenter = indenter
            self._indent = indent
        def restore(self):
            self._indenter._indent = self._indent
    return context(self, self._indent)
