Class MReportParser

java.lang.Object
be.gaudry.model.file.AbstractFileParser<Long>
be.gaudry.model.file.mreport.MReportParser
All Implemented Interfaces:
PropertyChangeListener, EventListener

public class MReportParser extends AbstractFileParser<Long>
Provided by the broldev.file.mediareporter.model project.
Since:
1.0 (Mar 31, 2011), broldev.file.mediareporter.model 0.0.1-SNAPSHOT dependency
Version:
1.0 (Mar 31, 2011)
Author:
Steph GAUDRY
  • Field Details

  • Constructor Details

    • MReportParser

      public MReportParser()
  • Method Details

    • getExtensions

      public List<String> getExtensions()
      Returns:
      the extensions
    • setExtensions

      public void setExtensions(List<String> extensions)
      Parameters:
      extensions - the extensions to set
    • getCoverFileName

      public String getCoverFileName()
      Returns:
      the coverFileName
    • setCoverFileName

      public void setCoverFileName(String coverFileName)
      Parameters:
      coverFileName - the coverFileName to set
      See Also:
      getCoverFileName()
    • getInfosFileName

      public String getInfosFileName()
      Returns:
      the infosFileName
    • setInfosFileName

      public void setInfosFileName(String infosFileName)
      Parameters:
      infosFileName - the infosFileName to set
      See Also:
      getInfosFileName()
    • getSynopsisFileName

      public String getSynopsisFileName()
      Returns:
      the synopsisFileName
    • setSynopsisFileName

      public void setSynopsisFileName(String synopsisFileName)
      Parameters:
      synopsisFileName - the synopsisFileName to set
      See Also:
      getSynopsisFileName()
    • addExtension

      public void addExtension(String extension)
      Adds an extension to the episode valid extensions
      Parameters:
      extension -
    • performOnFile

      protected boolean performOnFile(AbstractBrolWorker<Long> bgw, File file, int progressPercent, int subDirDeep)
      Description copied from class: AbstractFileParser
      Do something on each file
      Specified by:
      performOnFile in class AbstractFileParser<Long>
      Parameters:
      bgw - AbstractBrolWorker to perform cancel if needed, and report progress
      file - file to check
      progressPercent - Progress percentage
      subDirDeep - Deep of the directory in comparison with start directory
      Returns:
      true if we must stop the parsing of current directory (ie. if we have a vob file, we don't check the other files in this directory) false otherwise
    • performOnDirectory

      protected void performOnDirectory(AbstractBrolWorker<Long> bgw, File directory, int subDirDeep)
      Description copied from class: AbstractFileParser
      Do something on each directory. Does nothing in this default implementation, but may be overrided.
      Overrides:
      performOnDirectory in class AbstractFileParser<Long>
      Parameters:
      bgw - AbstractBrolWorker to notify progress.
      directory - File object. No need to check if is directory (already done in the parser)
      subDirDeep - Deep of the directory in comparison with start directory
    • parse

      public long parse(AbstractBrolWorker<Long> bgw)
      Description copied from class: AbstractFileParser
      Parses files from the defined start path, and call the AbstractFileParser.performOnFile(AbstractBrolWorker, File, int, int) on each file.
      Overrides:
      parse in class AbstractFileParser<Long>
      Returns:
      the size of the matching files, not the size of the parsed directory