Class ParserExecutor

java.lang.Object
java.util.concurrent.AbstractExecutorService
java.util.concurrent.ThreadPoolExecutor
org.nuiton.i18n.plugin.parser.ParserExecutor
All Implemented Interfaces:
java.util.concurrent.Executor, java.util.concurrent.ExecutorService, I18nParserConfiguration

public class ParserExecutor
extends java.util.concurrent.ThreadPoolExecutor
implements I18nParserConfiguration
Since:
1.2.2
Author:
poussin
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.util.concurrent.ThreadPoolExecutor

    java.util.concurrent.ThreadPoolExecutor.AbortPolicy, java.util.concurrent.ThreadPoolExecutor.CallerRunsPolicy, java.util.concurrent.ThreadPoolExecutor.DiscardOldestPolicy, java.util.concurrent.ThreadPoolExecutor.DiscardPolicy
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected I18nParserConfiguration configuration
    the incoming configuration (from mojo which contains shared result and logger)
    protected int nbFiles
    number of files registred to consume
    protected java.util.List<java.io.File> touchedFiles
    list of files touched (says having at least one i18n key)
    protected java.util.List<java.io.File> treatedFiles
    list of files consumed
  • Constructor Summary

    Constructors 
    Constructor Description
    ParserExecutor​(I18nParserConfiguration configuration)  
  • Method Summary

    Modifier and Type Method Description
    void addFile​(FileParser parser, java.io.File... files)
    Add a file to be consumed.
    protected void afterExecute​(java.lang.Runnable r, java.lang.Throwable t)  
    void clear()
    clean internal state after usage of the thread.
    protected I18nParserConfiguration getConfiguration()  
    org.apache.maven.plugin.logging.Log getLog()  
    protected int getNbFilesToTreate()  
    org.nuiton.io.SortedProperties getResult()  
    java.util.List<java.io.File> getTouchedFiles()  
    java.util.List<java.io.File> getTreatedFiles()  
    boolean isShowTouchedFiles()  
    boolean isSilent()  
    boolean isVerbose()  
    void terminatesAndWaits()
    Ask the thread to stop.

    Methods inherited from class java.util.concurrent.ThreadPoolExecutor

    allowCoreThreadTimeOut, allowsCoreThreadTimeOut, awaitTermination, beforeExecute, execute, finalize, getActiveCount, getCompletedTaskCount, getCorePoolSize, getKeepAliveTime, getLargestPoolSize, getMaximumPoolSize, getPoolSize, getQueue, getRejectedExecutionHandler, getTaskCount, getThreadFactory, isShutdown, isTerminated, isTerminating, prestartAllCoreThreads, prestartCoreThread, purge, remove, setCorePoolSize, setKeepAliveTime, setMaximumPoolSize, setRejectedExecutionHandler, setThreadFactory, shutdown, shutdownNow, terminated, toString

    Methods inherited from class java.util.concurrent.AbstractExecutorService

    invokeAll, invokeAll, invokeAny, invokeAny, newTaskFor, newTaskFor, submit, submit, submit

    Methods inherited from class java.lang.Object

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