Package tigase.stats

## Class StatisticsList

- java.lang.Object
- - tigase.stats.StatisticsList

- All Implemented Interfaces:
    `java.lang.Iterable<StatRecord>`

      public class StatisticsList
      extends java.lang.Object
      implements java.lang.Iterable<StatRecord>

  Created: Jul 10, 2009 3:23:23 PM
  Author:
    Artur Hefczyc

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `StatisticsList​(java.util.logging.Level level)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `boolean` | `add​(java.lang.String comp, java.lang.String description, float value, java.util.logging.Level recordLevel)` |
    `boolean` | `add​(java.lang.String comp, java.lang.String description, int value, java.util.logging.Level recordLevel)` |
    `boolean` | `add​(java.lang.String comp, java.lang.String description, long value, java.util.logging.Level recordLevel)` |
    `boolean` | `add​(java.lang.String comp, java.lang.String description, java.lang.String value, java.util.logging.Level recordLevel)` |
    `<E extends java.lang.Number> boolean` | `add​(java.lang.String comp, java.lang.String description, java.util.Collection<E> value, java.util.logging.Level recordLevel)` |
    `java.util.LinkedHashMap<java.lang.String,​StatRecord>` | `addCompStats​(java.lang.String comp)` |
    `boolean` | `checkLevel​(java.util.logging.Level recordLevel)` |
    `boolean` | `checkLevel​(java.util.logging.Level recordLevel, int value)` |
    `boolean` | `checkLevel​(java.util.logging.Level recordLevel, long value)` |
    `boolean` | `checkLevel​(java.util.logging.Level recordLevel, StatRecord record)` |
    `<E> java.util.Collection<E>` | `getCollectionValue​(java.lang.String dataId)` |
    `<E> java.util.Collection<E>` | `getCollectionValue​(java.lang.String comp, java.lang.String description, java.util.Collection<E> def)` |
    `int` | `getCompConnections​(java.lang.String comp)` |
    `long` | `getCompIq​(java.lang.String comp)` |
    `long` | `getCompIqReceived​(java.lang.String comp)` |
    `long` | `getCompIqSent​(java.lang.String comp)` |
    `long` | `getCompMsg​(java.lang.String comp)` |
    `long` | `getCompMsgReceived​(java.lang.String comp)` |
    `long` | `getCompMsgSent​(java.lang.String comp)` |
    `java.util.Set<java.lang.String>` | `getCompNames()` | Returns names of every component for which statistics are stored in `stats` variable
    `long` | `getCompPackets​(java.lang.String comp)` |
    `long` | `getCompPres​(java.lang.String comp)` |
    `long` | `getCompPresReceived​(java.lang.String comp)` |
    `long` | `getCompPresSent​(java.lang.String comp)` |
    `long` | `getCompReceivedPackets​(java.lang.String comp)` |
    `long` | `getCompSentPackets​(java.lang.String comp)` |
    `java.util.LinkedHashMap<java.lang.String,​StatRecord>` | `getCompStats​(java.lang.String comp)` |
    `java.lang.Object` | `getValue​(java.lang.String dataId)` |
    `float` | `getValue​(java.lang.String comp, java.lang.String description, float def)` |
    `int` | `getValue​(java.lang.String comp, java.lang.String description, int def)` |
    `long` | `getValue​(java.lang.String comp, java.lang.String description, long def)` |
    `java.lang.String` | `getValue​(java.lang.String comp, java.lang.String description, java.lang.String def)` |
    `<E> java.util.Collection<E>` | `getValue​(java.lang.String comp, java.lang.String description, java.util.Collection<E> def)` |
    `java.util.Iterator<StatRecord>` | `iterator()` |
    `java.lang.String` | `toString()` |

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface java.lang.Iterable

      `forEach, spliterator`

- - ### Constructor Detail

    - #### StatisticsList

          public StatisticsList​(java.util.logging.Level level)

  - ### Method Detail

    - #### add

          public boolean add​(java.lang.String comp,
                             java.lang.String description,
                             long value,
                             java.util.logging.Level recordLevel)

    - #### add

          public boolean add​(java.lang.String comp,
                             java.lang.String description,
                             int value,
                             java.util.logging.Level recordLevel)

    - #### add

          public boolean add​(java.lang.String comp,
                             java.lang.String description,
                             java.lang.String value,
                             java.util.logging.Level recordLevel)

    - #### add

          public boolean add​(java.lang.String comp,
                             java.lang.String description,
                             float value,
                             java.util.logging.Level recordLevel)

    - #### add

          public <E extends java.lang.Number> boolean add​(java.lang.String comp,
                                                          java.lang.String description,
                                                          java.util.Collection<E> value,
                                                          java.util.logging.Level recordLevel)

    - #### addCompStats

          public java.util.LinkedHashMap<java.lang.String,​StatRecord> addCompStats​(java.lang.String comp)

    - #### checkLevel

          public boolean checkLevel​(java.util.logging.Level recordLevel)

    - #### checkLevel

          public boolean checkLevel​(java.util.logging.Level recordLevel,
                                    long value)

    - #### checkLevel

          public boolean checkLevel​(java.util.logging.Level recordLevel,
                                    StatRecord record)

    - #### checkLevel

          public boolean checkLevel​(java.util.logging.Level recordLevel,
                                    int value)

    - #### getCompConnections

          public int getCompConnections​(java.lang.String comp)

    - #### getCompIq

          public long getCompIq​(java.lang.String comp)

    - #### getCompIqReceived

          public long getCompIqReceived​(java.lang.String comp)

    - #### getCompIqSent

          public long getCompIqSent​(java.lang.String comp)

    - #### getCompNames

          public java.util.Set<java.lang.String> getCompNames()

      Returns names of every component for which statistics are stored in `stats` variable

    - #### getCompMsg

          public long getCompMsg​(java.lang.String comp)

    - #### getCompMsgReceived

          public long getCompMsgReceived​(java.lang.String comp)

    - #### getCompMsgSent

          public long getCompMsgSent​(java.lang.String comp)

    - #### getCompPackets

          public long getCompPackets​(java.lang.String comp)

    - #### getCompPres

          public long getCompPres​(java.lang.String comp)

    - #### getCompPresReceived

          public long getCompPresReceived​(java.lang.String comp)

    - #### getCompPresSent

          public long getCompPresSent​(java.lang.String comp)

    - #### getCompReceivedPackets

          public long getCompReceivedPackets​(java.lang.String comp)

    - #### getCompSentPackets

          public long getCompSentPackets​(java.lang.String comp)

    - #### getCompStats

          public java.util.LinkedHashMap<java.lang.String,​StatRecord> getCompStats​(java.lang.String comp)

    - #### getValue

          public long getValue​(java.lang.String comp,
                               java.lang.String description,
                               long def)

    - #### getValue

          public float getValue​(java.lang.String comp,
                                java.lang.String description,
                                float def)

    - #### getValue

          public int getValue​(java.lang.String comp,
                              java.lang.String description,
                              int def)

    - #### getValue

          public java.lang.String getValue​(java.lang.String comp,
                                           java.lang.String description,
                                           java.lang.String def)

    - #### getValue

          public <E> java.util.Collection<E> getValue​(java.lang.String comp,
                                                      java.lang.String description,
                                                      java.util.Collection<E> def)

    - #### getCollectionValue

          public <E> java.util.Collection<E> getCollectionValue​(java.lang.String dataId)

    - #### getCollectionValue

          public <E> java.util.Collection<E> getCollectionValue​(java.lang.String comp,
                                                                java.lang.String description,
                                                                java.util.Collection<E> def)

    - #### getValue

          public java.lang.Object getValue​(java.lang.String dataId)

    - #### iterator

          public java.util.Iterator<StatRecord> iterator()

      Specified by:
        `iterator` in interface `java.lang.Iterable<StatRecord>`

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`