twitter4j
Class TwitterAPIMonitor

java.lang.Object
  extended by twitter4j.TwitterAPIMonitor

public class TwitterAPIMonitor
extends java.lang.Object

Singleton instance of all Twitter API monitoring. Handles URL parsing and "wire off" logic. We could avoid using a singleton here if Twitter objects were instantiated from a factory.

Since:
Twitter4J 2.2.1
Author:
Nick Dellamaggiore (nick.dellamaggiore gmail.com)

Field Summary
private static twitter4j.internal.logging.Logger logger
           
private static java.util.regex.Pattern pattern
           
private static TwitterAPIMonitor SINGLETON
           
private  APIStatistics STATISTICS
           
 
Constructor Summary
private TwitterAPIMonitor()
          Constructor
 
Method Summary
static TwitterAPIMonitor getInstance()
           
 APIStatisticsMBean getStatistics()
           
(package private)  void methodCalled(java.lang.String twitterUrl, long elapsedTime, boolean success)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

private static final twitter4j.internal.logging.Logger logger

pattern

private static final java.util.regex.Pattern pattern

SINGLETON

private static final TwitterAPIMonitor SINGLETON

STATISTICS

private final APIStatistics STATISTICS
Constructor Detail

TwitterAPIMonitor

private TwitterAPIMonitor()
Constructor

Method Detail

getInstance

public static TwitterAPIMonitor getInstance()

getStatistics

public APIStatisticsMBean getStatistics()

methodCalled

void methodCalled(java.lang.String twitterUrl,
                  long elapsedTime,
                  boolean success)