Class SearchPathIncludeResolver
java.lang.Object
io.github.protasm.jvmud.compiler.preproc.SearchPathIncludeResolver
- All Implemented Interfaces:
IncludeResolver
Include resolver that searches a configurable list of system include roots.
-
Constructor Summary
ConstructorsConstructorDescriptionSearchPathIncludeResolver(Path baseIncludePath, List<Path> systemIncludePaths) -
Method Summary
Modifier and TypeMethodDescriptionResolve an include path to source text.
-
Constructor Details
-
SearchPathIncludeResolver
-
-
Method Details
-
resolve
public IncludeResolution resolve(Path includingFile, String includePath, boolean system) throws IOException Description copied from interface:IncludeResolverResolve an include path to source text.- Specified by:
resolvein interfaceIncludeResolver- Parameters:
includingFile- absolute or virtual path of the including fileName (may be null for roots)includePath- the raw string inside#include "..."or#include <...>system- true for#include <...>, false for#include "..."- Returns:
- the loaded source text
- Throws:
IOException- if not found or unreadable
-