Class ModelDataItem


  • public class ModelDataItem
    extends java.lang.Object
    Object to store the preprocessed data passed to the detector
    • Constructor Detail

      • ModelDataItem

        public ModelDataItem​(ISourceFile file)
        Build data item for file
        Parameters:
        file - file to build for
      • ModelDataItem

        public ModelDataItem​(ISourceFile file,
                             java.util.Map<java.lang.String,​java.util.List<IndexedString>> map)
        Build data item for file
        Parameters:
        file - file to build for
        map - map of indexed lines against the tag for their producing strategy
    • Method Detail

      • addPreProcessedLines

        public void addPreProcessedLines​(java.lang.String strategyName,
                                         java.util.List<IndexedString> lines)
        Adds a mapping for a preprocessing strategy
        Parameters:
        strategyName - tag for strategy
        lines - index lines
      • getFile

        public ISourceFile getFile()
        Get the file this data item for
        Returns:
        file
      • getPreProcessedLines

        public java.util.List<IndexedString> getPreProcessedLines​(java.lang.String strategyName)
        get the preprocessed lines for a strategy, returns null if strategy does not exist
        Parameters:
        strategyName - strategy tag
        Returns:
        lines, null if strategy does not exist