Class JrtFileSystemAnalysisInputLocation
java.lang.Object
sootup.java.bytecode.frontend.inputlocation.JrtFileSystemAnalysisInputLocation
- All Implemented Interfaces:
AnalysisInputLocation
,ModuleInfoAnalysisInputLocation
public class JrtFileSystemAnalysisInputLocation
extends Object
implements ModuleInfoAnalysisInputLocation
Base class for
AnalysisInputLocation
s that can be located by a Path
object.- Author:
- Andreas Dann created on 06.06.18
-
Constructor Summary
ConstructorDescriptionJrtFileSystemAnalysisInputLocation
(SourceType sourceType) JrtFileSystemAnalysisInputLocation
(SourceType sourceType, List<BodyInterceptor> bodyInterceptors) -
Method Summary
Modifier and TypeMethodDescriptionDiscover and return all modules contained in the jrt filesystem.boolean
protected ClassProvider
getClassProvider
(View view) getClassSource
(ClassType classType, View view) Create or find a class source for a given type.getClassSources
(View view) Scan the input location and create ClassSources for every compilation / interpretation unit.protected Stream<JavaSootClassSource>
getClassSourcesInternal
(ModuleSignature moduleSignature, IdentifierFactory identifierFactory, View view) getModuleInfo
(ModuleSignature sig, View view) getModules
(View view) getModulesClassSources
(ModuleSignature moduleSignature, View view) Retreive CLassSources of a module specified by methodSignatureIf the AnalysisInputLocation is initialized with the SourceType then this method should return that specific SourceType.int
hashCode()
-
Constructor Details
-
JrtFileSystemAnalysisInputLocation
public JrtFileSystemAnalysisInputLocation() -
JrtFileSystemAnalysisInputLocation
-
JrtFileSystemAnalysisInputLocation
public JrtFileSystemAnalysisInputLocation(@Nonnull SourceType sourceType, @Nonnull List<BodyInterceptor> bodyInterceptors)
-
-
Method Details
-
getClassSource
@Nonnull public Optional<JavaSootClassSource> getClassSource(@Nonnull ClassType classType, @Nonnull View view) Description copied from interface:AnalysisInputLocation
Create or find a class source for a given type.- Specified by:
getClassSource
in interfaceAnalysisInputLocation
- Parameters:
classType
- The type of the class to be found.- Returns:
- The source entry for that class.
-
getModulesClassSources
@Nonnull public Collection<JavaSootClassSource> getModulesClassSources(@Nonnull ModuleSignature moduleSignature, @Nonnull View view) Retreive CLassSources of a module specified by methodSignature- Specified by:
getModulesClassSources
in interfaceModuleInfoAnalysisInputLocation
-
getClassSourcesInternal
@Nonnull protected Stream<JavaSootClassSource> getClassSourcesInternal(@Nonnull ModuleSignature moduleSignature, @Nonnull IdentifierFactory identifierFactory, @Nonnull View view) -
getClassProvider
-
getClassSources
Description copied from interface:AnalysisInputLocation
Scan the input location and create ClassSources for every compilation / interpretation unit.- Specified by:
getClassSources
in interfaceAnalysisInputLocation
- Returns:
- The source entries.
-
discoverModules
Discover and return all modules contained in the jrt filesystem.- Returns:
- Collection of found module names.
-
getModuleInfo
- Specified by:
getModuleInfo
in interfaceModuleInfoAnalysisInputLocation
-
getModules
- Specified by:
getModules
in interfaceModuleInfoAnalysisInputLocation
-
getSourceType
Description copied from interface:AnalysisInputLocation
If the AnalysisInputLocation is initialized with the SourceType then this method should return that specific SourceType. This is the default implementation and it returns null when no source type is specified.- Specified by:
getSourceType
in interfaceAnalysisInputLocation
- Returns:
- returns null as source type
-
getBodyInterceptors
- Specified by:
getBodyInterceptors
in interfaceAnalysisInputLocation
-
equals
-
hashCode
public int hashCode()
-