Package org.fhirfrog.frog.ant.ig
Class PackageClassifier
java.lang.Object
org.fhirfrog.frog.ant.ig.PackageClassifier
Classifies FHIR packages from the local package cache as include, exclude, or skip
for a given target FHIR version (R4 or R5).
Uses FilesystemPackageCacheManager to resolve packages from
~/.fhir/packages, downloading missing packages automatically.
Walks the full transitive dependency closure via NpmPackage.dependencies().
Classification Rules (for target R4)
- Type
fhir.coreorCore→ skip (HAPI loads core implicitly) - Type
Tool→ skip - All declared FHIR versions start with
"5."→ exclude - Any declared FHIR version starts with
"4."→ include
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordResult of classifying a full dependency tree.static final recordA resolved package reference with name and version. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionResolves and classifies all packages in the transitive dependency tree rooted at the given direct dependencies.
-
Constructor Details
-
PackageClassifier
- Throws:
IOException
-
-
Method Details
-
classify
public PackageClassifier.ClassificationResult classify(Map<String, String> directDependencies) throws IOExceptionResolves and classifies all packages in the transitive dependency tree rooted at the given direct dependencies.- Parameters:
directDependencies- map of package name → version from sushi-config.yaml- Returns:
- classification result with include and exclude lists
- Throws:
IOException
-