Package org.snpeff.logStatsServer

# Class LogStats

java.lang.Object
java.lang.Thread
org.snpeff.logStatsServer.LogStats

All Implemented Interfaces:
  `Runnable`

public class LogStats extends Thread
Log basic usage information to a server (for feedback and stats) This information an always be suppressed (no info sent at all)

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`static enum`
`LogStats.RequestResult`

## Nested classes/interfaces inherited from class java.lang.Thread

`Thread.Builder, Thread.State, Thread.UncaughtExceptionHandler`

## Field Summary

Fields
Modifier and Type
Field
Description
`static boolean`
`debug`
`protected boolean`
`log`
`static final int`
`LOG_THREAD_WAIT_TIME`
`static final int`
`LOG_THREAD_WAIT_TIME_REPEAT`
`StringBuilder`
`msg`
`protected boolean`
`verbose`

### Fields inherited from class java.lang.Thread

`MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY`

## Constructor Summary

Constructors
Constructor
Description
`LogStats(String software, String versionShort, String versionFull)`
Constructor

## Method Summary

Modifier and Type
Method
Description
`void`
`add(String name, String value)`
Add a 'name=value' pair
`void`
`connect()`
Connect to server
`LogStats.RequestResult`
`getRes()`
`static LogStats`
`report(String software, String versionShort, String versionFull, boolean ok, boolean verbose, String[] args, String errorMessage, HashMap<String,String> reportValues)`
Report stats to server
`void`
`run()`
Run thread in background

### Methods inherited from class java.lang.Thread

`activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, isVirtual, join, join, join, join, ofPlatform, ofVirtual, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, sleep, start, startVirtualThread, stop, suspend, threadId, toString, yield`

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

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

## Field Details

### LOG_THREAD_WAIT_TIME

public static final int LOG_THREAD_WAIT_TIME

See Also:
  - Constant Field Values

### LOG_THREAD_WAIT_TIME_REPEAT

public static final int LOG_THREAD_WAIT_TIME_REPEAT

See Also:
  - Constant Field Values

### debug

public static boolean debug

### msg

public StringBuilder msg

### log

protected boolean log

### verbose

protected boolean verbose

## Constructor Details

### LogStats

public LogStats(String software, String versionShort, String versionFull)
Constructor

## Method Details

### report

public static LogStats report(String software, String versionShort, String versionFull, boolean ok, boolean verbose, String[] args, String errorMessage, HashMap<String,String> reportValues)
Report stats to server

Parameters:
  `versionFull` - : Program name and version
  `ok` - : Did the program finished OK?
  `verbose` - : Be verbose while reporting
  `args` - : Program's command line arguments
  `errorMessage` - : Error messages (if any)
  `reportValues` - : A hash containing invalid input: '<'name, value> pairs to report

### add

public void add(String name, String value)
Add a 'name=value' pair

### connect

public void connect()
Connect to server

### getRes

public LogStats.RequestResult getRes()

### run

public void run()
Run thread in background

Specified by:
  `run` in interface `Runnable`
Overrides:
  `run` in class `Thread`