Package org.pkl.core.packages
Interface PackageResolver
- All Superinterfaces:
AutoCloseable,Closeable
-
Method Summary
Modifier and TypeMethodDescriptionvoiddownloadPackage(PackageUri uri, @Nullable Checksums checksums, boolean noTransitive) byte[]getBytes(PackageAssetUri uri, boolean allowDirectories, @Nullable Checksums checksums) Reads the byte contents of the resource within a package.getDependencyMetadata(PackageUri uri, @Nullable Checksums checksums) getDependencyMetadataAndComputeChecksum(PackageUri packageUri) static PackageResolvergetInstance(SecurityManager securityManager, HttpClient httpClient, @Nullable Path cachedDir) booleanhasElement(PackageAssetUri uri, @Nullable Checksums checksums) listElements(PackageAssetUri uri, @Nullable Checksums checksums)
-
Method Details
-
getInstance
static PackageResolver getInstance(SecurityManager securityManager, HttpClient httpClient, @Nullable @Nullable Path cachedDir) -
getDependencyMetadata
DependencyMetadata getDependencyMetadata(PackageUri uri, @Nullable @Nullable Checksums checksums) throws IOException, SecurityManagerException - Throws:
IOExceptionSecurityManagerException
-
getDependencyMetadataAndComputeChecksum
Pair<DependencyMetadata,Checksums> getDependencyMetadataAndComputeChecksum(PackageUri packageUri) throws IOException, SecurityManagerException - Throws:
IOExceptionSecurityManagerException
-
downloadPackage
void downloadPackage(PackageUri uri, @Nullable @Nullable Checksums checksums, boolean noTransitive) throws OperationNotSupportedException, IOException, SecurityManagerException -
getBytes
byte[] getBytes(PackageAssetUri uri, boolean allowDirectories, @Nullable @Nullable Checksums checksums) throws IOException, SecurityManagerException Reads the byte contents of the resource within a package.- Throws:
IOExceptionSecurityManagerException
-
listElements
List<PathElement> listElements(PackageAssetUri uri, @Nullable @Nullable Checksums checksums) throws IOException, SecurityManagerException - Throws:
IOExceptionSecurityManagerException
-
hasElement
boolean hasElement(PackageAssetUri uri, @Nullable @Nullable Checksums checksums) throws IOException, SecurityManagerException - Throws:
IOExceptionSecurityManagerException
-