MapsExtensionsGenerateMapOptionsT Method

Generates a MapOptions for a Google Map centered around the item parameter. (Usually a EnvironmentDto or DeviceDto)

Definition

Namespace: MobileTrack.Web.Components.Extensions
Assembly: MobileTrack.Web.Components (in MobileTrack.Web.Components.dll) Version: 0.7+45c8d9adb5970d727cceec44a5ed61aea0016e50
public static Task<MapOptions> GenerateMapOptions<T>(
	UserSessionData currentUser,
	IAzureCosmosDb cosmosDb,
	T item,
	MapApiLoadOptions loadOptions,
	CancellationToken cancellationToken
)
where T : class, IIdLabel, IHasEnvironment, IHasLocation

Parameters

currentUser  UserSessionData
currently signed-in user.
cosmosDb  IAzureCosmosDb
Cosmos DB interop
item  T
Item to generate the options for
loadOptions  MapApiLoadOptions
API options.
cancellationToken  CancellationToken
Cancellation token

Type Parameters

T
Item type of item to base the map around

Return Value

TaskMapOptions
Generated MapOptions

Exceptions

ArgumentNullExceptionThrown if item or loadOptions is .

See Also