C# Class InstallPad.RemoteVersionChecker

Takes a URL and tries to find the newest version of the software that exists online.
Mostra file Open project: philc/InstallPad Class Usage Examples

Public Methods

Method Description
FillInUrl ( string url, List version ) : string

Fills in a URL like "synergy-{0}.{1}" using the integers in the version array.

LatestVersion ( string url, List startingVersion ) : List

Private Methods

Method Description
CheckExistence ( string url ) : bool

Checks to make sure a URL doesn't return 404.

CheckVersion ( string url, List currentVersion, int ordinal ) : List

Recursively check versions along the ordinal position into currentVersion. So if current version is a list of 3 items (e.g. 5.2.1) and ordinal is 1, CheckVersion will build a version string by incrementing the second number, and setting the version numbers after it (1) to 0. It will then check online for that version until the web server returns 404. It recursively checks the next ordinal (the third number) until it also is not found.

SameVersionSoFar ( List currentVersion, List otherVersion, int ordinal ) : bool

Returns true if currentVersion and otherVersion are the same up to the ordinal (index_

Method Details

FillInUrl() public static method

Fills in a URL like "synergy-{0}.{1}" using the integers in the version array.
public static FillInUrl ( string url, List version ) : string
url string
version List
return string

LatestVersion() public method

public LatestVersion ( string url, List startingVersion ) : List
url string
startingVersion List
return List