1. Lynn Rees
  2. callchain


callchain / callchain / root / keys.py

# -*- coding: utf-8 -*-
'''callchain contrib keys'''

from callchain.keys.base import KConfig
from callchain.keys.mixin import KCall, KChain
from callchain.keys.queue import KResult, KThings

class KEventManager(KConfig):

    '''root event key'''

    def event(event):  # @NoSelf
        create or fetch `event`

        @param event: event label

    def unevent(event):  # @NoSelf
        drop `event`

        @param event: event label

class KRoot(KConfig, KChain, KCall):

    '''root chain key'''

    def __call__(*args):  # @NoSelf
        '''new chain session'''

    def back(branch):  # @NoSelf
        handle return from branch chain

        @param branch: branch chain

class KRootThings(KRoot, KThings):

    '''root chain with results'''

class KRootResults(KRoot, KResult):

    '''root chain with results'''