ó V!¶\c@sJddlmZddlmZddlmZdefd„ƒYZdS(iÿÿÿÿ(tsix(taccepts_kwargs(tInvalidSubscriberMethodErrortBaseSubscribercBsPeZdZdddgZd„Zed„ƒZd„Zd„Zd„Z RS( s¶The base subscriber class It is recommended that all subscriber implementations subclass and then override the subscription methods (i.e. on_{subsribe_type}() methods). tqueuedtprogresstdonecOs |jƒtt|ƒj|ƒS(N(t_validate_subscriber_methodstsuperRt__new__(tclstargstkwargs((s</tmp/pip-install-usGedi/s3transfer/s3transfer/subscribers.pyR s cCslxe|jD]Z}t|d|ƒ}tj|ƒsEtd|ƒ‚nt|ƒs td|ƒ‚q q WdS(Nton_s&Subscriber method %s must be callable.s=Subscriber method %s must accept keyword arguments (**kwargs)(tVALID_SUBSCRIBER_TYPEStgetattrRtcallableRR(R tsubscriber_typetsubscriber_method((s</tmp/pip-install-usGedi/s3transfer/s3transfer/subscribers.pyR#s  cKsdS(sùCallback to be invoked when transfer request gets queued This callback can be useful for: * Keeping track of how many transfers have been requested * Providing the expected transfer size through future.meta.provide_transfer_size() so a HeadObject would not need to be made for copies and downloads. :type future: s3transfer.futures.TransferFuture :param future: The TransferFuture representing the requested transfer. N((tselftfutureR ((s</tmp/pip-install-usGedi/s3transfer/s3transfer/subscribers.pyt on_queued1s cKsdS(sjCallback to be invoked when progress is made on transfer This callback can be useful for: * Recording and displaying progress :type future: s3transfer.futures.TransferFuture :param future: The TransferFuture representing the requested transfer. :type bytes_transferred: int :param bytes_transferred: The number of bytes transferred for that invocation of the callback. Note that a negative amount can be provided, which usually indicates that an in-progress request needed to be retried and thus progress was rewound. N((RRtbytes_transferredR ((s</tmp/pip-install-usGedi/s3transfer/s3transfer/subscribers.pyt on_progress@scKsdS(säCallback to be invoked once a transfer is done This callback can be useful for: * Recording and displaying whether the transfer succeeded or failed using future.result() * Running some task after the transfer completed like changing the last modified time of a downloaded file. :type future: s3transfer.futures.TransferFuture :param future: The TransferFuture representing the requested transfer. N((RRR ((s</tmp/pip-install-usGedi/s3transfer/s3transfer/subscribers.pyton_doneRs ( t__name__t __module__t__doc__RR t classmethodRRRR(((s</tmp/pip-install-usGedi/s3transfer/s3transfer/subscribers.pyRs    N(tbotocore.compatRts3transfer.compatRts3transfer.exceptionsRtobjectR(((s</tmp/pip-install-usGedi/s3transfer/s3transfer/subscribers.pyt s