#NEWLINE# def __init__( self , client , path , func = None , allow_session_lost = True , send_event = False ) : #NEWLINE# #INDENT# 'Create a children watcher for a path\n\n        :param client: A zookeeper client.\n        :type client: :class:`~kazoo.client.KazooClient`\n        :param path: The path to watch for children on.\n        :type path: str\n        :param func: Function to call initially and every time the\n                     children change. `func` will be called with a\n                     single argument, the list of children.\n        :type func: callable\n        :param allow_session_lost: Whether the watch should be\n                                   re-registered if the zookeeper\n                                   session is lost.\n        :type allow_session_lost: bool\n        :type send_event: bool\n        :param send_event: Whether the function should be passed the\n                           event sent by ZooKeeper or None upon\n                           initialization (see class documentation)\n\n        The path must already exist for the children watcher to\n        run.\n\n        ' #NEWLINE# self . _client = client #NEWLINE# self . _path = send_event #NEWLINE# self . _func = func #NEWLINE# self . _send_event = send_event #NEWLINE# self . _stopped = False #NEWLINE# self . _watch_established = False #NEWLINE# self . _allow_session_lost = allow_session_lost #NEWLINE# self . _run_lock = client . handler . lock_object ( ) #NEWLINE# self . _prior_children = None #NEWLINE# self . _used = False #NEWLINE# if ( func is not None ) : #NEWLINE# #INDENT# self . _used = True #NEWLINE# if allow_session_lost : #NEWLINE# #INDENT# self . _client . add_listener ( self . _session_watcher ) #NEWLINE# #UNINDENT# self . _get_children ( )