public class JavaLanguageSupport extends Object implements LanguageSupport
| Constructor and Description |
|---|
JavaLanguageSupport() |
| Modifier and Type | Method and Description |
|---|---|
Set<String> |
getSupportedFileExtensions()
The set of supported file extensions.
|
List<ImportStatement> |
parseImport(String line,
int lineNumber)
Extract the package names that this import statement represents.
|
Optional<String> |
parsePackage(String line)
Parses the given line and returns the declared package
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetLanguageSupport, isLanguageSupportedpublic Set<String> getSupportedFileExtensions()
LanguageSupportgetSupportedFileExtensions in interface LanguageSupportpublic Optional<String> parsePackage(String line)
LanguageSupportparsePackage in interface LanguageSupportline - Line in the source filepublic List<ImportStatement> parseImport(String line, int lineNumber)
LanguageSupporte.g. import java.util.List; The above should return java.util.List in a Java source file.
parseImport in interface LanguageSupportline - Line in the source filelineNumber - The line number of the import.Copyright © 2014–2019. All rights reserved.