View Javadoc
1   /*
2    * Copyright 2020 The Netty Project
3    *
4    * The Netty Project licenses this file to you under the Apache License,
5    * version 2.0 (the "License"); you may not use this file except in compliance
6    * with the License. You may obtain a copy of the License at:
7    *
8    *   https://www.apache.org/licenses/LICENSE-2.0
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12   * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13   * License for the specific language governing permissions and limitations
14   * under the License.
15   */
16  package io.netty.handler.codec.quic;
17  
18  /**
19   * Statistics about the {@code QUIC} connection. If unknown by the implementation it might return {@code -1} values
20   * for the various methods.
21   */
22  public interface QuicConnectionStats {
23      /**
24       * @return The number of QUIC packets received on the connection.
25       */
26      long recv();
27  
28      /**
29       * @return The number of QUIC packets sent on this connection.
30       */
31      long sent();
32  
33      /**
34       * @return The number of QUIC packets that were lost.
35       */
36      long lost();
37  
38      /**
39       * @return The number of sent QUIC packets with retransmitted data.
40       */
41      long retrans();
42  
43      /**
44       * @return The number of sent bytes.
45       */
46      long sentBytes();
47  
48      /**
49       * @return The number of received bytes.
50       */
51      long recvBytes();
52  
53      /**
54       * @return  The number of bytes lost.
55       */
56      long lostBytes();
57  
58      /**
59       * @return  The number of stream bytes retransmitted.
60       */
61      long streamRetransBytes();
62  
63      /**
64       * @return   The number of known paths for the connection.
65       */
66      long pathsCount();
67  }