def initWithDelegate_(self, cb_obj):
self = super(_ChannelEventListener, self).init()<EOL>if cb_obj is None:<EOL><INDENT>raise TypeError("<STR_LIT>")<EOL><DEDENT>self.__cb_obj = cb_obj<EOL>self.__closenotif = None<EOL>self.__channelDelegate =BBBluetoothChannelDelegate.alloc().initWithDelegate_(self)<EOL>return self<EOL>
Arguments:
- cb_obj: An object that receives callbacks when events occur. This
  object should have:
    - a method '_handle_channeldata' which takes the related channel (a
      IOBluetoothRFCOMMChannel or IOBluetoothL2CAPChannel) and the new
      data (a string) as the arguments.
    - a method '_handle_channelclosed' which takes the related channel
      as the argument.

If this listener's delegate is passed to the openRFCOMMChannel... or
openL2CAPChannel... selectors as the delegate, the delegate (and
therefore this listener) will automatically start receiving events.

Otherwise, call setDelegate_() on the channel with this listener's
delegate as the argument to allow this listener to start receiving
channel events. (This is the only option for server-spawned sockets.)