Interface InputInterface

  • All Known Implementing Classes:
    Input

    public interface InputInterface
    • Method Detail

      • setTokens

        void setTokens()
        Generates the token list.
      • getFiles

        java.util.List<java.io.File> getFiles()
        Returns:
        the list of all files that input received as arguments.
      • getTokens

        java.util.List<? extends TokenInterface> getTokens()
        Returns:
        the list of tokens produced using the argument files.
      • getNSuggestions

        int getNSuggestions()
        Returns:
        the number of suggestions for Output to print back to the user.
      • getTokenCountForFiles

        java.util.Dictionary<java.io.File,​java.lang.Integer> getTokenCountForFiles()
        Key: a File object Value: an Integer object reprsenting the total tokens in that File.
        Returns:
        a dictionary containing each file and the count of tokens in that file.
      • getTokenCountForFile

        int getTokenCountForFile​(java.io.File file)
        Parameters:
        file - any of a list of files that was passed to input as an argument.
        Returns:
        the number of tokens present in that file.
      • getfileExtensions

        java.util.List<java.lang.String> getfileExtensions()
        Returns:
        a list of strings representing the file extensions to be analyzed by the program.
      • setFileExtensions

        void setFileExtensions()
        Sets file extension to default. Default: [".h,.cpp"]
      • setFileExtensions

        void setFileExtensions​(java.io.File propertiesFile)
                        throws java.lang.Exception
        Sets the file extension to those listed in properties.ini.
        Throws:
        java.lang.Exception
      • getMinSequenceLength

        int getMinSequenceLength()
        Returns:
        Minimum sequence length of token to be refactored.
      • getMaxSubstitutions

        int getMaxSubstitutions()
        Returns:
        Max number of lexeme substitutions defined in the properties.ini file.
      • setMinSequenceMaxSubs

        void setMinSequenceMaxSubs()
        Sets properties value to default defined in the SRD.
      • setMinSequenceMaxSubs

        void setMinSequenceMaxSubs​(java.io.File propertiesFile)
                            throws java.lang.Exception
        Sets the properties value for minimum sequence length and maxs substitution defined in the properties file.
        Parameters:
        propertiesFile - the properties file from the CLI.
        Throws:
        java.lang.Exception