Click or drag to resize

SimpleRepositoryCreateFailoverRepository Method

Verizon Connect Logo
Print this page
Learn more about Verizon Connect GeoBase.
Get information about the latest release
Get a new SimpleRepository created from several instances of a same GBFS file. In case one file instance is no longer available, the SimpleRepository fails over to the next one.

Namespace:  Telogis.GeoBase.Repositories
Assembly:  geobase.net (in geobase.net.dll) Version: 4.99.0.0
Syntax
public static SimpleRepository CreateFailoverRepository(
	string gbfsBaseame,
	uint nbRetry,
	uint retryInterval,
	params string[] failoverDirectories
)

Parameters

gbfsBaseame
Type: SystemString
The basename of a GBFS file.
nbRetry
Type: SystemUInt32
Number of retries, in case of temporary errors, before failing over to the next file.
retryInterval
Type: SystemUInt32
Time to wait between each try (in milliseconds).
failoverDirectories
Type: SystemString
Paths to directories containing this GBFS file. These may be absolute, or relative.

Return Value

Type: SimpleRepository
A SimpleRepository.
Examples
C#
// Try to load the primary map data file instance four times, once every 100ms, before switching to an alternative
Telogis.GeoBase.Repositories.SimpleRepository.CreateFailoverRepository(
    "MAP_DATA_FILE.gbfs",
    4,
    100,
    new string[] { 
        "C:\\primary_folder",
        "C:\\failover_folder"
    });
See Also