Package hudson.model
Class UpdateSite.Entry
- java.lang.Object
-
- hudson.model.UpdateSite.Entry
-
- Direct Known Subclasses:
UpdateSite.Plugin
- Enclosing class:
- UpdateSite
@ExportedBean public static class UpdateSite.Entry extends Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ApigetApi()LonggetFileSize()Size of the file being advertised in bytes, ornullif unspecified/unknown.StringgetSha1()The base64 encoded binary SHA-1 checksum of the file.StringgetSha256()The base64 encoded SHA-256 checksum of the file.StringgetSha512()The base64 encoded SHA-512 checksum of the file.booleanisNewerThan(String currentVersion)Checks if the specified "current version" is older than the version of this entry.
-
-
-
Field Detail
-
sourceId
@Exported public final String sourceId
UpdateSiteID.
-
name
@Exported public final String name
Artifact ID.
-
version
@Exported public final String version
The version.
-
url
@Exported public final String url
Download URL.
-
-
Constructor Detail
-
Entry
public Entry(String sourceId, net.sf.json.JSONObject o)
-
-
Method Detail
-
getSha1
public String getSha1()
The base64 encoded binary SHA-1 checksum of the file. Can be null if not provided by the update site.- Since:
- 1.641 (and 1.625.3 LTS)
-
getSha256
public String getSha256()
The base64 encoded SHA-256 checksum of the file. Can be null if not provided by the update site.- Since:
- 2.130
-
getSha512
public String getSha512()
The base64 encoded SHA-512 checksum of the file. Can be null if not provided by the update site.- Since:
- 2.130
-
isNewerThan
public boolean isNewerThan(String currentVersion)
Checks if the specified "current version" is older than the version of this entry.- Parameters:
currentVersion- The string that represents the version number to be compared.- Returns:
- true if the version listed in this entry is newer. false otherwise, including the situation where the strings couldn't be parsed as version numbers.
-
getApi
public Api getApi()
-
getFileSize
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public Long getFileSize()
Size of the file being advertised in bytes, ornullif unspecified/unknown.- Returns:
- size of the file if known,
nullotherwise. - Since:
- 2.325
-
-