Uses of Class
com.puppycrawl.tools.checkstyle.api.CheckstyleException
-
Packages that use CheckstyleException Package Description com.puppycrawl.tools.checkstyle Contains the implementation of the Checkstyle framework.com.puppycrawl.tools.checkstyle.api Contains the core API to be used to implement checks.com.puppycrawl.tools.checkstyle.checks.header File Header checks.com.puppycrawl.tools.checkstyle.checks.imports Contains the Imports checks that are bundled with the main distribution.com.puppycrawl.tools.checkstyle.checks.javadoc Contains the Javadoc checks that are bundled with the main distribution.com.puppycrawl.tools.checkstyle.checks.regexp Contains the regular expression checks that are bundled with the main distribution.com.puppycrawl.tools.checkstyle.filters Contains the filters that are bundled with the main distribution.com.puppycrawl.tools.checkstyle.gui User interface classes for CheckStyle.com.puppycrawl.tools.checkstyle.meta Contains module metadata generation classes for checkstyle.com.puppycrawl.tools.checkstyle.utils Contains utils classes for checkstyle. -
-
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle
Methods in com.puppycrawl.tools.checkstyle that throw CheckstyleException Modifier and Type Method Description private java.lang.ObjectPackageObjectFactory. createFromStandardCheckSet(java.lang.String name)Create object from one of Checkstyle module names.java.lang.ObjectModuleFactory. createModule(java.lang.String name)Creates a new instance of a class from a given name.java.lang.ObjectPackageObjectFactory. createModule(java.lang.String name)Creates a new instance of a class from a given name, or that name concatenated with "Check".private java.lang.ObjectPackageObjectFactory. createModuleByTryInEachPackage(java.lang.String name)Searching to class with given name (or name concatenated with "Check") in existing packages.private java.lang.ObjectPackageObjectFactory. createObject(java.lang.String className)Creates a new instance of a named class.private java.lang.ObjectPackageObjectFactory. createObjectFromFullModuleNames(java.lang.String name, java.util.Set<java.lang.String> fullModuleNames)Create Object from optional full module names.private java.lang.ObjectPackageObjectFactory. createObjectFromMap(java.lang.String name, java.util.Map<java.lang.String,java.util.Set<java.lang.String>> map)Create object with the help of the supplied map.private static intMain. execute(picocli.CommandLine.ParseResult parseResult, Main.CliOptions options)Validates the user input and returns -1 if invalid, otherwise executes CheckStyle and returns the number of violations.protected voidChecker. finishLocalSetup()private static voidJavadocPropertiesGenerator. formatInlineCodeTag(java.lang.StringBuilder builder, DetailNode inlineTag)Converts inline code tag into HTML form.java.lang.StringDefaultConfiguration. getAttribute(java.lang.String attributeName)private static java.lang.StringJavadocPropertiesGenerator. getFirstJavadocSentence(DetailAST ast)Extracts the first sentence as HTML formatted text from the comment of an DetailAST.private static java.lang.StringJavadocPropertiesGenerator. getFirstJavadocSentence(DetailNode tree)Extracts the first sentence as HTML formatted text from a DetailNode.static java.util.Set<java.lang.String>PackageNamesLoader. getPackageNames(java.lang.ClassLoader classLoader)Returns the set of package names, compiled from all checkstyle_packages.xml files found on the given class loaders classpath.java.lang.StringDefaultConfiguration. getProperty(java.lang.String propertyName)private static RootModuleMain. getRootModule(java.lang.String name, java.lang.ClassLoader moduleClassLoader)Creates a new instance of the root module that will control and run Checkstyle.private static voidJavadocPropertiesGenerator. iteratePublicStaticIntFields(DetailAST objBlock, java.util.function.Consumer<java.lang.String> consumer)Walks over the type members and push the first javadoc sentence of everypublicstaticintfield to the consumer.static ConfigurationConfigurationLoader. loadConfiguration(java.lang.String config, PropertyResolver overridePropsResolver)Returns the module configurations in a specified file.static ConfigurationConfigurationLoader. loadConfiguration(java.lang.String config, PropertyResolver overridePropsResolver, ConfigurationLoader.IgnoredModulesOptions ignoredModulesOptions)Returns the module configurations in a specified file.static ConfigurationConfigurationLoader. loadConfiguration(java.lang.String config, PropertyResolver overridePropsResolver, ConfigurationLoader.IgnoredModulesOptions ignoredModulesOptions, ThreadModeSettings threadModeSettings)Returns the module configurations in a specified file.static ConfigurationConfigurationLoader. loadConfiguration(java.lang.String config, PropertyResolver overridePropsResolver, ThreadModeSettings threadModeSettings)Returns the module configurations in a specified file.static ConfigurationConfigurationLoader. loadConfiguration(org.xml.sax.InputSource configSource, PropertyResolver overridePropsResolver, ConfigurationLoader.IgnoredModulesOptions ignoredModulesOptions)Returns the module configurations from a specified input source.static ConfigurationConfigurationLoader. loadConfiguration(org.xml.sax.InputSource configSource, PropertyResolver overridePropsResolver, ConfigurationLoader.IgnoredModulesOptions ignoredModulesOptions, ThreadModeSettings threadModeSettings)Returns the module configurations from a specified input source.private static byte[]PropertyCacheFile. loadExternalResource(java.lang.String location)Loads the content of external resource.private static java.util.PropertiesMain. loadProperties(java.io.File file)Loads properties from a File.static voidJavadocPropertiesGenerator. main(java.lang.String... args)TokenTypes.properties generator entry point.static DetailASTJavaParser. parse(FileContents contents)Static helper method to parses a Java source file.static DetailASTJavaParser. parseFile(java.io.File file, JavaParser.Options options)Parses Java source file.static DetailASTJavaParser. parseFileText(FileText text, JavaParser.Options options)Parse a text and return the parse tree.private static voidConfigurationLoader. parsePropertyString(java.lang.String value, java.util.List<java.lang.String> fragments, java.util.List<java.lang.String> propertyRefs)Parses a string containing${xxx}style property references into two lists.static java.lang.StringAstTreeStringPrinter. printAst(FileText text, JavaParser.Options options)Parse a file and print the parse tree.static java.lang.StringAstTreeStringPrinter. printFileAst(java.io.File file, JavaParser.Options options)Parse a file and print the parse tree.static java.lang.StringAstTreeStringPrinter. printJavaAndJavadocTree(java.io.File file)Prints full AST (java + comments + javadoc) of the java file.static java.lang.StringSuppressionsStringPrinter. printSuppressions(java.io.File file, java.lang.String suppressionLineColumnNumber, int tabWidth)Prints generated suppressions.intChecker. process(java.util.List<java.io.File> files)private java.util.SortedSet<Violation>Checker. processFile(java.io.File file)Processes a file with all FileSetChecks.private static voidPackageNamesLoader. processFile(java.net.URL packageFile, PackageNamesLoader namesLoader)Reads the file provided and parses it with package names loader.private voidChecker. processFiles(java.util.List<java.io.File> files)Processes a list of files with all FileSetChecks.protected voidTreeWalker. processFiltered(java.io.File file, FileText fileText)private voidTreeWalker. registerCheck(int tokenId, AbstractCheck check)Register a check for a specified token id.private voidTreeWalker. registerCheck(AbstractCheck check)Register a check for a given configuration.private static java.lang.StringConfigurationLoader. replaceProperties(java.lang.String value, PropertyResolver props, java.lang.String defaultValue)Replaces${xxx}style constructions in the given value with the string value of the corresponding data types.private static intMain. runCheckstyle(Main.CliOptions options, java.util.List<java.io.File> filesToProcess)Executes required Checkstyle actions based on passed parameters.private static intMain. runCli(Main.CliOptions options, java.util.List<java.io.File> filesToProcess)Do execution of CheckStyle based on Command line options.protected voidChecker. setupChild(Configuration childConf)Called by configure() for every child of this component's Configuration.voidTreeWalker. setupChild(Configuration childConf)Called by configure() for every child of this component's Configuration.private static voidJavadocPropertiesGenerator. writePropertiesFile(JavadocPropertiesGenerator.CliOptions options)Creates the .properties file from a .java file. -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.api
Methods in com.puppycrawl.tools.checkstyle.api that throw CheckstyleException Modifier and Type Method Description voidAutomaticBean. configure(Configuration config)Implements the Configurable interface using bean introspection.voidConfigurable. configure(Configuration configuration)Configures this component.voidAutomaticBean. contextualize(Context context)Implements the Contextualizable interface using bean introspection.voidContextualizable. contextualize(Context context)Sets the context for this Component.protected voidAbstractViolationReporter. finishLocalSetup()protected abstract voidAutomaticBean. finishLocalSetup()Provides a hook to finish the part of this component's setup that was not handled by the bean introspection.java.lang.StringConfiguration. getAttribute(java.lang.String name)Deprecated.This shall be removed in future releases.java.lang.StringConfiguration. getProperty(java.lang.String name)The property value for n property name.java.util.SortedSet<Violation>AbstractFileSetCheck. process(java.io.File file, FileText fileText)java.util.SortedSet<Violation>FileSetCheck. process(java.io.File file, FileText fileText)Request to process a file.intRootModule. process(java.util.List<java.io.File> files)Processes a set of files.protected abstract voidAbstractFileSetCheck. processFiltered(java.io.File file, FileText fileText)Called to process a file that matches the specified file extensions.protected voidAutomaticBean. setupChild(Configuration childConf)Called by configure() for every child of this component's Configuration.private voidAutomaticBean. tryCopyProperty(java.lang.String key, java.lang.Object value, boolean recheck)Recheck property and try to copy it. -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.checks.header
Methods in com.puppycrawl.tools.checkstyle.checks.header that throw CheckstyleException Modifier and Type Method Description protected voidAbstractHeaderCheck. finishLocalSetup()private voidAbstractHeaderCheck. loadHeaderFile()Load the header from a file.voidAbstractHeaderCheck. setHeaderFile(java.net.URI uri)Setter to specify the name of the file containing the required header.. -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.checks.imports
Methods in com.puppycrawl.tools.checkstyle.checks.imports that throw CheckstyleException Modifier and Type Method Description static PkgImportControlImportControlLoader. load(java.net.URI uri)Loads the import control file from a file.private static PkgImportControlImportControlLoader. load(org.xml.sax.InputSource source, java.net.URI uri)Loads the import control file from aInputSource.private static PkgImportControlImportControlLoader. loadUri(java.net.URI uri)Loads the import control file from a URI. -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.checks.javadoc
Methods in com.puppycrawl.tools.checkstyle.checks.javadoc that throw CheckstyleException Modifier and Type Method Description protected voidJavadocPackageCheck. processFiltered(java.io.File file, FileText fileText) -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.checks.regexp
Methods in com.puppycrawl.tools.checkstyle.checks.regexp that throw CheckstyleException Modifier and Type Method Description private static java.lang.StringRegexpOnFilenameCheck. getFolderPath(java.io.File file)Retrieves the folder path from the givenfile.protected voidRegexpOnFilenameCheck. processFiltered(java.io.File file, FileText fileText) -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.filters
Methods in com.puppycrawl.tools.checkstyle.filters that throw CheckstyleException Modifier and Type Method Description protected voidSuppressionFilter. finishLocalSetup()protected voidSuppressionXpathFilter. finishLocalSetup()private static SuppressionsLoaderSuppressionsLoader. getSuppressionLoader(org.xml.sax.InputSource source, java.lang.String sourceName)Parses specified source and returns the suppression loader.static FilterSetSuppressionsLoader. loadSuppressions(java.lang.String filename)Returns the suppression filters in a specified file.private static FilterSetSuppressionsLoader. loadSuppressions(org.xml.sax.InputSource source, java.lang.String sourceName)Returns the suppression filters in a specified source.static java.util.Set<TreeWalkerFilter>SuppressionsLoader. loadXpathSuppressions(java.lang.String filename)Returns the suppressionTreeWalkerfilters in a specified file.private static java.util.Set<TreeWalkerFilter>SuppressionsLoader. loadXpathSuppressions(org.xml.sax.InputSource source, java.lang.String sourceName)Returns the suppressionTreeWalkerfilters in a specified source. -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.gui
Methods in com.puppycrawl.tools.checkstyle.gui that throw CheckstyleException Modifier and Type Method Description voidMainFrameModel. openFile(java.io.File file)Open file and load the file. -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.meta
Methods in com.puppycrawl.tools.checkstyle.meta that throw CheckstyleException Modifier and Type Method Description private static voidMetadataGeneratorUtil. dumpMetadata(Checker checker, java.lang.String path, java.lang.String... moduleFolders)Process files using the checker passed and write to corresponding XML files.static voidMetadataGeneratorUtil. generate(java.lang.String path, java.io.OutputStream out, java.lang.String... moduleFolders)Generate metadata from the module source files available in the input argument path. -
Uses of CheckstyleException in com.puppycrawl.tools.checkstyle.utils
Methods in com.puppycrawl.tools.checkstyle.utils that throw CheckstyleException Modifier and Type Method Description private static java.net.URICommonUtil. getFilepathOrClasspathUri(java.lang.String filename)Resolves the specified local filename, possibly with 'classpath:' protocol, to a URI.static java.util.PropertiesChainedPropertyUtil. getResolvedProperties(java.util.Properties properties)Accepts user defined properties and returns new properties with all chained properties resolved.static java.net.URICommonUtil. getResourceFromClassPath(java.lang.String filename)Gets a resource from the classpath.static java.net.URICommonUtil. getUriByFilename(java.lang.String filename)Resolve the specified filename to a URI.static java.lang.StringXpathUtil. printXpathBranch(java.lang.String xpath, java.io.File file)Returns xpath query results on file as string.
-