Class StatusUtil


  • public class StatusUtil
    extends java.lang.Object
    • Constructor Detail

      • StatusUtil

        public StatusUtil​(Context context)
    • Method Detail

      • contextHasStatusListener

        public static boolean contextHasStatusListener​(Context context)
        Returns true if the StatusManager associated with the context passed as parameter has one or more StatusListener instances registered. Returns false otherwise.
        Parameters:
        context -
        Returns:
        true if one or more StatusListeners registered, false otherwise
        Since:
        1.0.8
      • filterStatusListByTimeThreshold

        public static java.util.List<Status> filterStatusListByTimeThreshold​(java.util.List<Status> rawList,
                                                                             long threshold)
      • addStatus

        public void addStatus​(Status status)
      • addInfo

        public void addInfo​(java.lang.Object caller,
                            java.lang.String msg)
      • addWarn

        public void addWarn​(java.lang.Object caller,
                            java.lang.String msg)
      • addError

        public void addError​(java.lang.Object caller,
                             java.lang.String msg,
                             java.lang.Throwable t)
      • hasXMLParsingErrors

        public boolean hasXMLParsingErrors​(long threshold)
      • noXMLParsingErrorsOccurred

        public boolean noXMLParsingErrorsOccurred​(long threshold)
      • getHighestLevel

        public int getHighestLevel​(long threshold)
      • isErrorFree

        public boolean isErrorFree​(long threshold)
      • isWarningOrErrorFree

        public boolean isWarningOrErrorFree​(long threshold)
      • containsMatch

        public boolean containsMatch​(long threshold,
                                     int level,
                                     java.lang.String regex)
      • containsMatch

        public boolean containsMatch​(int level,
                                     java.lang.String regex)
      • containsMatch

        public boolean containsMatch​(java.lang.String regex)
      • matchCount

        public int matchCount​(java.lang.String regex)
      • containsException

        public boolean containsException​(java.lang.Class<?> exceptionType)
      • timeOfLastReset

        public long timeOfLastReset()
        Return the time of last reset. -1 if last reset time could not be found
        Returns:
        time of last reset or -1