Package org.eclipse.aether.repository
Class RepositoryPolicy
java.lang.Object
org.eclipse.aether.repository.RepositoryPolicy
A policy controlling access to a repository.
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final StringVerify checksums and fail the resolution if they do not match.static final StringDo not verify checksums.static final StringVerify checksums and warn if they do not match.static final StringAlways update locally cached data.static final StringUpdate locally cached data once a day.static final StringUpdate locally cached data every X minutes as given by "interval:X".static final StringNever update locally cached data.
- 
Constructor SummaryConstructorsConstructorDescriptionCreates a new policy with checksum warnings and daily update checks.RepositoryPolicy(boolean enabled, String updatePolicy, String checksumPolicy) Creates a new policy with the specified settings.
- 
Method Summary
- 
Field Details- 
UPDATE_POLICY_NEVERNever update locally cached data.- See Also:
 
- 
UPDATE_POLICY_ALWAYSAlways update locally cached data.- See Also:
 
- 
UPDATE_POLICY_DAILYUpdate locally cached data once a day.- See Also:
 
- 
UPDATE_POLICY_INTERVALUpdate locally cached data every X minutes as given by "interval:X".- See Also:
 
- 
CHECKSUM_POLICY_FAILVerify checksums and fail the resolution if they do not match.- See Also:
 
- 
CHECKSUM_POLICY_WARNVerify checksums and warn if they do not match.- See Also:
 
- 
CHECKSUM_POLICY_IGNOREDo not verify checksums.- See Also:
 
 
- 
- 
Constructor Details- 
RepositoryPolicypublic RepositoryPolicy()Creates a new policy with checksum warnings and daily update checks.
- 
RepositoryPolicyCreates a new policy with the specified settings.- Parameters:
- enabled- A flag whether the associated repository should be accessed or not.
- updatePolicy- The update interval after which locally cached data from the repository is considered stale and should be refetched, may be- null.
- checksumPolicy- The way checksum verification should be handled, may be- null.
 
 
- 
- 
Method Details- 
isEnabledIndicates whether the associated repository should be contacted or not.- Returns:
- trueif the repository should be contacted,- falseotherwise.
 
- 
getUpdatePolicyGets the update policy for locally cached data from the repository.- Returns:
- The update policy, never null.
 
- 
getChecksumPolicyGets the policy for checksum validation.- Returns:
- The checksum policy, never null.
 
- 
toString
- 
equals
- 
hashCode
 
-