public class ReferencePackage extends AbstractDistributionPackage
DistributionPackage providing a reference to it
by its DistributionPackage.getId().PACKAGES_ROOT| Constructor and Description |
|---|
ReferencePackage(DistributionPackage distributionPackage) |
| Modifier and Type | Method and Description |
|---|---|
void |
acquire(String... holderNames)
acquire a reference to this package and increase the reference count.
|
void |
close()
closes all resources associated with this instance
|
@NotNull InputStream |
createInputStream()
creates a package stream.
|
void |
delete()
releases all resources associated with this package
|
@Nullable String |
getDigestAlgorithm() |
String |
getDigestMessage() |
@NotNull String |
getId()
get package id.
|
long |
getSize() |
@NotNull String |
getType()
get the type of package
|
static @Nullable String |
idFromReference(String reference) |
static boolean |
isReference(String string) |
void |
release(String... holderNames)
release a reference to this package and decrease the reference count.
|
getInfopublic ReferencePackage(DistributionPackage distributionPackage)
public void acquire(@NotNull
String... holderNames)
SharedDistributionPackagepublic void release(@NotNull
String... holderNames)
SharedDistributionPackageDistributionPackage#delete method will be invoked.@NotNull public @NotNull InputStream createInputStream() throws IOException
DistributionPackageInputStreamIOExceptionpublic long getSize()
public void close()
DistributionPackagepublic void delete()
DistributionPackage@NotNull public @NotNull String getType()
DistributionPackagegetType in interface DistributionPackagegetType in class AbstractDistributionPackage@NotNull public @NotNull String getId()
DistributionPackagegetId in interface DistributionPackagegetId in class AbstractDistributionPackage@Nullable public @Nullable String getDigestAlgorithm()
getDigestAlgorithm in class AbstractDistributionPackagepublic String getDigestMessage()
getDigestMessage in class AbstractDistributionPackagepublic static boolean isReference(String string)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.