Ver código fonte

Add docstring for plotting of exchanged packets per connection

dustin.born 6 anos atrás
pai
commit
fee6955140
1 arquivos alterados com 7 adições e 0 exclusões
  1. 7 0
      code/ID2TLib/Statistics.py

+ 7 - 0
code/ID2TLib/Statistics.py

@@ -1029,6 +1029,13 @@ class Statistics:
                 return out
 
         def plot_packets_per_connection(file_ending: str):
+            """
+            Plots the exchanged packets per connection as horizontal bar plot. 
+            Included are 'half-open' connections, where only one packet is exchanged.
+
+            :param file_ending: The file extension for the output file containing the plot
+            :return: A filepath to the file containing the created plot
+            """
             plt.gcf().clear()
             result = self.stats_db._process_user_defined_query(
                 "SELECT ipAddressA, portA, ipAddressB, portB, pktsCount FROM conv_statistics_stateless")