Class DomainIngester

  • All Implemented Interfaces:
    java.lang.Runnable

    public class DomainIngester
    extends java.lang.Thread
    This class manages a thread that ingests (i.e. creates) new domains.
    • Nested Class Summary

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

        java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
    • Field Summary

      • Fields inherited from class java.lang.Thread

        MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
    • Constructor Summary

      Constructors 
      Constructor Description
      DomainIngester​(javax.servlet.jsp.JspWriter out, java.io.File ingestFile, java.util.Locale l)
      Create a new ingester for a given session and output, reading domains from a file.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Exception getException()  
      boolean isDone()
      Check whether or not the DomainIngester is finished.
      void run()
      Starts the ingesting thread.
      • 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, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • DomainIngester

        public DomainIngester​(javax.servlet.jsp.JspWriter out,
                              java.io.File ingestFile,
                              java.util.Locale l)
        Create a new ingester for a given session and output, reading domains from a file.
        Parameters:
        out - The writer that goes into HTML output
        ingestFile - The file with a list of domains to ingest.
        l - the given locale
    • Method Detail

      • run

        public void run()
        Starts the ingesting thread. When 'done' is set to true, the thread is finished, and any exceptions are found in 'e'.
        Specified by:
        run in interface java.lang.Runnable
        Overrides:
        run in class java.lang.Thread
      • isDone

        public boolean isDone()
        Check whether or not the DomainIngester is finished.
        Returns:
        true if finished; false otherwise
      • getException

        public java.lang.Exception getException()
        Returns:
        any exception caught during ingest