kwin commented on code in PR #1762:
URL: https://github.com/apache/maven-resolver/pull/1762#discussion_r3519565814
##########
maven-resolver-spi/src/main/java/org/eclipse/aether/spi/connector/transport/TransportListener.java:
##########
@@ -34,19 +35,39 @@
*/
public abstract class TransportListener {
+ public interface TransportPropertyKey {}
+
/**
* Enables subclassing.
*/
protected TransportListener() {}
+ /**
+ * Notifies the listener about the start of the data transfer. This event
may arise more than once if the transfer
+ * needs to be restarted (e.g. after an authentication failure).
+ *
+ * @param dataOffset The byte offset in the resource at which the transfer
starts, must not be negative.
+ * @param dataLength The total number of bytes in the resource or {@code
-1} if the length is unknown.
+ * @param transportProperties The transport properties associated with
this transfer, may be empty. The keys are transporter specific and the value
types are key specific.
+ * @throws TransferCancelledException If the transfer should be aborted.
+ * @since NEXT
+ */
+ public void transportStarted(
+ long dataOffset, long dataLength, Map<TransportPropertyKey,
Object> transportProperties)
+ throws TransferCancelledException {
+ transportStarted(dataOffset, dataLength);
+ }
+
/**
* Notifies the listener about the start of the data transfer. This event
may arise more than once if the transfer
Review Comment:
What about adding an additional parameter direction which indicates, whether
this is about receiving or sending?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]