Interface ClassResolver.ClassUriImporter
-
- Enclosing interface:
- ClassResolver
@PublicAPI(usage=ACCESS) public static interface ClassResolver.ClassUriImporter
Provides a way to import a JavaClass from a givenURI.- See Also:
tryImport(URI)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Optional<JavaClass>tryImport(java.net.URI uri)Try to import aJavaClassfrom the givenURI, i.e.
-
-
-
Method Detail
-
tryImport
@PublicAPI(usage=ACCESS) Optional<JavaClass> tryImport(java.net.URI uri)
Try to import aJavaClassfrom the givenURI, i.e. open a stream and use the default core import, to create aJavaClassfrom it.
NOTE:ClassUriImporterhas to be resilient against errors during import, e.g.IOExceptionsorMalformedURLExceptions. Errors while reading from the givenURIwill always result in an Optional.absent() return value, no need to catchExceptions.
-
-