Class ArtifactTransferPolicy
- java.lang.Object
-
- org.eclipse.tycho.repository.p2base.artifact.provider.formats.ArtifactTransferPolicy
-
- Direct Known Subclasses:
ArtifactTransferPolicyBase
public abstract class ArtifactTransferPolicy extends java.lang.Object
Policy for picking the internally used artifact format when obtaining an artifact. Different policies may optimize for network bandwidth or CPU usage.- See Also:
IArtifactProvider#getArtifact(IArtifactKey, OutputStream, IProgressMonitor)
-
-
Constructor Summary
Constructors Constructor Description ArtifactTransferPolicy()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static boolean
isCanonicalFormat(org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor format)
static boolean
isPack200Format(org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor format)
abstract java.util.List<org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor>
sortFormatsByPreference(org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor[] artifactDescriptors)
Sorts a list of artifact formats by the order in which they should be tried to be used for a (non-raw) artifact read operation.
-
-
-
Method Detail
-
sortFormatsByPreference
public abstract java.util.List<org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor> sortFormatsByPreference(org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor[] artifactDescriptors)
Sorts a list of artifact formats by the order in which they should be tried to be used for a (non-raw) artifact read operation.- Parameters:
formats
- the list of raw artifact formats available from a provider- Returns:
- the list of formats, sorted by preference
-
isCanonicalFormat
public static boolean isCanonicalFormat(org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor format)
-
isPack200Format
public static boolean isPack200Format(org.eclipse.equinox.p2.repository.artifact.IArtifactDescriptor format)
-
-