Class CommandStats

java.lang.Object
org.deltava.beans.acars.CommandStats
All Implemented Interfaces:
Serializable, Comparable<CommandStats>, ViewEntry

public class CommandStats extends Object implements Serializable, Comparable<CommandStats>, ViewEntry
A bean to store ACARS Server Command statistics.
Since:
8.6
Version:
8.6
Author:
Luke
See Also:
  • Constructor Details

    • CommandStats

      public CommandStats(String name)
      Creates a new Web Site Command statistics bean.
      Parameters:
      name - the command ID
      Throws:
      NullPointerException - if name is null
      See Also:
  • Method Details

    • getName

      public String getName()
      Returns the Command ID.
      Returns:
      the command ID
    • getCount

      public int getCount()
      Returns the number of times the Command was executed.
      Returns:
      the invocation count
      See Also:
    • getSuccessCount

      public int getSuccessCount()
      Returns the number of times the Command was successfully executed.
      Returns:
      the invocation count
      See Also:
    • getAvgTime

      public int getAvgTime()
      Returns the average Command execution time.
      Returns:
      the average execution time, in milliseconds
      See Also:
    • getAvgBackEndTime

      public int getAvgBackEndTime()
      Returns the average back-end data source use time.
      Returns:
      the average use time, in milliseconds
      See Also:
    • getMaxTime

      public long getMaxTime()
      Returns the maximum Command execution time.
      Returns:
      the maximum execution time, in millseconds
      See Also:
    • getMaxBackEndTime

      public long getMaxBackEndTime()
      Returns the miaxmum back-end data source use time.
      Returns:
      the maximum use time, in millseconds
      See Also:
    • increment

      public void increment()
      Increments the execution count for this Command.
      See Also:
    • success

      public void success(long totalTime, long backEndTime)
      Incrementss the number of times this Command was successfully executed.
      Parameters:
      totalTime - the total execution time in milliseconds
      backEndTime - the total back-end execution time in milliseconds
      See Also:
    • compareTo

      public int compareTo(CommandStats cse2)
      Specified by:
      compareTo in interface Comparable<CommandStats>
    • getRowClassName

      public String getRowClassName()
      Description copied from interface: ViewEntry
      Returns the CSS class for this object if rendered in a view table.
      Specified by:
      getRowClassName in interface ViewEntry
      Returns:
      the CSS class name, or NULL if none